Skip to content

Commit

Permalink
Fix Clang -Wshadow-uncaptured-local warning.
Browse files Browse the repository at this point in the history
  • Loading branch information
skvadrik committed Nov 13, 2024
1 parent bce5d21 commit a5e37dc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/codegen/pass2_generate.cc
Original file line number Diff line number Diff line change
Expand Up @@ -674,9 +674,6 @@ static CodeList* gen_goifl(
OutAllocator& alc = output.allocator;
const opt_t* opts = output.block().opts;

CodeList* stmts = code_list(alc);
const CodeGoBranch* b = go->branches, *e = b + go->nbranches;

auto transition = [&](const CodeGoBranch* b) {
if (b->kind == CodeGoBranch::Kind::JUMP) {
CodeList* code = code_list(alc);
Expand All @@ -687,6 +684,9 @@ static CodeList* gen_goifl(
}
};

CodeList* stmts = code_list(alc);
const CodeGoBranch* b = go->branches, *e = b + go->nbranches;

if (opts->code_model != CodeModel::REC_FUNC) {
// In goto/label and loop/switch modes generate a sequence of IF statements.
// It is possible to use IF/ELSE-IF.../ELSE instead, but this would prevent folding YYSKIP
Expand Down

0 comments on commit a5e37dc

Please sign in to comment.