[clang] [clang] Add break/continue stmts with missing lable to the AST (PR #168332)

via cfe-commits cfe-commits at lists.llvm.org
Mon Nov 17 04:41:25 PST 2025


Sirraide wrote:

> I'm not entirely sure if we should do the same thing in `Sema::ActOnBreakStmt`, but I think so.

If we’re doing this then that *should* be fine so long as we still drop the `break`/`continue` if were not inside a loop or `switch` statement, because trying to evaluate e.g. `int f() { break; }` would definitely crash.

https://github.com/llvm/llvm-project/pull/168332


More information about the cfe-commits mailing list