[cfe-commits] r75608 - in /cfe/trunk/test/Index: cxx-operator-overload-input.cpp cxx-operator-overload.cpp resolve-loc-input.c resolve-loc.c

Argiris Kirtzidis akyrtzi at gmail.com
Mon Jul 13 22:34:59 PDT 2009


Author: akirtzidis
Date: Tue Jul 14 00:34:59 2009
New Revision: 75608

URL: http://llvm.org/viewvc/llvm-project?rev=75608&view=rev
Log:
Move the RUN lines on the same file but below the code, as suggested by Sebastian.

Removed:
    cfe/trunk/test/Index/cxx-operator-overload-input.cpp
    cfe/trunk/test/Index/resolve-loc-input.c
Modified:
    cfe/trunk/test/Index/cxx-operator-overload.cpp
    cfe/trunk/test/Index/resolve-loc.c

Removed: cfe/trunk/test/Index/cxx-operator-overload-input.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Index/cxx-operator-overload-input.cpp?rev=75607&view=auto

==============================================================================
--- cfe/trunk/test/Index/cxx-operator-overload-input.cpp (original)
+++ cfe/trunk/test/Index/cxx-operator-overload-input.cpp (removed)
@@ -1,12 +0,0 @@
-class Cls {
-public:
-    Cls operator +(const Cls &RHS);
-};
-
-static void bar() {
-    Cls x1, x2, x3;
-    Cls x4 = x1 + x2 + x3;
-}
-
-Cls Cls::operator +(const Cls &RHS) {
-}

Modified: cfe/trunk/test/Index/cxx-operator-overload.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Index/cxx-operator-overload.cpp?rev=75608&r1=75607&r2=75608&view=diff

==============================================================================
--- cfe/trunk/test/Index/cxx-operator-overload.cpp (original)
+++ cfe/trunk/test/Index/cxx-operator-overload.cpp Tue Jul 14 00:34:59 2009
@@ -1,9 +1,22 @@
-// RUN: clang-cc -emit-pch %S/cxx-operator-overload-input.cpp -o %t.ast &&
-// RUN: index-test %t.ast -point-at %S/cxx-operator-overload-input.cpp:8:17 -print-decls | count 2 &&
-// RUN: index-test %t.ast -point-at %S/cxx-operator-overload-input.cpp:8:17 -print-decls | grep ':3:9,' &&
-// RUN: index-test %t.ast -point-at %S/cxx-operator-overload-input.cpp:8:17 -print-decls | grep ':11:10,' &&
+class Cls {
+public:
+    Cls operator +(const Cls &RHS);
+};
+
+static void bar() {
+    Cls x1, x2, x3;
+    Cls x4 = x1 + x2 + x3;
+}
+
+Cls Cls::operator +(const Cls &RHS) {
+}
+
+// RUN: clang-cc -emit-pch %s -o %t.ast &&
+// RUN: index-test %t.ast -point-at %s:8:17 -print-decls | count 2 &&
+// RUN: index-test %t.ast -point-at %s:8:17 -print-decls | grep ':3:9,' &&
+// RUN: index-test %t.ast -point-at %s:8:17 -print-decls | grep ':11:10,' &&
 
 // Yep, we can show references of '+' plus signs that are overloaded, w00t!
-// RUN: index-test %t.ast -point-at %S/cxx-operator-overload-input.cpp:3:15 -print-refs | count 2 &&
-// RUN: index-test %t.ast -point-at %S/cxx-operator-overload-input.cpp:3:15 -print-refs | grep ':8:17,' &&
-// RUN: index-test %t.ast -point-at %S/cxx-operator-overload-input.cpp:3:15 -print-refs | grep ':8:22,'
+// RUN: index-test %t.ast -point-at %s:3:15 -print-refs | count 2 &&
+// RUN: index-test %t.ast -point-at %s:3:15 -print-refs | grep ':8:17,' &&
+// RUN: index-test %t.ast -point-at %s:3:15 -print-refs | grep ':8:22,'

Removed: cfe/trunk/test/Index/resolve-loc-input.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Index/resolve-loc-input.c?rev=75607&view=auto

==============================================================================
--- cfe/trunk/test/Index/resolve-loc-input.c (original)
+++ cfe/trunk/test/Index/resolve-loc-input.c (removed)
@@ -1,14 +0,0 @@
-int top_var;
-
-void top_func_decl(int param1);
-
-void top_func_def(int param2) {
-  int local_var1;
-  for (int for_var = 100; for_var < 500; ++for_var) {
-    int local_var2 = for_var + 1;
-  }
-}
-
-struct S {
-  int field_var;
-};

Modified: cfe/trunk/test/Index/resolve-loc.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Index/resolve-loc.c?rev=75608&r1=75607&r2=75608&view=diff

==============================================================================
--- cfe/trunk/test/Index/resolve-loc.c (original)
+++ cfe/trunk/test/Index/resolve-loc.c Tue Jul 14 00:34:59 2009
@@ -1,16 +1,32 @@
-// RUN: clang-cc -emit-pch %S/resolve-loc-input.c -o %t.ast &&
-// RUN: index-test %t.ast -point-at %S/resolve-loc-input.c:1:8 | grep top_var &&
-// RUN: index-test %t.ast -point-at %S/resolve-loc-input.c:3:15 | grep top_func_decl &&
-// RUN: index-test %t.ast -point-at %S/resolve-loc-input.c:3:25 | grep param1 &&
-// RUN: index-test %t.ast -point-at %S/resolve-loc-input.c:5:17 | grep top_func_def &&
-// RUN: index-test %t.ast -point-at %S/resolve-loc-input.c:5:23 | grep param2 &&
-// RUN: index-test %t.ast -point-at %S/resolve-loc-input.c:6:10 | grep local_var1 &&
-// RUN: index-test %t.ast -point-at %S/resolve-loc-input.c:7:15 | grep for_var &&
-// RUN: index-test %t.ast -point-at %S/resolve-loc-input.c:7:43 | grep top_func_def &&
-// RUN: index-test %t.ast -point-at %S/resolve-loc-input.c:7:43 | grep '++for_var' &&
-// RUN: index-test %t.ast -point-at %S/resolve-loc-input.c:8:9 | grep local_var2 &&
-// RUN: index-test %t.ast -point-at %S/resolve-loc-input.c:8:30 | grep local_var2 &&
-// RUN: index-test %t.ast -point-at %S/resolve-loc-input.c:8:30 | grep 'for_var + 1' &&
+int top_var;
+
+void top_func_decl(int param1);
+
+void top_func_def(int param2) {
+  int local_var1;
+  for (int for_var = 100; for_var < 500; ++for_var) {
+    int local_var2 = for_var + 1;
+  }
+}
+
+struct S {
+  int field_var;
+};
+
+
+// RUN: clang-cc -emit-pch %s -o %t.ast &&
+// RUN: index-test %t.ast -point-at %s:1:8 | grep top_var &&
+// RUN: index-test %t.ast -point-at %s:3:15 | grep top_func_decl &&
+// RUN: index-test %t.ast -point-at %s:3:25 | grep param1 &&
+// RUN: index-test %t.ast -point-at %s:5:17 | grep top_func_def &&
+// RUN: index-test %t.ast -point-at %s:5:23 | grep param2 &&
+// RUN: index-test %t.ast -point-at %s:6:10 | grep local_var1 &&
+// RUN: index-test %t.ast -point-at %s:7:15 | grep for_var &&
+// RUN: index-test %t.ast -point-at %s:7:43 | grep top_func_def &&
+// RUN: index-test %t.ast -point-at %s:7:43 | grep '++for_var' &&
+// RUN: index-test %t.ast -point-at %s:8:9 | grep local_var2 &&
+// RUN: index-test %t.ast -point-at %s:8:30 | grep local_var2 &&
+// RUN: index-test %t.ast -point-at %s:8:30 | grep 'for_var + 1' &&
 
 // fields test.
-// RUN: index-test %t.ast -point-at %S/resolve-loc-input.c:13:10 | grep field_var
+// RUN: index-test %t.ast -point-at %s:13:10 | grep field_var





More information about the cfe-commits mailing list