From: Rhys Weatherley Date: Wed, 12 May 2004 00:22:30 +0000 (+0000) Subject: IfTail: fix a bug that caused the "then" case of an "if" to fall X-Git-Tag: r.0.0.2~12 X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=680c45505f97594cd21827bdfd498c22c8987a51;p=francis%2Flibjit.git IfTail: fix a bug that caused the "then" case of an "if" to fall through to the "else". --- diff --git a/ChangeLog b/ChangeLog index b557b11..93217ae 100644 --- a/ChangeLog +++ b/ChangeLog @@ -9,6 +9,9 @@ dpas/dpas-types.h: add the "SameType" and "SameShape" builtins, to assist with unit testing type coercions. + * dpas/dpas-parser.y (IfTail): fix a bug that caused the "then" + case of an "if" to fall through to the "else". + 2004-05-11 Rhys Weatherley * include/jit/jit-insn.h, jit/jit-insn.c, jit/jit-interp.cpp, diff --git a/dpas/dpas-parser.y b/dpas/dpas-parser.y index b606faf..1bb9ce1 100644 --- a/dpas/dpas-parser.y +++ b/dpas/dpas-parser.y @@ -1786,7 +1786,7 @@ IfTail jit_label_t label = jit_label_undefined; /* Jump to the end of the "if" statement */ - if(jit_block_ends_in_dead + if(!jit_block_ends_in_dead (jit_block_previous(dpas_current_function(), 0))) { if(!jit_insn_branch(dpas_current_function(), &label))