From 462d81430c8e8824899b3920dc02e367fd2c3a46 Mon Sep 17 00:00:00 2001 From: gingerBill Date: Sun, 5 Aug 2018 10:31:20 +0100 Subject: Fix map runtime issue regarding erasing a key --- src/ir.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'src/ir.cpp') diff --git a/src/ir.cpp b/src/ir.cpp index c59be047f..8d555c7b3 100644 --- a/src/ir.cpp +++ b/src/ir.cpp @@ -1753,6 +1753,7 @@ void ir_emit_defer_stmts(irProcedure *proc, irDeferExitKind kind, irBlock *block while (i --> 0) { irDefer d = proc->defer_stmts[i]; if (d.context_stack_count >= 0) { + GB_ASSERT(proc->context_stack.count >= d.context_stack_count); proc->context_stack.count = d.context_stack_count; } -- cgit v1.2.3