fix catch handlers / match statements yielding past scope

This commit is contained in:
2026-06-30 23:21:47 +02:00
parent d6f9c24314
commit 7fe3552c01
6 changed files with 117 additions and 44 deletions
+2
View File
@@ -1376,6 +1376,7 @@ parse_statement :: proc(parser: ^Parser) -> ast.Stmt_Id {
name=name.symbol,
type=type_syntax,
immutable=immutable,
value_control_flow=true,
target=ast.INVALID_EXPR,
expr=ast.INVALID_EXPR,
body=body,
@@ -1443,6 +1444,7 @@ parse_statement :: proc(parser: ^Parser) -> ast.Stmt_Id {
kind=.Assignment,
span=span_from(parser.module.exprs[expr].span, previous(parser).span),
target=expr,
value_control_flow=true,
expr=ast.INVALID_EXPR,
body=body,
diagnostic=source.INVALID_DIAGNOSTIC,