[clang] [clang][CFG] Fix range-for iterator initialization order (PR #234467)
Taufiq Rahman via cfe-commits
cfe-commits at lists.llvm.org
Thu Oct 22 18:07:27 PDT 2026
================
@@ -4989,8 +4989,8 @@ CFGBlock *CFGBuilder::VisitCXXForRangeStmt(CXXForRangeStmt *S) {
// Add the initialization statements.
Block = createBlock();
- addStmt(S->getBeginStmt());
addStmt(S->getEndStmt());
+ addStmt(S->getBeginStmt());
----------------
Inconnu08 wrote:
Wow, I didn’t realize this went all the way back to Clang 3.9! Thanks for digging into the history.
https://github.com/llvm/llvm-project/pull/234467
More information about the cfe-commits
mailing list