[PATCH] D141215: [clang-repl] Introduce Value to capture expression results

Vassil Vassilev via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Sun Apr 2 00:57:14 PDT 2023


v.g.vassilev added inline comments.


================
Comment at: clang/lib/Parse/ParseStmt.cpp:554
+    // Otherwise, eat the semicolon.
+    ExpectAndConsumeSemi(diag::err_expected_semi_after_expr);
+  }
----------------
We seem to have more than one call to `ExpectAndConsumeSemi(diag::err_expected_semi_after_expr)`. Do we need something with them as well? Perhaps it is easier to have a check in `ExpectAndConsumeSemi` when the `diagID` is `err_expected_semi_after_expr` and check if `PP.isIncrementalProcessingEnabled() && Tok.is(tok::annot_input_end)`. There we can our new interface, say, `Sema::ActOnEndOfInput` which can attach more infrastructure if necessary.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D141215



More information about the cfe-commits mailing list