diff options
author | Alexander Musman <alexander.musman@gmail.com> | 2014-07-21 09:42:05 +0000 |
---|---|---|
committer | Alexander Musman <alexander.musman@gmail.com> | 2014-07-21 09:42:05 +0000 |
commit | 76fc5c55ecf19799784bf1f798293da347a7e56f (patch) | |
tree | 311f55cc3ed96eb5a5343d925be0cabe14fb4e4a /lib/AST/StmtPrinter.cpp | |
parent | 88b9e43471b45aaa91b6904865374a35db7c1c0b (diff) |
[OPENMP] Parsing/Sema of the OpenMP directive 'critical'.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@213510 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/AST/StmtPrinter.cpp')
-rw-r--r-- | lib/AST/StmtPrinter.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/lib/AST/StmtPrinter.cpp b/lib/AST/StmtPrinter.cpp index 0267bcca2a..9c00eeaa0f 100644 --- a/lib/AST/StmtPrinter.cpp +++ b/lib/AST/StmtPrinter.cpp @@ -834,6 +834,16 @@ void StmtPrinter::VisitOMPMasterDirective(OMPMasterDirective *Node) { PrintOMPExecutableDirective(Node); } +void StmtPrinter::VisitOMPCriticalDirective(OMPCriticalDirective *Node) { + Indent() << "#pragma omp critical"; + if (Node->getDirectiveName().getName()) { + OS << " ("; + Node->getDirectiveName().printName(OS); + OS << ")"; + } + PrintOMPExecutableDirective(Node); +} + void StmtPrinter::VisitOMPParallelForDirective(OMPParallelForDirective *Node) { Indent() << "#pragma omp parallel for "; PrintOMPExecutableDirective(Node); |