summaryrefslogtreecommitdiffstats
path: root/clang/lib/Parse/ParseOpenMP.cpp
diff options
context:
space:
mode:
authorAlexey Bataev <a.bataev@hotmail.com>2014-06-26 12:05:45 +0000
committerAlexey Bataev <a.bataev@hotmail.com>2014-06-26 12:05:45 +0000
commitd1e40fbfe1c38f5778c739d1fc1b3bcf156ccb58 (patch)
tree30b273a3b64072c964ed33986d2de6362af8c7d8 /clang/lib/Parse/ParseOpenMP.cpp
parentaee45418287cdcc1387c56e0c0d08990c322b45b (diff)
downloadbcm5719-llvm-d1e40fbfe1c38f5778c739d1fc1b3bcf156ccb58.tar.gz
bcm5719-llvm-d1e40fbfe1c38f5778c739d1fc1b3bcf156ccb58.zip
[OPENMP] Initial parsing and sema analysis for 'single' directive.
llvm-svn: 211774
Diffstat (limited to 'clang/lib/Parse/ParseOpenMP.cpp')
-rw-r--r--clang/lib/Parse/ParseOpenMP.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/clang/lib/Parse/ParseOpenMP.cpp b/clang/lib/Parse/ParseOpenMP.cpp
index 11e888efb40..102cab36e99 100644
--- a/clang/lib/Parse/ParseOpenMP.cpp
+++ b/clang/lib/Parse/ParseOpenMP.cpp
@@ -65,6 +65,7 @@ Parser::DeclGroupPtrTy Parser::ParseOpenMPDeclarativeDirective() {
case OMPD_for:
case OMPD_sections:
case OMPD_section:
+ case OMPD_single:
Diag(Tok, diag::err_omp_unexpected_directive)
<< getOpenMPDirectiveName(DKind);
break;
@@ -80,8 +81,8 @@ Parser::DeclGroupPtrTy Parser::ParseOpenMPDeclarativeDirective() {
/// annot_pragma_openmp_end
///
/// executable-directive:
-/// annot_pragma_openmp 'parallel'|'simd'|'for'|'sections'|'section'
-/// {clause} annot_pragma_openmp_end
+/// annot_pragma_openmp 'parallel' | 'simd' | 'for' | 'sections' |
+/// 'section' | 'single' {clause} annot_pragma_openmp_end
///
StmtResult Parser::ParseOpenMPDeclarativeOrExecutableDirective() {
assert(Tok.is(tok::annot_pragma_openmp) && "Not an OpenMP directive!");
@@ -121,6 +122,7 @@ StmtResult Parser::ParseOpenMPDeclarativeOrExecutableDirective() {
case OMPD_simd:
case OMPD_for:
case OMPD_sections:
+ case OMPD_single:
case OMPD_section: {
ConsumeToken();
OpenPOWER on IntegriCloud