ABataev added inline comments.

================
Comment at: clang/lib/Parse/ParseOpenMP.cpp:2814
     }
 
     if (CKind == OMPC_ordered && PP.LookAhead(/*N=*/0).isNot(tok::l_paren))
----------------
This can be simplified like this:
```
    if (!FirstClause) {
      Diag(Tok, diag::err_omp_more_one_clause)
          << getOpenMPDirectiveName(DKind) << getOpenMPClauseName(CKind) << 0;
      ErrorFound = true;
    }
    LLVM_FALLTHROUGH;
case OMPC_filter:
```
Plus, I think, you should not exclude OMPC_filter from the check, I think only 
single clause is allowed by the spec.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D99995/new/

https://reviews.llvm.org/D99995

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to