diff options
Diffstat (limited to 'stdlib/source/lux/target/jvm/bytecode.lux')
-rw-r--r-- | stdlib/source/lux/target/jvm/bytecode.lux | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/stdlib/source/lux/target/jvm/bytecode.lux b/stdlib/source/lux/target/jvm/bytecode.lux index 6e24b790a..a319ef2a7 100644 --- a/stdlib/source/lux/target/jvm/bytecode.lux +++ b/stdlib/source/lux/target/jvm/bytecode.lux @@ -463,7 +463,7 @@ (import: java/lang/Double ["#::." - (#static doubleToRawLongBits #manual [double] int)]) + (#static doubleToRawLongBits #manual [double] long)]) (template [<name> <type> <constructor> <constant> <wide> <to_lux> <specializations>] [(def: #export (<name> value) @@ -511,7 +511,7 @@ (:coerce Int))) (def: negative_zero_float_bits - (|> -0.0 host.double_to_float ..float_bits)) + (|> -0.0 (:coerce java/lang/Double) host.double_to_float ..float_bits)) (def: #export (float value) (-> java/lang/Float (Bytecode Any)) @@ -548,7 +548,7 @@ (def: (arbitrary_double value) (-> java/lang/Double (Bytecode Any)) (do ..monad - [index (..lift (//constant/pool.double (//constant.double value)))] + [index (..lift (//constant/pool.double (//constant.double (:coerce Frac value))))] (..bytecode $0 $2 @_ _.ldc2_w/double [index]))) (def: double_bits @@ -557,14 +557,14 @@ (:coerce Int))) (def: negative_zero_double_bits - (..double_bits -0.0)) + (..double_bits (:coerce java/lang/Double -0.0))) (def: #export (double value) (-> java/lang/Double (Bytecode Any)) (if (i.= ..negative_zero_double_bits (..double_bits value)) (..arbitrary_double value) - (case value + (case (:coerce Frac value) (^template [<special> <instruction>] [<special> (..bytecode $0 $2 @_ <instruction> [])]) ([+0.0 _.dconst_0] |