Skip to content

Commit cc247bc

Browse files
[Clang][OpenMP] Fixing error - 147336
1 parent 3de59f7 commit cc247bc

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

clang/lib/Parse/ParseOpenMP.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2704,7 +2704,7 @@ StmtResult Parser::ParseOpenMPDeclarativeOrExecutableDirective(
27042704
// If no match is found and no otherwise clause is present, skip
27052705
// OMP5.2 Chapter 7.4: If no otherwise clause is specified the effect is as
27062706
// if one was specified without an associated directive variant.
2707-
if (BestIdx == -1 && Idx == 1) {
2707+
if (BestIdx == -1 && Idx > 0) {
27082708
assert(Tok.is(tok::annot_pragma_openmp_end) &&
27092709
"Expecting the end of the pragma here");
27102710
ConsumeAnnotationToken();

0 commit comments

Comments
 (0)