diff options
Diffstat (limited to 'clang/unittests/ASTMatchers/ASTMatchersTest.h')
-rw-r--r-- | clang/unittests/ASTMatchers/ASTMatchersTest.h | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/clang/unittests/ASTMatchers/ASTMatchersTest.h b/clang/unittests/ASTMatchers/ASTMatchersTest.h index b22cafefd9a..3f3118c2ef4 100644 --- a/clang/unittests/ASTMatchers/ASTMatchersTest.h +++ b/clang/unittests/ASTMatchers/ASTMatchersTest.h @@ -235,6 +235,18 @@ testing::AssertionResult notMatchesWithCuda(const std::string &Code, } template <typename T> +testing::AssertionResult matchesWithOpenMP(const std::string &Code, + const T &AMatcher) { + return matchesConditionally(Code, AMatcher, true, "-fopenmp"); +} + +template <typename T> +testing::AssertionResult notMatchesWithOpenMP(const std::string &Code, + const T &AMatcher) { + return matchesConditionally(Code, AMatcher, false, "-fopenmp"); +} + +template <typename T> testing::AssertionResult matchAndVerifyResultConditionally(const std::string &Code, const T &AMatcher, std::unique_ptr<BoundNodesCallback> FindResultVerifier, |