From 69fefab57c40f323d759dc444dbcebad15071585 Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Fri, 13 Jul 2018 22:01:32 -0400 Subject: Re-named "Bool" type to "Bit". --- .../luxc/lang/translation/jvm/procedure/host.jvm.lux | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) (limited to 'new-luxc/source/luxc/lang/translation/jvm/procedure/host.jvm.lux') diff --git a/new-luxc/source/luxc/lang/translation/jvm/procedure/host.jvm.lux b/new-luxc/source/luxc/lang/translation/jvm/procedure/host.jvm.lux index f6a0069f5..45cb67fb9 100644 --- a/new-luxc/source/luxc/lang/translation/jvm/procedure/host.jvm.lux +++ b/new-luxc/source/luxc/lang/translation/jvm/procedure/host.jvm.lux @@ -155,6 +155,10 @@ [double//% $i.DREM #$.Double #$.Double #$.Double] ) +(def: boolean-class ($t.class "java.lang.Boolean" (list))) +(def: falseI ($i.GETSTATIC "java.lang.Boolean" "FALSE" boolean-class)) +(def: trueI ($i.GETSTATIC "java.lang.Boolean" "TRUE" boolean-class)) + (do-template [ ] [(def: ( [xI yI]) @.Binary @@ -163,10 +167,10 @@ (|>> xI ($i.unwrap ) yI ($i.unwrap ) ( @then) - ($i.GETSTATIC "java.lang.Boolean" "FALSE" ($t.class "java.lang.Boolean" (list))) + falseI ($i.GOTO @end) ($i.label @then) - ($i.GETSTATIC "java.lang.Boolean" "TRUE" ($t.class "java.lang.Boolean" (list))) + trueI ($i.label @end))))] [int//= $i.IF_ICMPEQ #$.Int #$.Int #$.Boolean] @@ -186,10 +190,10 @@ ($i.int ) ($i.IF_ICMPEQ @then) - ($i.GETSTATIC "java.lang.Boolean" "FALSE" ($t.class "java.lang.Boolean" (list))) + falseI ($i.GOTO @end) ($i.label @then) - ($i.GETSTATIC "java.lang.Boolean" "TRUE" ($t.class "java.lang.Boolean" (list))) + trueI ($i.label @end))))] [long//= $i.LCMP 0 #$.Long #$.Long #$.Boolean] @@ -380,10 +384,10 @@ $i.with-label (function (_ @end)) (|>> objectI ($i.IFNULL @then) - ($i.GETSTATIC "java.lang.Boolean" "FALSE" ($t.class "java.lang.Boolean" (list))) + falseI ($i.GOTO @end) ($i.label @then) - ($i.GETSTATIC "java.lang.Boolean" "TRUE" ($t.class "java.lang.Boolean" (list))) + trueI ($i.label @end)))) (def: (object//synchronized [monitorI exprI]) -- cgit v1.2.3