Author: dmgreen
Date: Sat Feb 16 03:19:04 2019
New Revision: 354201

URL: http://llvm.org/viewvc/llvm-project?rev=354201&view=rev
Log:
Move multiline raw string literal out of macro. NFC

Certain combinations of gcc and ccache fail when the raw
string literal is preprocessed. This just moves the string
out as is done elsewhere in the same file.

Modified:
    cfe/trunk/unittests/ASTMatchers/ASTMatchersTraversalTest.cpp

Modified: cfe/trunk/unittests/ASTMatchers/ASTMatchersTraversalTest.cpp
URL: 
http://llvm.org/viewvc/llvm-project/cfe/trunk/unittests/ASTMatchers/ASTMatchersTraversalTest.cpp?rev=354201&r1=354200&r2=354201&view=diff
==============================================================================
--- cfe/trunk/unittests/ASTMatchers/ASTMatchersTraversalTest.cpp (original)
+++ cfe/trunk/unittests/ASTMatchers/ASTMatchersTraversalTest.cpp Sat Feb 16 
03:19:04 2019
@@ -491,16 +491,15 @@ TEST(MatcherCXXMemberCallExpr, On) {
   EXPECT_TRUE(matches(Snippet2, MatchesX));
 
   // Parens are ignored.
+  auto Snippet3 = R"cc(
+    struct Y {
+      void m();
+    };
+    Y g();
+    void z(Y y) { (g()).m(); }
+  )cc";
   auto MatchesCall = cxxMemberCallExpr(on(callExpr()));
-  EXPECT_TRUE(matches(
-      R"cc(
-        struct Y {
-          void m();
-        };
-        Y g();
-        void z(Y y) { (g()).m(); }
-      )cc",
-      MatchesCall));
+  EXPECT_TRUE(matches(Snippet3, MatchesCall));
 }
 
 TEST(MatcherCXXMemberCallExpr, OnImplicitObjectArgument) {
@@ -527,16 +526,15 @@ TEST(MatcherCXXMemberCallExpr, OnImplici
   EXPECT_TRUE(notMatches(Snippet2, MatchesX));
 
   // Parens are not ignored.
+  auto Snippet3 = R"cc(
+    struct Y {
+      void m();
+    };
+    Y g();
+    void z(Y y) { (g()).m(); }
+  )cc";
   auto MatchesCall = cxxMemberCallExpr(onImplicitObjectArgument(callExpr()));
-  EXPECT_TRUE(notMatches(
-      R"cc(
-        struct Y {
-          void m();
-        };
-        Y g();
-        void z(Y y) { (g()).m(); }
-      )cc",
-      MatchesCall));
+  EXPECT_TRUE(notMatches(Snippet3, MatchesCall));
 }
 
 TEST(Matcher, HasObjectExpr) {


_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to