diff options
Diffstat (limited to 'new-luxc/source/luxc/lang/translation/js/case.jvm.lux')
-rw-r--r-- | new-luxc/source/luxc/lang/translation/js/case.jvm.lux | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/new-luxc/source/luxc/lang/translation/js/case.jvm.lux b/new-luxc/source/luxc/lang/translation/js/case.jvm.lux index 82a8bb5c9..3abd8c55c 100644 --- a/new-luxc/source/luxc/lang/translation/js/case.jvm.lux +++ b/new-luxc/source/luxc/lang/translation/js/case.jvm.lux @@ -31,7 +31,7 @@ [valueJS (translate valueS)] (wrap (list/fold (function (_ [idx tail?] source) (let [method (if tail? runtimeT.product//right runtimeT.product//left)] - (format method "(" source "," (|> idx nat-to-int %i) ")"))) + (format method "(" source "," (|> idx .int %i) ")"))) (format "(" valueJS ")") path)))) @@ -111,13 +111,13 @@ (^template [<pm> <getter>] (^code (<pm> (~ [_ (#.Nat idx)]))) - (meta/wrap (push-cursor (format <getter> "(" peek-cursor "," (|> idx nat-to-int %i) ")")))) + (meta/wrap (push-cursor (format <getter> "(" peek-cursor "," (|> idx .int %i) ")")))) (["lux case tuple left" runtimeT.product//left] ["lux case tuple right" runtimeT.product//right]) (^template [<pm> <flag>] (^code (<pm> (~ [_ (#.Nat idx)]))) - (meta/wrap (format "temp = " runtimeT.sum//get "(" peek-cursor "," (|> idx nat-to-int %i) "," <flag> ");" + (meta/wrap (format "temp = " runtimeT.sum//get "(" peek-cursor "," (|> idx .int %i) "," <flag> ");" "if(temp == null) {" fail-pattern-matching "}" |