[OpenMP] Make target data directive generate unexpected directive diagnostic.
authorSamuel Antao <sfantao@us.ibm.com>
Wed, 22 Jul 2015 16:02:46 +0000 (16:02 +0000)
committerSamuel Antao <sfantao@us.ibm.com>
Wed, 22 Jul 2015 16:02:46 +0000 (16:02 +0000)
llvm-svn: 242906

clang/lib/Parse/ParseOpenMP.cpp

index 533d8db..2234f13 100644 (file)
@@ -136,11 +136,10 @@ Parser::DeclGroupPtrTy Parser::ParseOpenMPDeclarativeDirective() {
   case OMPD_teams:
   case OMPD_cancellation_point:
   case OMPD_cancel:
+  case OMPD_target_data:
     Diag(Tok, diag::err_omp_unexpected_directive)
         << getOpenMPDirectiveName(DKind);
     break;
-  case OMPD_target_data:
-    break;
   }
   SkipUntil(tok::annot_pragma_openmp_end);
   return DeclGroupPtrTy();