@@ -2760,17 +2760,15 @@ StmtResult Parser::ParseOpenMPDeclarativeOrExecutableDirective(
2760
2760
? OMPC_unknown
2761
2761
: getOpenMPClauseKind (PP.getSpelling (Tok));
2762
2762
// Check if the clause is unrecognized.
2763
- if (CKind == OMPC_unknown) {
2763
+ if (CKind == OMPC_unknown)
2764
2764
Diag (Tok, diag::err_omp_unknown_clause)
2765
2765
<< PP.getSpelling (Tok) << " metadirective" ;
2766
- }
2767
- if (getLangOpts ().OpenMP < 52 && CKind == OMPC_otherwise) {
2766
+ if (getLangOpts ().OpenMP < 52 && CKind == OMPC_otherwise)
2768
2767
Diag (Tok, diag::err_omp_unexpected_clause)
2769
2768
<< PP.getSpelling (Tok) << " metadirective" ;
2770
- }
2771
- if (CKind == OMPC_default && getLangOpts ().OpenMP >= 52 ) {
2769
+ if (CKind == OMPC_default && getLangOpts ().OpenMP >= 52 )
2772
2770
Diag (Tok, diag::warn_omp_default_deprecated);
2773
- }
2771
+
2774
2772
SourceLocation Loc = ConsumeToken ();
2775
2773
2776
2774
// Parse '('.
@@ -2797,13 +2795,7 @@ StmtResult Parser::ParseOpenMPDeclarativeOrExecutableDirective(
2797
2795
return Directive;
2798
2796
}
2799
2797
}
2800
- if (CKind == OMPC_otherwise) {
2801
- // Check for 'otherwise' keyword.
2802
- if (Tok.is (tok::identifier) &&
2803
- Tok.getIdentifierInfo ()->getName () == " otherwise" ) {
2804
- ConsumeToken (); // Consume 'otherwise'
2805
- }
2806
- }
2798
+
2807
2799
// Skip Directive for now. We will parse directive in the second iteration
2808
2800
int paren = 0 ;
2809
2801
while (Tok.isNot (tok::r_paren) || paren != 0 ) {
0 commit comments