diff --git a/tccgen.c b/tccgen.c index d5e9bf5..24c46ed 100644 --- a/tccgen.c +++ b/tccgen.c @@ -7253,6 +7253,9 @@ again: if (debug_modes) tcc_tcov_reset_ind(tcc_state); vla_restore(cur_scope->vla.loc); + /* c23 declaration after label */ + if (tok != ';') + decl(VT_LOCAL); if (tok != '}') goto again; /* we accept this, but it is a mistake */ @@ -7266,7 +7269,7 @@ again: if (is_expr) { vpop(); gexpr(); - } else if (!decl(VT_JMP)) { + } else { gexpr(); vpop(); }