| 1 | class Foo { // CHECK: class Bar { |
|---|---|
| 2 | public: |
| 3 | Foo(); /* Test 1 */ // CHECK: Bar(); |
| 4 | }; |
| 5 | |
| 6 | Foo::Foo() /* Test 2 */ {} // CHECK: Bar::Bar() /* Test 2 */ {} |
| 7 | |
| 8 | // Test 1. |
| 9 | // RUN: clang-rename -offset=62 -new-name=Bar %s -- | sed 's,//.*,,' | FileCheck %s |
| 10 | // Test 2. |
| 11 | // RUN: clang-rename -offset=116 -new-name=Bar %s -- | sed 's,//.*,,' | FileCheck %s |
| 12 | |
| 13 | // To find offsets after modifying the file, use: |
| 14 | // grep -Ubo 'Foo.*' <file> |
| 15 |