[clang-tools-extra] r277354 - [clang-rename] revert r276836

Kirill Bobyrev via cfe-commits cfe-commits at lists.llvm.org
Mon Aug 1 09:48:34 PDT 2016


Author: omtcyfz
Date: Mon Aug  1 11:48:33 2016
New Revision: 277354

URL: http://llvm.org/viewvc/llvm-project?rev=277354&view=rev
Log:
[clang-rename] revert r276836

Revert r276836, which resulted in tests passing regardless of the actual tool
replacements.


Modified:
    clang-tools-extra/trunk/test/clang-rename/ClassAsTemplateArgumentFindByClass.cpp
    clang-tools-extra/trunk/test/clang-rename/ClassAsTemplateArgumentFindByTemplateArgument.cpp
    clang-tools-extra/trunk/test/clang-rename/ClassFindByName.cpp
    clang-tools-extra/trunk/test/clang-rename/ClassNameInFunctionDefinition.cpp
    clang-tools-extra/trunk/test/clang-rename/ClassSimpleRenaming.cpp
    clang-tools-extra/trunk/test/clang-rename/ComplicatedClassType.cpp
    clang-tools-extra/trunk/test/clang-rename/ConstCastExpr.cpp
    clang-tools-extra/trunk/test/clang-rename/ConstructExpr.cpp
    clang-tools-extra/trunk/test/clang-rename/CtorFindByDeclaration.cpp
    clang-tools-extra/trunk/test/clang-rename/CtorFindByDefinition.cpp
    clang-tools-extra/trunk/test/clang-rename/CtorInitializer.cpp
    clang-tools-extra/trunk/test/clang-rename/DeclRefExpr.cpp
    clang-tools-extra/trunk/test/clang-rename/DtorDeclaration.cpp
    clang-tools-extra/trunk/test/clang-rename/DtorDefinition.cpp
    clang-tools-extra/trunk/test/clang-rename/DynamicCastExpr.cpp
    clang-tools-extra/trunk/test/clang-rename/Field.cpp
    clang-tools-extra/trunk/test/clang-rename/FunctionMacro.cpp
    clang-tools-extra/trunk/test/clang-rename/MemberExprMacro.cpp
    clang-tools-extra/trunk/test/clang-rename/Namespace.cpp
    clang-tools-extra/trunk/test/clang-rename/ReinterpretCastExpr.cpp
    clang-tools-extra/trunk/test/clang-rename/StaticCastExpr.cpp
    clang-tools-extra/trunk/test/clang-rename/TemplateFunctionFindByDeclaration.cpp
    clang-tools-extra/trunk/test/clang-rename/TemplateFunctionFindByUse.cpp
    clang-tools-extra/trunk/test/clang-rename/TemplateTypenameFindByTypeInside.cpp
    clang-tools-extra/trunk/test/clang-rename/UserDefinedConversionFindByTypeDeclaration.cpp
    clang-tools-extra/trunk/test/clang-rename/Variable.cpp
    clang-tools-extra/trunk/test/clang-rename/VariableMacro.cpp

Modified: clang-tools-extra/trunk/test/clang-rename/ClassAsTemplateArgumentFindByClass.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/ClassAsTemplateArgumentFindByClass.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/ClassAsTemplateArgumentFindByClass.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/ClassAsTemplateArgumentFindByClass.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=74 -new-name=Bar %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=136 -new-name=Bar %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 class Foo {};   // CHECK: class Bar {};
 

Modified: clang-tools-extra/trunk/test/clang-rename/ClassAsTemplateArgumentFindByTemplateArgument.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/ClassAsTemplateArgumentFindByTemplateArgument.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/ClassAsTemplateArgumentFindByTemplateArgument.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/ClassAsTemplateArgumentFindByTemplateArgument.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=243 -new-name=Bar %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=304 -new-name=Bar %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 class Foo {};   // CHECK: class Bar {};
 

Modified: clang-tools-extra/trunk/test/clang-rename/ClassFindByName.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/ClassFindByName.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/ClassFindByName.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/ClassFindByName.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -old-name=Foo -new-name=Bar %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -old-name=Foo -new-name=Bar %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 class Foo {         // CHECK: class Bar
 };

Modified: clang-tools-extra/trunk/test/clang-rename/ClassNameInFunctionDefinition.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/ClassNameInFunctionDefinition.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/ClassNameInFunctionDefinition.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/ClassNameInFunctionDefinition.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=74 -new-name=Bar %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=136 -new-name=Bar %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 class Foo {             // CHECK: class Bar {
 public:

Modified: clang-tools-extra/trunk/test/clang-rename/ClassSimpleRenaming.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/ClassSimpleRenaming.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/ClassSimpleRenaming.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/ClassSimpleRenaming.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=74 -new-name=Bar %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=136 -new-name=Bar %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 class Foo {};       // CHECK: class Bar
 
@@ -7,5 +9,5 @@ int main() {
   return 0;
 }
 
-// Use grep -FUbo 'Foo' <file> to get the correct offset of Foo when changing
+// Use grep -FUbo 'Foo' <file> to get the correct offset of Cla when changing
 // this file.

Modified: clang-tools-extra/trunk/test/clang-rename/ComplicatedClassType.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/ComplicatedClassType.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/ComplicatedClassType.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/ComplicatedClassType.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=159 -new-name=Bar %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=220 -new-name=Bar %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 // Forward declaration.
 class Foo;                            // CHECK: class Bar;

Modified: clang-tools-extra/trunk/test/clang-rename/ConstCastExpr.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/ConstCastExpr.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/ConstCastExpr.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/ConstCastExpr.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=74 -new-name=Bar %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=136 -new-name=Bar %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 class Foo {                         // CHECK: class Bar {
 public:
@@ -12,5 +14,5 @@ int main() {
   const_cast<Foo *>(C)->getValue(); // CHECK: const_cast<Bar *>(C)->getValue();
 }
 
-// Use grep -FUbo 'Foo' <file> to get the correct offset of Foo when changing
+// Use grep -FUbo 'Cla' <file> to get the correct offset of foo when changing
 // this file.

Modified: clang-tools-extra/trunk/test/clang-rename/ConstructExpr.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/ConstructExpr.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/ConstructExpr.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/ConstructExpr.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=74 -new-name=Boo %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=136 -new-name=Boo %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 class Foo {};         // CHECK: class Boo {};
 
@@ -6,5 +8,5 @@ int main() {
   Foo *C = new Foo(); // CHECK: Boo *C = new Boo();
 }
 
-// Use grep -FUbo 'Foo' <file> to get the correct offset of Foo when changing
+// Use grep -FUbo 'Boo' <file> to get the correct offset of foo when changing
 // this file.

Modified: clang-tools-extra/trunk/test/clang-rename/CtorFindByDeclaration.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/CtorFindByDeclaration.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/CtorFindByDeclaration.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/CtorFindByDeclaration.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=113 -new-name=Bar %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=174 -new-name=Bar %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 class Foo {   // CHECK: class Bar
 public:
@@ -7,5 +9,5 @@ public:
 
 Foo::Foo() {} // CHECK: Bar::Bar()
 
-// Use grep -FUbo 'Foo' <file> to get the correct offset of Foo when changing
+// Use grep -FUbo 'C' <file> to get the correct offset of foo when changing
 // this file.

Modified: clang-tools-extra/trunk/test/clang-rename/CtorFindByDefinition.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/CtorFindByDefinition.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/CtorFindByDefinition.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/CtorFindByDefinition.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=151 -new-name=Bar %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=212 -new-name=Bar %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 class Foo {   // CHECK: class Bar
 public:
@@ -7,5 +9,5 @@ public:
 
 Foo::Foo() {} // CHECK: Bar::Bar()
 
-// Use grep -FUbo 'Foo' <file> to get the correct offset of Foo when changing
+// Use grep -FUbo 'C' <file> to get the correct offset of foo when changing
 // this file.

Modified: clang-tools-extra/trunk/test/clang-rename/CtorInitializer.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/CtorInitializer.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/CtorInitializer.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/CtorInitializer.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=102 -new-name=Bar %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=163 -new-name=Bar %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 class Baz {};
 

Modified: clang-tools-extra/trunk/test/clang-rename/DeclRefExpr.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/DeclRefExpr.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/DeclRefExpr.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/DeclRefExpr.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=100 -new-name=Bar %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=161 -new-name=Bar %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 class C {
 public:
@@ -14,5 +16,5 @@ int main() {
   int y = C::Foo; // CHECK: C::Bar
 }
 
-// Use grep -FUbo 'Foo' <file> to get the correct offset of Foo when changing
+// Use grep -FUbo 'X' <file> to get the correct offset of foo when changing
 // this file.

Modified: clang-tools-extra/trunk/test/clang-rename/DtorDeclaration.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/DtorDeclaration.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/DtorDeclaration.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/DtorDeclaration.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=114 -new-name=Bar %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=175 -new-name=Bar %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 class Foo { // CHECK: class Bar {
 public:
@@ -8,5 +10,5 @@ public:
 Foo::~Foo() { // CHECK: Bar::~Bar()
 }
 
-// Use grep -FUbo 'Foo' <file> to get the correct offset of Foo when changing
+// Use grep -FUbo 'Bar' <file> to get the correct offset of foo when changing
 // this file.

Modified: clang-tools-extra/trunk/test/clang-rename/DtorDefinition.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/DtorDefinition.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/DtorDefinition.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/DtorDefinition.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=158 -new-name=Bar %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=219 -new-name=Bar %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 class Foo {     // CHECK: class Bar {
 public:
@@ -8,5 +10,5 @@ public:
 Foo::~Foo() {}  // CHECK: Bar::~Bar()
 
 
-// Use grep -FUbo 'Foo' <file> to get the correct offset of Foo when changing
+// Use grep -FUbo 'Foo' <file> to get the correct offset of foo when changing
 // this file.

Modified: clang-tools-extra/trunk/test/clang-rename/DynamicCastExpr.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/DynamicCastExpr.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/DynamicCastExpr.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/DynamicCastExpr.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=134 -new-name=Bar %s -- -frtti | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=195 -new-name=Bar %t.cpp -i -- -frtti
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 class Baz {
   virtual int getValue() const = 0;
@@ -20,5 +22,5 @@ int main() {
   dynamic_cast<const Foo *>(Pointer)->getValue();  // CHECK: dynamic_cast<const Bar *>(Pointer)->getValue();
 }
 
-// Use grep -FUbo 'Foo' <file> to get the correct offset of Foo when changing
+// Use grep -FUbo 'Foo' <file> to get the correct offset of foo when changing
 // this file.

Modified: clang-tools-extra/trunk/test/clang-rename/Field.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/Field.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/Field.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/Field.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=87 -new-name=Bar %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=148 -new-name=Bar %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 class Baz {
   int Foo;              // CHECK: Bar;

Modified: clang-tools-extra/trunk/test/clang-rename/FunctionMacro.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/FunctionMacro.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/FunctionMacro.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/FunctionMacro.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=138 -new-name=macro_function %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=199 -new-name=macro_function %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 #define moo foo // CHECK: #define moo macro_function
 
@@ -15,5 +17,5 @@ void qoo() {
   boo(moo());
 }
 
-// Use grep -FUbo 'foo' <file> to get the correct offset of foo when changing
+// Use grep -FUbo 'foo;' <file> to get the correct offset of foo when changing
 // this file.

Modified: clang-tools-extra/trunk/test/clang-rename/MemberExprMacro.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/MemberExprMacro.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/MemberExprMacro.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/MemberExprMacro.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=95 -new-name=Bar %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=156 -new-name=Bar %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 class Baz {
 public:

Modified: clang-tools-extra/trunk/test/clang-rename/Namespace.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/Namespace.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/Namespace.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/Namespace.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=79 -new-name=llvm %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=143 -new-name=llvm %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 namespace foo { // CHECK: namespace llvm {
   int x;
@@ -8,5 +10,5 @@ void boo() {
   foo::x = 42;  // CHECK: llvm::x = 42;
 }
 
-// Use grep -FUbo 'foo' <file> to get the correct offset of foo when changing
+// Use grep -FUbo 'foo;' <file> to get the correct offset of foo when changing
 // this file.

Modified: clang-tools-extra/trunk/test/clang-rename/ReinterpretCastExpr.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/ReinterpretCastExpr.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/ReinterpretCastExpr.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/ReinterpretCastExpr.cpp Mon Aug  1 11:48:33 2016
@@ -1,5 +1,6 @@
-// RUN: clang-rename -offset=73 -new-name=X %s -- | FileCheck %s
-
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=133 -new-name=X %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 class Cla {
 public:
   int getValue() const {
@@ -12,5 +13,5 @@ int main() {
   reinterpret_cast<const Cla *>(C)->getValue(); // CHECK: reinterpret_cast<const X *>
 }
 
-// Use grep -FUbo 'Cla' <file> to get the correct offset of Cla when changing
+// Use grep -FUbo 'Cla' <file> to get the correct offset of foo when changing
 // this file.

Modified: clang-tools-extra/trunk/test/clang-rename/StaticCastExpr.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/StaticCastExpr.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/StaticCastExpr.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/StaticCastExpr.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=91 -new-name=Bar %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=152 -new-name=Bar %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 class Baz {
 };

Modified: clang-tools-extra/trunk/test/clang-rename/TemplateFunctionFindByDeclaration.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/TemplateFunctionFindByDeclaration.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/TemplateFunctionFindByDeclaration.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/TemplateFunctionFindByDeclaration.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=93 -new-name=bar %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=154 -new-name=bar %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 template <typename T>
 T foo(T value) {    // CHECK: T bar(T value) {

Modified: clang-tools-extra/trunk/test/clang-rename/TemplateFunctionFindByUse.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/TemplateFunctionFindByUse.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/TemplateFunctionFindByUse.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/TemplateFunctionFindByUse.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=172 -new-name=bar %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=233 -new-name=bar %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 template <typename T>
 T foo(T value) {    // CHECK: T bar(T value) {

Modified: clang-tools-extra/trunk/test/clang-rename/TemplateTypenameFindByTypeInside.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/TemplateTypenameFindByTypeInside.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/TemplateTypenameFindByTypeInside.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/TemplateTypenameFindByTypeInside.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=289 -new-name=U %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=350 -new-name=U %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 // Currently unsupported test.
 // FIXME: clang-rename should be able to rename template parameters correctly.

Modified: clang-tools-extra/trunk/test/clang-rename/UserDefinedConversionFindByTypeDeclaration.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/UserDefinedConversionFindByTypeDeclaration.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/UserDefinedConversionFindByTypeDeclaration.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/UserDefinedConversionFindByTypeDeclaration.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=75 -new-name=Bar %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=136 -new-name=Bar %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 class Foo {                         // CHECK: class Bar {
 //    ^ offset must be here
@@ -20,5 +22,5 @@ int main() {
   return 0;
 }
 
-// Use grep -FUbo 'Foo' <file> to get the correct offset of Foo when changing
+// Use grep -FUbo 'Foo' <file> to get the correct offset of Cla when changing
 // this file.

Modified: clang-tools-extra/trunk/test/clang-rename/Variable.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/Variable.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/Variable.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/Variable.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=87 -new-name=Bar %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=148 -new-name=Bar %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 namespace A {
 int Foo;                // CHECK: int Bar;
@@ -21,5 +23,5 @@ void fun() {
   Foo = b.Foo;          // Foo = b.Foo;
 }
 
-// Use grep -FUbo 'Foo' <file> to get the correct offset of Foo when changing
+// Use grep -FUbo 'Foo' <file> to get the correct offset of foo when changing
 // this file.

Modified: clang-tools-extra/trunk/test/clang-rename/VariableMacro.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/test/clang-rename/VariableMacro.cpp?rev=277354&r1=277353&r2=277354&view=diff
==============================================================================
--- clang-tools-extra/trunk/test/clang-rename/VariableMacro.cpp (original)
+++ clang-tools-extra/trunk/test/clang-rename/VariableMacro.cpp Mon Aug  1 11:48:33 2016
@@ -1,4 +1,6 @@
-// RUN: clang-rename -offset=147 -new-name=Z %s -- | FileCheck %s
+// RUN: cat %s > %t.cpp
+// RUN: clang-rename -offset=208 -new-name=Z %t.cpp -i --
+// RUN: sed 's,//.*,,' %t.cpp | FileCheck %s
 
 #define Y X // CHECK: #define Y Z
 
@@ -12,5 +14,5 @@ void macro() {
   foo(Y);
 }
 
-// Use grep -FUbo 'X' <file> to get the correct offset of X when changing
+// Use grep -FUbo 'foo;' <file> to get the correct offset of foo when changing
 // this file.




More information about the cfe-commits mailing list