================
@@ -7196,6 +7196,9 @@ bool Compiler<Emitter>::visitBreakStmt(const BreakStmt
*S) {
}
}
} else {
+ const Stmt *TargetLoop = S->getNamedLoopOrSwitch();
+ assert(TargetLoop && "break target label not available");
----------------
Expertcoderz wrote:
Okay now it should error on encountering invalid labeled `break`/`continue`
within otherwise valid loops in constant expressions, whether or not the new
interpreter is being used.
Now all that's left (I think?) is to make the error message a bit clearer.
https://github.com/llvm/llvm-project/pull/228655
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits