This commit is contained in:
agra
2026-03-02 21:00:55 +02:00
parent 2f4f898d54
commit bbb5426777
42 changed files with 483 additions and 9023 deletions

View File

@@ -89,6 +89,8 @@ pub const Parser = struct {
const expr = try self.parseIfExpr();
if (expr.data == .if_expr) {
expr.data.if_expr.is_comptime = true;
} else if (expr.data == .match_expr) {
expr.data.match_expr.is_comptime = true;
}
return expr;
}
@@ -1394,6 +1396,8 @@ pub const Parser = struct {
const expr = try self.parseIfExpr();
if (expr.data == .if_expr) {
expr.data.if_expr.is_comptime = true;
} else if (expr.data == .match_expr) {
expr.data.match_expr.is_comptime = true;
}
try self.expectSemicolonAfter(expr);
return expr;