aboutsummaryrefslogtreecommitdiff
path: root/src/check_decl.cpp
diff options
context:
space:
mode:
authorgingerBill <gingerBill@users.noreply.github.com>2022-12-07 11:42:23 +0000
committerGitHub <noreply@github.com>2022-12-07 11:42:23 +0000
commita5bdb4a8e85f955ea660bd66b2c1c5990ab46c03 (patch)
tree9cc0fe9c6a7b7cd4728bafc21b5252372d131d52 /src/check_decl.cpp
parent521ed286321a30e5742a432effefb2c98b9484a7 (diff)
parentd88b052d2d9aa8fa012be314bd29d7ae311fc941 (diff)
Merge pull request #2208 from odin-lang/multiple-return-abi-experiment
Multiple Return ABI Changes and Improvements
Diffstat (limited to 'src/check_decl.cpp')
-rw-r--r--src/check_decl.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/check_decl.cpp b/src/check_decl.cpp
index bb56749af..0e41dbbb5 100644
--- a/src/check_decl.cpp
+++ b/src/check_decl.cpp
@@ -1544,8 +1544,12 @@ void check_proc_body(CheckerContext *ctx_, Token token, DeclInfo *decl, Type *ty
// NOTE(bill): Don't err here
}
+ GB_ASSERT(decl->defer_use_checked == false);
+
check_stmt_list(ctx, bs->stmts, Stmt_CheckScopeDecls);
+ decl->defer_use_checked = true;
+
for_array(i, bs->stmts) {
Ast *stmt = bs->stmts[i];
if (stmt->kind == Ast_ValueDecl) {
@@ -1580,6 +1584,7 @@ void check_proc_body(CheckerContext *ctx_, Token token, DeclInfo *decl, Type *ty
}
}
}
+
}
check_close_scope(ctx);