| 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 // Tests that the prototype for a function is updated. | 7 // Tests that the prototype for a function is updated. |
| 8 int TestFunctionThatTakesTwoInts(int x, int y); | 8 int TestFunctionThatTakesTwoInts(int x, int y); |
| 9 // Overload to test using declarations that introduce multiple shadow | 9 // Overload to test using declarations that introduce multiple shadow |
| 10 // declarations. | 10 // declarations. |
| (...skipping 18 matching lines...) Expand all Loading... |
| 29 | 29 |
| 30 // swap() functions are not renamed. | 30 // swap() functions are not renamed. |
| 31 void swap(SwapType& a, SwapType& b) {} | 31 void swap(SwapType& a, SwapType& b) {} |
| 32 | 32 |
| 33 // Note: F is already Google style and should not change. | 33 // Note: F is already Google style and should not change. |
| 34 void F() { | 34 void F() { |
| 35 // Test referencing a function without calling it. | 35 // Test referencing a function without calling it. |
| 36 int (*function_pointer)(int, int) = &TestFunctionThatTakesTwoInts; | 36 int (*function_pointer)(int, int) = &TestFunctionThatTakesTwoInts; |
| 37 } | 37 } |
| 38 | 38 |
| 39 void Bug640688(); // Declaration within blink namespace. |
| 40 |
| 39 } // namespace blink | 41 } // namespace blink |
| 40 | 42 |
| 43 void blink::Bug640688() {} // Definition outside of blink namespace. |
| 44 |
| 41 using blink::TestFunctionThatTakesTwoInts; | 45 using blink::TestFunctionThatTakesTwoInts; |
| 42 | 46 |
| 43 void G() { | 47 void G() { |
| 44 TestFunctionThatTakesTwoInts(1, 2); | 48 TestFunctionThatTakesTwoInts(1, 2); |
| 45 | 49 |
| 46 blink::SwapType a, b; | 50 blink::SwapType a, b; |
| 47 swap(a, b); | 51 swap(a, b); |
| 48 } | 52 } |
| OLD | NEW |