From 981b92cfea68537b766dfacc53e45f39c9ba92f1 Mon Sep 17 00:00:00 2001 From: Christoph Mallon Date: Wed, 6 Apr 2011 15:27:06 +0200 Subject: [PATCH] Fix regression: Allow setting the current block to NULL. --- ir/ir/ircons.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ir/ir/ircons.c b/ir/ir/ircons.c index 0b765a41e..810f225bf 100644 --- a/ir/ir/ircons.c +++ b/ir/ir/ircons.c @@ -543,13 +543,13 @@ void add_immBlock_pred(ir_node *block, ir_node *jmp) void set_cur_block(ir_node *target) { - assert(current_ir_graph == get_irn_irg(target)); + assert(target == NULL || current_ir_graph == get_irn_irg(target)); current_ir_graph->current_block = target; } void set_r_cur_block(ir_graph *irg, ir_node *target) { - assert(irg == get_irn_irg(target)); + assert(target == NULL || irg == get_irn_irg(target)); irg->current_block = target; } -- 2.20.1