aboutsummaryrefslogtreecommitdiffhomepage
path: root/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'main.c')
-rw-r--r--main.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/main.c b/main.c
index 8b7e1c5..05d2a2e 100644
--- a/main.c
+++ b/main.c
@@ -1752,6 +1752,7 @@ void gen_for_stmt(struct CodeGen* g, struct AstNode* ast) {
if (ast->expr1) {
gen_expr(g, ast->expr1, GEN_RVAL);
+ printf(" pop rax\n");
}
printf(".Lbegin%d:\n", label);
gen_expr(g, ast->expr2, GEN_RVAL);