From bcd3d9ee8f6797f758a2abea98d5cb6a74cc7df0 Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Fri, 15 Jun 2018 00:11:33 -0400 Subject: - WIP: Adjustments to new-luxc based on recent changes to stdlib. --- new-luxc/source/luxc/lang/translation/r/runtime.jvm.lux | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'new-luxc/source/luxc/lang/translation/r/runtime.jvm.lux') diff --git a/new-luxc/source/luxc/lang/translation/r/runtime.jvm.lux b/new-luxc/source/luxc/lang/translation/r/runtime.jvm.lux index 7cdc82064..7267494d5 100644 --- a/new-luxc/source/luxc/lang/translation/r/runtime.jvm.lux +++ b/new-luxc/source/luxc/lang/translation/r/runtime.jvm.lux @@ -28,17 +28,17 @@ (|> input (bit.and full-32) cap-32) (n/> half-32 input) - (|> post-32 (n/- input) nat-to-int (i/* -1)) + (|> post-32 (n/- input) .int (i/* -1)) ## else - (nat-to-int input))) + (.int input))) (def: high-32 (bit.logical-right-shift +32)) (def: low-32 (|>> (bit.and (hex "+FFFFFFFF")))) (def: #export (int value) (-> Int Expression) - (let [value (int-to-nat value) + (let [value (.nat value) high (|> value ..high-32 cap-32) low (|> value ..low-32 cap-32)] (r.named-list (list [//.int-high-field (r.int high)] @@ -58,7 +58,7 @@ (def: #export (variant tag last? value) (-> Nat Bool Expression Expression) - (variant' (r.int (nat-to-int tag)) + (variant' (r.int (.int tag)) (flag last?) value)) -- cgit v1.2.3