aboutsummaryrefslogtreecommitdiff
path: root/src/check_expr.cpp
diff options
context:
space:
mode:
authorgingerBill <bill@gingerbill.org>2022-11-13 22:55:32 +0000
committergingerBill <bill@gingerbill.org>2022-11-13 22:55:32 +0000
commita705a2e38bee035d6800999ba6eddd82792594f7 (patch)
tree9beece2552d41ad12489e7cfaf73df80bbf6fb95 /src/check_expr.cpp
parent7dfbda58d9c51932fa91a04727b821860358289d (diff)
Minor improvement to multi return value reducing stack usage
Diffstat (limited to 'src/check_expr.cpp')
-rw-r--r--src/check_expr.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/check_expr.cpp b/src/check_expr.cpp
index c58aac609..c819267fd 100644
--- a/src/check_expr.cpp
+++ b/src/check_expr.cpp
@@ -6739,6 +6739,9 @@ ExprKind check_call_expr(CheckerContext *c, Operand *operand, Ast *call, Ast *pr
if (initial_entity != nullptr && initial_entity->kind == Entity_Procedure) {
if (initial_entity->Procedure.deferred_procedure.entity != nullptr) {
call->viral_state_flags |= ViralStateFlag_ContainsDeferredProcedure;
+ if (c->decl != nullptr) {
+ c->decl->defer_use_count += 1;
+ }
}
}