summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--clang/unittests/AST/OMPStructuredBlockTest.cpp16
1 files changed, 9 insertions, 7 deletions
diff --git a/clang/unittests/AST/OMPStructuredBlockTest.cpp b/clang/unittests/AST/OMPStructuredBlockTest.cpp
index 623bed388c0..f4a3fad4a1b 100644
--- a/clang/unittests/AST/OMPStructuredBlockTest.cpp
+++ b/clang/unittests/AST/OMPStructuredBlockTest.cpp
@@ -102,11 +102,12 @@ void test() {
#pragma omp cancel parallel
}
})";
- ASSERT_TRUE(
- PrintedOMPStmtMatches(Source, OMPInnermostStructuredBlockMatcher(), R"({
+ const char *Expected = R"({
#pragma omp cancel parallel
}
-)"));
+)";
+ ASSERT_TRUE(PrintedOMPStmtMatches(
+ Source, OMPInnermostStructuredBlockMatcher(), Expected));
ASSERT_TRUE(PrintedOMPStmtMatches(Source, OMPStandaloneDirectiveMatcher(),
"#pragma omp cancel parallel\n"));
}
@@ -117,14 +118,15 @@ TEST(OMPStructuredBlock, TestCancellationPoint) {
void test() {
#pragma omp parallel
{
-#pragma omp cancellation point parallel
+ #pragma omp cancellation point parallel
}
})";
- ASSERT_TRUE(
- PrintedOMPStmtMatches(Source, OMPInnermostStructuredBlockMatcher(), R"({
+ const char *Expected = R"({
#pragma omp cancellation point parallel
}
-)"));
+)";
+ ASSERT_TRUE(PrintedOMPStmtMatches(
+ Source, OMPInnermostStructuredBlockMatcher(), Expected));
ASSERT_TRUE(
PrintedOMPStmtMatches(Source, OMPStandaloneDirectiveMatcher(),
"#pragma omp cancellation point parallel\n"));
OpenPOWER on IntegriCloud