| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 namespace blink { | 5 namespace blink { |
| 6 | 6 |
| 7 namespace { | 7 namespace { |
| 8 | 8 |
| 9 // Naive renaming will break the build, by leaving return type the same name as | 9 // Naive renaming will break the build, by leaving return type the same name as |
| 10 // the function name - to avoid this "Get" prefix needs to be prepended as | 10 // the function name - to avoid this "Get" prefix needs to be prepended as |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 44 void swap(SwapType& a, SwapType& b) {} | 44 void swap(SwapType& a, SwapType& b) {} |
| 45 | 45 |
| 46 // Note: F is already Google style and should not change. | 46 // Note: F is already Google style and should not change. |
| 47 void F() { | 47 void F() { |
| 48 // Test referencing a function without calling it. | 48 // Test referencing a function without calling it. |
| 49 int (*function_pointer)(int, int) = &TestFunctionThatTakesTwoInts; | 49 int (*function_pointer)(int, int) = &TestFunctionThatTakesTwoInts; |
| 50 } | 50 } |
| 51 | 51 |
| 52 void Bug640688(int); // Declaration within blink namespace. | 52 void Bug640688(int); // Declaration within blink namespace. |
| 53 | 53 |
| 54 // Tests for --method-blocklist cmdline parameter. |
| 55 namespace IdlFunctions { |
| 56 void foo(); |
| 57 } // namespace IdlFunctions |
| 58 |
| 54 } // namespace blink | 59 } // namespace blink |
| 55 | 60 |
| 56 // Definition outside of blink namespace. | 61 // Definition outside of blink namespace. |
| 57 void blink::Bug640688(int my_param) { | 62 void blink::Bug640688(int my_param) { |
| 58 char my_variable = 'c'; | 63 char my_variable = 'c'; |
| 59 } | 64 } |
| 60 | 65 |
| 61 using blink::TestFunctionThatTakesTwoInts; | 66 using blink::TestFunctionThatTakesTwoInts; |
| 62 | 67 |
| 63 void G() { | 68 void G() { |
| 64 TestFunctionThatTakesTwoInts(1, 2); | 69 TestFunctionThatTakesTwoInts(1, 2); |
| 65 | 70 |
| 66 blink::SwapType a, b; | 71 blink::SwapType a, b; |
| 67 swap(a, b); | 72 swap(a, b); |
| 68 } | 73 } |
| OLD | NEW |