]> git.unchartedbackwaters.co.uk Git - francis/libjit.git/commitdiff
IfTail: fix a bug that caused the "then" case of an "if" to fall
authorRhys Weatherley <rweather@southern-storm.com.au>
Wed, 12 May 2004 00:22:30 +0000 (00:22 +0000)
committerRhys Weatherley <rweather@southern-storm.com.au>
Wed, 12 May 2004 00:22:30 +0000 (00:22 +0000)
through to the "else".

ChangeLog
dpas/dpas-parser.y

index b557b11bc4a95f5db64f2b4ca8bf4cb803775c82..93217ae30cfabc31f0d380639df50d7fbff415f2 100644 (file)
--- 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  <rweather@southern-storm.com.au>
 
        * include/jit/jit-insn.h, jit/jit-insn.c, jit/jit-interp.cpp,
index b606faf8b0b4dd880a578cba2c1b97690be7d110..1bb9ce1a4b45618487e3546a250052d6c8d1fe2a 100644 (file)
@@ -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))