From 7d539a83fd55f7ced7657302054e099955b55ae2 Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Wed, 18 Apr 2018 01:28:24 -0400 Subject: - Initial Scheme back-end implementation. --- new-luxc/source/luxc/lang/translation/js/case.jvm.lux | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'new-luxc/source/luxc/lang/translation/js/case.jvm.lux') 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 45b6ec10e..82a8bb5c9 100644 --- a/new-luxc/source/luxc/lang/translation/js/case.jvm.lux +++ b/new-luxc/source/luxc/lang/translation/js/case.jvm.lux @@ -118,11 +118,11 @@ (^template [ ] (^code ( (~ [_ (#.Nat idx)]))) (meta/wrap (format "temp = " runtimeT.sum//get "(" peek-cursor "," (|> idx nat-to-int %i) "," ");" - "if(temp !== null) {" - (push-cursor "temp") + "if(temp == null) {" + fail-pattern-matching "}" "else {" - fail-pattern-matching + (push-cursor "temp") "}"))) (["lux case variant left" "null"] ["lux case variant right" "\"\""]) -- cgit v1.2.3