Skip to content

Commit 9b4b94a

Browse files
committed
Added an assert.
1 parent c5160c0 commit 9b4b94a

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

clang/lib/Parse/ParseOpenMP.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2886,6 +2886,8 @@ StmtResult Parser::ParseOpenMPDeclarativeOrExecutableDirective(
28862886
// OMP5.2 Chapter 7.4: If no otherwise clause is specified the effect is as
28872887
// if one was specified without an associated directive variant.
28882888
if (BestIdx == -1 && Idx == 1) {
2889+
assert(Tok.is(tok::annot_pragma_openmp_end) &&
2890+
"Expecting the end of the pragma here");
28892891
ConsumeAnnotationToken();
28902892
return StmtEmpty();
28912893
}

0 commit comments

Comments
 (0)