Use thread_safe_file

This commit is contained in:
gingerBill
2026-08-27 15:26:29 +01:00
parent 938257d425
commit db0cd79633
2 changed files with 3 additions and 3 deletions

View File

@@ -1387,7 +1387,7 @@ gb_internal void check_switch_stmt(CheckerContext *ctx, Ast *node, u32 mod_flags
}
}
if (is_strict_style(ast_file(node))) {
if (is_strict_style(node->thread_safe_file())) {
Token stok = ss->token;
for_array(i, bs->stmts) {
Ast *stmt = bs->stmts[i];
@@ -1663,7 +1663,7 @@ gb_internal void check_type_switch_stmt(CheckerContext *ctx, Ast *node, u32 mod_
}
}
if (is_strict_style(ast_file(node))) {
if (is_strict_style(node->thread_safe_file())) {
Token stok = ss->token;
for_array(i, bs->stmts) {
Ast *stmt = bs->stmts[i];

View File

@@ -104,7 +104,7 @@ gb_internal bool ast_file_vet_explicit_allocators(AstFile *f) {
}
gb_internal bool file_allow_newline(AstFile *f) {
bool is_strict = is_strict_style(f) || ast_file_vet_style(f)
bool is_strict = is_strict_style(f) || ast_file_vet_style(f);
return !is_strict;
}