diff options
author | Eduardo Julian | 2018-05-06 00:45:45 -0400 |
---|---|---|
committer | Eduardo Julian | 2018-05-06 00:45:45 -0400 |
commit | 8787650c4b1641832db9df2c35bc3046e886220e (patch) | |
tree | 8c14799379226aa8452d39d91e9a56896db9187f /new-luxc/test | |
parent | 3c93d7a3aabaa49c67f9a498bc0d70f0af7f09d0 (diff) |
- Updated new-luxc to the latest stdlib changes.
Diffstat (limited to '')
17 files changed, 259 insertions, 290 deletions
diff --git a/new-luxc/test/test/luxc/common.lux b/new-luxc/test/test/luxc/common.lux index 633263243..b5754b088 100644 --- a/new-luxc/test/test/luxc/common.lux +++ b/new-luxc/test/test/luxc/common.lux @@ -14,41 +14,41 @@ [".T_jvm" eval] [".T_jvm" runtime] [".T_jvm" statement]) - ## [js] - ## (js [".T_js" expression] - ## [".T_js" eval] - ## [".T_js" runtime] - ## [".T_js" statement]) - ## [lua] - ## (lua [".T_lua" expression] - ## [".T_lua" eval] - ## [".T_lua" runtime] - ## [".T_lua" statement]) - ## [ruby] - ## (ruby [".T_ruby" expression] - ## [".T_ruby" eval] - ## [".T_ruby" runtime] - ## [".T_ruby" statement]) - ## [python] - ## (python [".T_python" expression] - ## [".T_python" eval] - ## [".T_python" runtime] - ## [".T_python" statement]) - ## [r] - ## (r [".T_r" expression] - ## [".T_r" eval] - ## [".T_r" runtime] - ## [".T_r" statement]) - ## [scheme] - ## (scheme [".T_scheme" expression] - ## [".T_scheme" eval] - ## [".T_scheme" runtime] - ## [".T_scheme" statement]) - ## [common-lisp] - ## (common-lisp [".T_common-lisp" expression] - ## [".T_common-lisp" eval] - ## [".T_common-lisp" runtime] - ## [".T_common-lisp" statement]) + [js] + (js [".T_js" expression] + [".T_js" eval] + [".T_js" runtime] + [".T_js" statement]) + [lua] + (lua [".T_lua" expression] + [".T_lua" eval] + [".T_lua" runtime] + [".T_lua" statement]) + [ruby] + (ruby [".T_ruby" expression] + [".T_ruby" eval] + [".T_ruby" runtime] + [".T_ruby" statement]) + [python] + (python [".T_python" expression] + [".T_python" eval] + [".T_python" runtime] + [".T_python" statement]) + [r] + (r [".T_r" expression] + [".T_r" eval] + [".T_r" runtime] + [".T_r" statement]) + [scheme] + (scheme [".T_scheme" expression] + [".T_scheme" eval] + [".T_scheme" runtime] + [".T_scheme" statement]) + [common-lisp] + (common-lisp [".T_common-lisp" expression] + [".T_common-lisp" eval] + [".T_common-lisp" runtime] + [".T_common-lisp" statement]) [php] (php [".T_php" expression] [".T_php" eval] @@ -67,13 +67,13 @@ (wrap (initL.compiler host))))] [init-jvm &host.init-host] - ## [init-js js.init] - ## [init-lua lua.init] - ## [init-ruby ruby.init] - ## [init-python python.init] - ## [init-r r.init] - ## [init-scheme scheme.init] - ## [init-common-lisp common-lisp.init] + [init-js js.init] + [init-lua lua.init] + [init-ruby ruby.init] + [init-python python.init] + [init-r r.init] + [init-scheme scheme.init] + [init-common-lisp common-lisp.init] [init-php php.init] ) @@ -106,26 +106,26 @@ (def: #export run-jvm (runner runtimeT_jvm.translate expressionT_jvm.translate evalT_jvm.eval init-jvm)) (def: #export def-jvm (definer runtimeT_jvm.translate expressionT_jvm.translate evalT_jvm.eval init-jvm statementT_jvm.translate-def)) -## (def: #export run-js (runner runtimeT_js.translate expressionT_js.translate evalT_js.eval init-js)) -## (def: #export def-js (definer runtimeT_js.translate expressionT_js.translate evalT_js.eval init-js statementT_js.translate-def)) +(def: #export run-js (runner runtimeT_js.translate expressionT_js.translate evalT_js.eval init-js)) +(def: #export def-js (definer runtimeT_js.translate expressionT_js.translate evalT_js.eval init-js statementT_js.translate-def)) -## (def: #export run-lua (runner runtimeT_lua.translate expressionT_lua.translate evalT_lua.eval init-lua)) -## (def: #export def-lua (definer runtimeT_lua.translate expressionT_lua.translate evalT_lua.eval init-lua statementT_lua.translate-def)) +(def: #export run-lua (runner runtimeT_lua.translate expressionT_lua.translate evalT_lua.eval init-lua)) +(def: #export def-lua (definer runtimeT_lua.translate expressionT_lua.translate evalT_lua.eval init-lua statementT_lua.translate-def)) -## (def: #export run-ruby (runner runtimeT_ruby.translate expressionT_ruby.translate evalT_ruby.eval init-ruby)) -## (def: #export def-ruby (definer runtimeT_ruby.translate expressionT_ruby.translate evalT_ruby.eval init-ruby statementT_ruby.translate-def)) +(def: #export run-ruby (runner runtimeT_ruby.translate expressionT_ruby.translate evalT_ruby.eval init-ruby)) +(def: #export def-ruby (definer runtimeT_ruby.translate expressionT_ruby.translate evalT_ruby.eval init-ruby statementT_ruby.translate-def)) -## (def: #export run-python (runner runtimeT_python.translate expressionT_python.translate evalT_python.eval init-python)) -## (def: #export def-python (definer runtimeT_python.translate expressionT_python.translate evalT_python.eval init-python statementT_python.translate-def)) +(def: #export run-python (runner runtimeT_python.translate expressionT_python.translate evalT_python.eval init-python)) +(def: #export def-python (definer runtimeT_python.translate expressionT_python.translate evalT_python.eval init-python statementT_python.translate-def)) -## (def: #export run-r (runner runtimeT_r.translate expressionT_r.translate evalT_r.eval init-r)) -## (def: #export def-r (definer runtimeT_r.translate expressionT_r.translate evalT_r.eval init-r statementT_r.translate-def)) +(def: #export run-r (runner runtimeT_r.translate expressionT_r.translate evalT_r.eval init-r)) +(def: #export def-r (definer runtimeT_r.translate expressionT_r.translate evalT_r.eval init-r statementT_r.translate-def)) -## (def: #export run-scheme (runner runtimeT_scheme.translate expressionT_scheme.translate evalT_scheme.eval init-scheme)) -## (def: #export def-scheme (definer runtimeT_scheme.translate expressionT_scheme.translate evalT_scheme.eval init-scheme statementT_scheme.translate-def)) +(def: #export run-scheme (runner runtimeT_scheme.translate expressionT_scheme.translate evalT_scheme.eval init-scheme)) +(def: #export def-scheme (definer runtimeT_scheme.translate expressionT_scheme.translate evalT_scheme.eval init-scheme statementT_scheme.translate-def)) -## (def: #export run-common-lisp (runner runtimeT_common-lisp.translate expressionT_common-lisp.translate evalT_common-lisp.eval init-common-lisp)) -## (def: #export def-common-lisp (definer runtimeT_common-lisp.translate expressionT_common-lisp.translate evalT_common-lisp.eval init-common-lisp statementT_common-lisp.translate-def)) +(def: #export run-common-lisp (runner runtimeT_common-lisp.translate expressionT_common-lisp.translate evalT_common-lisp.eval init-common-lisp)) +(def: #export def-common-lisp (definer runtimeT_common-lisp.translate expressionT_common-lisp.translate evalT_common-lisp.eval init-common-lisp statementT_common-lisp.translate-def)) (def: #export run-php (runner runtimeT_php.translate expressionT_php.translate evalT_php.eval init-php)) (def: #export def-php (definer runtimeT_php.translate expressionT_php.translate evalT_php.eval init-php statementT_php.translate-def)) diff --git a/new-luxc/test/test/luxc/lang/analysis/case.lux b/new-luxc/test/test/luxc/lang/analysis/case.lux index bcb9943bb..63dd60e14 100644 --- a/new-luxc/test/test/luxc/lang/analysis/case.lux +++ b/new-luxc/test/test/luxc/lang/analysis/case.lux @@ -10,7 +10,7 @@ [text "T/" Eq<Text>] text/format (coll [list "L/" Monad<List>] - ["S" set])) + (set ["set" unordered]))) ["r" math/random "r/" Monad<Random>] [macro #+ Monad<Meta>] (macro [code]) @@ -136,13 +136,14 @@ variant-name (r.text +5) record-name (|> (r.text +5) (r.filter (|>> (T/= variant-name) not))) size (|> r.nat (:: @ map (|>> (n/% +10) (n/max +2)))) - variant-tags (|> (r.set text.Hash<Text> size (r.text +5)) (:: @ map S.to-list)) - record-tags (|> (r.set text.Hash<Text> size (r.text +5)) (:: @ map S.to-list)) + variant-tags (|> (r.set text.Hash<Text> size (r.text +5)) (:: @ map set.to-list)) + record-tags (|> (r.set text.Hash<Text> size (r.text +5)) (:: @ map set.to-list)) primitivesTC (r.list size gen-primitive) #let [primitivesT (L/map product.left primitivesTC) primitivesC (L/map product.right primitivesTC) - variant-tags+ (L/map (|>> [module-name] code.tag) variant-tags) - record-tags+ (L/map (|>> [module-name] code.tag) record-tags) + code-tag (|>> [module-name] code.tag) + variant-tags+ (L/map code-tag variant-tags) + record-tags+ (L/map code-tag record-tags) variantTC (list.zip2 variant-tags+ primitivesC)] inputC (input variant-tags+ record-tags+ primitivesC) [outputT outputC] gen-primitive @@ -165,63 +166,31 @@ (list (let [[_pattern _body] (maybe.assume (list.nth heterogeneous-idx exhaustive-branchesC))] [_pattern heterogeneousC])) (list.drop (n/inc heterogeneous-idx) exhaustive-branchesC))) - ]] + analyse-pm (|>> (@.analyse-case analyse inputC) + (&.with-type outputT) + &.with-scope + (do Monad<Meta> + [_ (@module.declare-tags variant-tags false + (#.Named [module-name variant-name] + (type.variant primitivesT))) + _ (@module.declare-tags record-tags false + (#.Named [module-name record-name] + (type.tuple primitivesT)))]) + (@module.with-module +0 module-name))]] ($_ seq (test "Will reject empty pattern-matching (no branches)." - (|> (&.with-scope - (&.with-type outputT - (@.analyse-case analyse inputC (list)))) + (|> (analyse-pm (list)) check-failure)) (test "Can analyse exhaustive pattern-matching." - (|> (@module.with-module +0 module-name - (do Monad<Meta> - [_ (@module.declare-tags variant-tags false - (#.Named [module-name variant-name] - (type.variant primitivesT))) - _ (@module.declare-tags record-tags false - (#.Named [module-name record-name] - (type.tuple primitivesT)))] - (&.with-scope - (&.with-type outputT - (@.analyse-case analyse inputC exhaustive-branchesC))))) + (|> (analyse-pm exhaustive-branchesC) check-success)) (test "Will reject non-exhaustive pattern-matching." - (|> (@module.with-module +0 module-name - (do Monad<Meta> - [_ (@module.declare-tags variant-tags false - (#.Named [module-name variant-name] - (type.variant primitivesT))) - _ (@module.declare-tags record-tags false - (#.Named [module-name record-name] - (type.tuple primitivesT)))] - (&.with-scope - (&.with-type outputT - (@.analyse-case analyse inputC non-exhaustive-branchesC))))) + (|> (analyse-pm non-exhaustive-branchesC) check-failure)) (test "Will reject redundant pattern-matching." - (|> (@module.with-module +0 module-name - (do Monad<Meta> - [_ (@module.declare-tags variant-tags false - (#.Named [module-name variant-name] - (type.variant primitivesT))) - _ (@module.declare-tags record-tags false - (#.Named [module-name record-name] - (type.tuple primitivesT)))] - (&.with-scope - (&.with-type outputT - (@.analyse-case analyse inputC redundant-branchesC))))) + (|> (analyse-pm redundant-branchesC) check-failure)) (test "Will reject pattern-matching if the bodies of the branches do not all have the same type." - (|> (@module.with-module +0 module-name - (do Monad<Meta> - [_ (@module.declare-tags variant-tags false - (#.Named [module-name variant-name] - (type.variant primitivesT))) - _ (@module.declare-tags record-tags false - (#.Named [module-name record-name] - (type.tuple primitivesT)))] - (&.with-scope - (&.with-type outputT - (@.analyse-case analyse inputC heterogeneous-branchesC))))) + (|> (analyse-pm heterogeneous-branchesC) check-failure)) )))) diff --git a/new-luxc/test/test/luxc/lang/analysis/common.lux b/new-luxc/test/test/luxc/lang/analysis/common.lux index cf213ccef..35212e55d 100644 --- a/new-luxc/test/test/luxc/lang/analysis/common.lux +++ b/new-luxc/test/test/luxc/lang/analysis/common.lux @@ -21,7 +21,7 @@ [<generators> (do-template [<type> <code-wrapper> <value-gen>] [(r.seq (r/wrap <type>) (r/map <code-wrapper> <value-gen>))] - [Unit code.tuple (r.list +0 gen-unit)] + [Top code.tuple (r.list +0 gen-unit)] [Bool code.bool r.bool] [Nat code.nat r.nat] [Int code.int r.int] diff --git a/new-luxc/test/test/luxc/lang/analysis/primitive.lux b/new-luxc/test/test/luxc/lang/analysis/primitive.lux index 572766820..aa3e30aab 100644 --- a/new-luxc/test/test/luxc/lang/analysis/primitive.lux +++ b/new-luxc/test/test/luxc/lang/analysis/primitive.lux @@ -34,7 +34,7 @@ @.analyse-unit) (macro.run (io.run init-jvm)) (case> (^ (#e.Success [_type (^code [])])) - (type/= Unit _type) + (type/= Top _type) _ false)) diff --git a/new-luxc/test/test/luxc/lang/analysis/procedure/common.lux b/new-luxc/test/test/luxc/lang/analysis/procedure/common.lux index 807a9f3d8..6d176e0cd 100644 --- a/new-luxc/test/test/luxc/lang/analysis/procedure/common.lux +++ b/new-luxc/test/test/luxc/lang/analysis/procedure/common.lux @@ -366,12 +366,12 @@ (test "Can run an IO computation concurrently." (check-success+ "lux process future" (list (` ("lux function" (~' _) (~' _) (~ primC)))) - Unit)) + Top)) (test "Can schedule an IO computation to run concurrently at some future time." (check-success+ "lux process schedule" (list timeC (` ("lux function" (~' _) (~' _) (~ primC)))) - Unit)) + Top)) )))) (context: "IO procedures" @@ -381,7 +381,7 @@ exitC (|> r.int (:: @ map code.int))] ($_ seq (test "Can log messages to standard output." - (check-success+ "lux io log" (list logC) Unit)) + (check-success+ "lux io log" (list logC) Top)) (test "Can throw a run-time error." (check-success+ "lux io error" (list logC) Bottom)) (test "Can exit the program." diff --git a/new-luxc/test/test/luxc/lang/analysis/procedure/host.jvm.lux b/new-luxc/test/test/luxc/lang/analysis/procedure/host.jvm.lux index 77fb71d27..0c27d14d1 100644 --- a/new-luxc/test/test/luxc/lang/analysis/procedure/host.jvm.lux +++ b/new-luxc/test/test/luxc/lang/analysis/procedure/host.jvm.lux @@ -11,7 +11,7 @@ text/format (coll [array] [list "list/" Fold<List>] - [dict])) + (dictionary ["dict" unordered]))) ["r" math/random "r/" Monad<Random>] [macro #+ Monad<Meta>] (macro [code]) @@ -415,14 +415,14 @@ (code.text "allHtmlFlavor") (`' ("lux check" (+0 "java.awt.datatransfer.DataFlavor" (+0)) ("jvm object null")))) - Unit)) + Top)) (test "jvm member static put (final)" (failure "jvm member static put" (list (code.text "java.lang.System") (code.text "out") (`' ("lux check" (+0 "java.io.PrintStream" (+0)) ("jvm object null")))) - Unit)) + Top)) (test "jvm member static put (inheritance in)" (success "jvm member static put" (list (code.text "java.awt.datatransfer.DataFlavor") @@ -430,7 +430,7 @@ (`' ("jvm object cast" ("lux check" (+0 "javax.activation.ActivationDataFlavor" (+0)) ("jvm object null"))))) - Unit)) + Top)) )) (context: "Member [Virtual Field]." diff --git a/new-luxc/test/test/luxc/lang/analysis/reference.lux b/new-luxc/test/test/luxc/lang/analysis/reference.lux index 0ab23600b..9ce4a51c1 100644 --- a/new-luxc/test/test/luxc/lang/analysis/reference.lux +++ b/new-luxc/test/test/luxc/lang/analysis/reference.lux @@ -40,7 +40,7 @@ (|> (do Monad<Meta> [_ (&module.create +0 module-name) _ (&module.define [module-name var-name] - [ref-type (' {}) (:! Void [])])] + [ref-type (' {}) (:! Bottom [])])] (@common.with-unknown-type (@.analyse-reference [module-name var-name]))) (macro.run (io.run init-jvm)) diff --git a/new-luxc/test/test/luxc/lang/analysis/structure.lux b/new-luxc/test/test/luxc/lang/analysis/structure.lux index cdef25448..0a94e37da 100644 --- a/new-luxc/test/test/luxc/lang/analysis/structure.lux +++ b/new-luxc/test/test/luxc/lang/analysis/structure.lux @@ -10,7 +10,7 @@ [text] text/format (coll [list "list/" Functor<List>] - ["S" set])) + (set ["set" unordered]))) ["r" math/random "r/" Monad<Random>] [macro] (macro [code]) @@ -216,7 +216,7 @@ (<| (times +100) (do @ [size (|> r.nat (:: @ map (|>> (n/% +10) (n/max +2)))) - tags (|> (r.set text.Hash<Text> size (r.text +5)) (:: @ map S.to-list)) + tags (|> (r.set text.Hash<Text> size (r.text +5)) (:: @ map set.to-list)) choice (|> r.nat (:: @ map (n/% size))) other-choice (|> r.nat (:: @ map (n/% size)) (r.filter (|>> (n/= choice) not))) primitives (r.list size gen-primitive) @@ -279,7 +279,7 @@ (<| (times +100) (do @ [size (|> r.nat (:: @ map (|>> (n/% +10) (n/max +2)))) - tags (|> (r.set text.Hash<Text> size (r.text +5)) (:: @ map S.to-list)) + tags (|> (r.set text.Hash<Text> size (r.text +5)) (:: @ map set.to-list)) primitives (r.list size gen-primitive) module-name (r.text +5) type-name (r.text +5) diff --git a/new-luxc/test/test/luxc/lang/synthesis/function.lux b/new-luxc/test/test/luxc/lang/synthesis/function.lux index c73793c8d..fa29b4284 100644 --- a/new-luxc/test/test/luxc/lang/synthesis/function.lux +++ b/new-luxc/test/test/luxc/lang/synthesis/function.lux @@ -8,8 +8,8 @@ [number] text/format (coll [list "list/" Functor<List> Fold<List>] - [dict #+ Dict] - [set])) + (dictionary ["dict" unordered #+ Dict]) + (set ["set" unordered]))) (macro [code]) ["r" math/random "r/" Monad<Random>] test) diff --git a/new-luxc/test/test/luxc/lang/synthesis/loop.lux b/new-luxc/test/test/luxc/lang/synthesis/loop.lux index 5d2db50a8..23641780f 100644 --- a/new-luxc/test/test/luxc/lang/synthesis/loop.lux +++ b/new-luxc/test/test/luxc/lang/synthesis/loop.lux @@ -5,7 +5,7 @@ (data [bool "bool/" Eq<Bool>] [number] (coll [list "list/" Functor<List> Fold<List>] - ["s" set]) + (set ["set" unordered])) text/format) (macro [code]) ["r" math/random "r/" Monad<Random>] @@ -58,7 +58,7 @@ [inputA (|> r.nat (:: @ map code.nat)) num-cases (|> r.nat (:: @ map (|>> (n/% +10) (n/max +1)))) tests (|> (r.set number.Hash<Nat> num-cases r.nat) - (:: @ map (|>> s.to-list (list/map code.nat)))) + (:: @ map (|>> set.to-list (list/map code.nat)))) #let [bad-bodies (list.repeat num-cases (' []))] good-body (gen-body arity output) where-to-set (|> r.nat (:: @ map (n/% num-cases))) diff --git a/new-luxc/test/test/luxc/lang/translation/case.lux b/new-luxc/test/test/luxc/lang/translation/case.lux index 2964edbe4..44df51014 100644 --- a/new-luxc/test/test/luxc/lang/translation/case.lux +++ b/new-luxc/test/test/luxc/lang/translation/case.lux @@ -97,37 +97,37 @@ false)))) ))) -## (context: "[JVM] Pattern-matching." -## (<| (times +100) -## (pattern-matching-spec run-jvm))) +(context: "[JVM] Pattern-matching." + (<| (times +100) + (pattern-matching-spec run-jvm))) -## (context: "[JS] Pattern-matching." -## (<| (times +100) -## (pattern-matching-spec run-js))) +(context: "[JS] Pattern-matching." + (<| (times +100) + (pattern-matching-spec run-js))) -## (context: "[Lua] Pattern-matching." -## (<| (times +100) -## (pattern-matching-spec run-lua))) +(context: "[Lua] Pattern-matching." + (<| (times +100) + (pattern-matching-spec run-lua))) -## (context: "[Ruby] Pattern-matching." -## (<| (times +100) -## (pattern-matching-spec run-ruby))) +(context: "[Ruby] Pattern-matching." + (<| (times +100) + (pattern-matching-spec run-ruby))) -## (context: "[Python] Function." -## (<| (times +100) -## (pattern-matching-spec run-python))) +(context: "[Python] Function." + (<| (times +100) + (pattern-matching-spec run-python))) -## (context: "[R] Pattern-matching." -## (<| (times +100) -## (pattern-matching-spec run-r))) +(context: "[R] Pattern-matching." + (<| (times +100) + (pattern-matching-spec run-r))) -## (context: "[Scheme] Pattern-matching." -## (<| (times +100) -## (pattern-matching-spec run-scheme))) +(context: "[Scheme] Pattern-matching." + (<| (times +100) + (pattern-matching-spec run-scheme))) -## (context: "[Common Lisp] Pattern-matching." -## (<| (times +100) -## (pattern-matching-spec run-common-lisp))) +(context: "[Common Lisp] Pattern-matching." + (<| (times +100) + (pattern-matching-spec run-common-lisp))) (context: "[PHP] Pattern-matching." (<| (times +100) diff --git a/new-luxc/test/test/luxc/lang/translation/common.lux b/new-luxc/test/test/luxc/lang/translation/common.lux index dbd7b6d50..be552f1f0 100644 --- a/new-luxc/test/test/luxc/lang/translation/common.lux +++ b/new-luxc/test/test/luxc/lang/translation/common.lux @@ -580,37 +580,37 @@ (process-spec run) )) -## (context: "[JVM] Common procedures." -## (<| (times +100) -## (all-specs run-jvm))) +(context: "[JVM] Common procedures." + (<| (times +100) + (all-specs run-jvm))) -## (context: "[JS] Common procedures." -## (<| (times +100) -## (all-specs run-js))) +(context: "[JS] Common procedures." + (<| (times +100) + (all-specs run-js))) -## (context: "[Lua] Common procedures." -## (<| (times +100) -## (all-specs run-lua))) +(context: "[Lua] Common procedures." + (<| (times +100) + (all-specs run-lua))) -## (context: "[Ruby] Common procedures." -## (<| (times +100) -## (all-specs run-ruby))) +(context: "[Ruby] Common procedures." + (<| (times +100) + (all-specs run-ruby))) -## (context: "[Python] Common procedures." -## (<| (times +100) -## (all-specs run-python))) +(context: "[Python] Common procedures." + (<| (times +100) + (all-specs run-python))) -## (context: "[R] Common procedures." -## (<| (times +100) -## (all-specs run-r))) +(context: "[R] Common procedures." + (<| (times +100) + (all-specs run-r))) -## (context: "[Scheme] Common procedures." -## (<| (times +100) -## (all-specs run-scheme))) +(context: "[Scheme] Common procedures." + (<| (times +100) + (all-specs run-scheme))) -## (context: "[Common Lisp] Common procedures." -## (<| (times +100) -## (all-specs run-common-lisp))) +(context: "[Common Lisp] Common procedures." + (<| (times +100) + (all-specs run-common-lisp))) (context: "[PHP] Common procedures." (<| (times +100) diff --git a/new-luxc/test/test/luxc/lang/translation/function.lux b/new-luxc/test/test/luxc/lang/translation/function.lux index f671f2503..69cd174dd 100644 --- a/new-luxc/test/test/luxc/lang/translation/function.lux +++ b/new-luxc/test/test/luxc/lang/translation/function.lux @@ -91,37 +91,37 @@ false)))))) ))) -## (context: "[JVM] Function." -## (<| (times +100) -## (function-spec run-jvm))) +(context: "[JVM] Function." + (<| (times +100) + (function-spec run-jvm))) -## (context: "[JS] Function." -## (<| (times +100) -## (function-spec run-js))) +(context: "[JS] Function." + (<| (times +100) + (function-spec run-js))) -## (context: "[Lua] Function." -## (<| (times +100) -## (function-spec run-lua))) +(context: "[Lua] Function." + (<| (times +100) + (function-spec run-lua))) -## (context: "[Ruby] Function." -## (<| (times +100) -## (function-spec run-ruby))) +(context: "[Ruby] Function." + (<| (times +100) + (function-spec run-ruby))) -## (context: "[Python] Function." -## (<| (times +100) -## (function-spec run-python))) +(context: "[Python] Function." + (<| (times +100) + (function-spec run-python))) -## (context: "[R] Function." -## (<| (times +100) -## (function-spec run-r))) +(context: "[R] Function." + (<| (times +100) + (function-spec run-r))) -## (context: "[Scheme] Function." -## (<| (times +100) -## (function-spec run-scheme))) +(context: "[Scheme] Function." + (<| (times +100) + (function-spec run-scheme))) -## (context: "[Common Lisp] Function." -## (<| (times +100) -## (function-spec run-common-lisp))) +(context: "[Common Lisp] Function." + (<| (times +100) + (function-spec run-common-lisp))) (context: "[PHP] Function." (<| (times +100) diff --git a/new-luxc/test/test/luxc/lang/translation/primitive.lux b/new-luxc/test/test/luxc/lang/translation/primitive.lux index b9454ce24..e69590975 100644 --- a/new-luxc/test/test/luxc/lang/translation/primitive.lux +++ b/new-luxc/test/test/luxc/lang/translation/primitive.lux @@ -56,37 +56,37 @@ ["text" Text code.text %text% text/=])) )))) -## (context: "[JVM] Primitives." -## (<| (times +100) -## (spec run-jvm))) +(context: "[JVM] Primitives." + (<| (times +100) + (spec run-jvm))) -## (context: "[JS] Primitives." -## (<| (times +100) -## (spec run-js))) +(context: "[JS] Primitives." + (<| (times +100) + (spec run-js))) -## (context: "[Lua] Primitives." -## (<| (times +100) -## (spec run-lua))) +(context: "[Lua] Primitives." + (<| (times +100) + (spec run-lua))) -## (context: "[Ruby] Primitives." -## (<| (times +100) -## (spec run-ruby))) +(context: "[Ruby] Primitives." + (<| (times +100) + (spec run-ruby))) -## (context: "[Python] Primitives." -## (<| (times +100) -## (spec run-python))) +(context: "[Python] Primitives." + (<| (times +100) + (spec run-python))) -## (context: "[R] Primitives." -## (<| (times +100) -## (spec run-r))) +(context: "[R] Primitives." + (<| (times +100) + (spec run-r))) -## (context: "[Scheme] Primitives." -## (<| (times +100) -## (spec run-scheme))) +(context: "[Scheme] Primitives." + (<| (times +100) + (spec run-scheme))) -## (context: "[Common Lisp] Primitives." -## (<| (times +100) -## (spec run-common-lisp))) +(context: "[Common Lisp] Primitives." + (<| (times +100) + (spec run-common-lisp))) (context: "[PHP] Primitives." (<| (times +100) diff --git a/new-luxc/test/test/luxc/lang/translation/reference.lux b/new-luxc/test/test/luxc/lang/translation/reference.lux index 7364e33eb..d6c848c27 100644 --- a/new-luxc/test/test/luxc/lang/translation/reference.lux +++ b/new-luxc/test/test/luxc/lang/translation/reference.lux @@ -70,37 +70,37 @@ (seq (definitions-spec define) (variables-spec run))) -## (context: "[JVM] References." -## (<| (times +100) -## (references-spec run-jvm def-jvm))) +(context: "[JVM] References." + (<| (times +100) + (references-spec run-jvm def-jvm))) -## (context: "[JS] References." -## (<| (times +100) -## (references-spec run-js def-js))) +(context: "[JS] References." + (<| (times +100) + (references-spec run-js def-js))) -## (context: "[Lua] References." -## (<| (times +100) -## (references-spec run-lua def-lua))) +(context: "[Lua] References." + (<| (times +100) + (references-spec run-lua def-lua))) -## (context: "[Ruby] References." -## (<| (times +100) -## (references-spec run-ruby def-ruby))) +(context: "[Ruby] References." + (<| (times +100) + (references-spec run-ruby def-ruby))) -## (context: "[Python] References." -## (<| (times +100) -## (references-spec run-python def-python))) +(context: "[Python] References." + (<| (times +100) + (references-spec run-python def-python))) -## (context: "[R] References." -## (<| (times +100) -## (references-spec run-r def-r))) +(context: "[R] References." + (<| (times +100) + (references-spec run-r def-r))) -## (context: "[Scheme] References." -## (<| (times +100) -## (references-spec run-scheme def-scheme))) +(context: "[Scheme] References." + (<| (times +100) + (references-spec run-scheme def-scheme))) -## (context: "[Common Lisp] References." -## (<| (times +100) -## (references-spec run-common-lisp def-common-lisp))) +(context: "[Common Lisp] References." + (<| (times +100) + (references-spec run-common-lisp def-common-lisp))) (context: "[PHP] References." (<| (times +100) diff --git a/new-luxc/test/test/luxc/lang/translation/structure.lux b/new-luxc/test/test/luxc/lang/translation/structure.lux index 0619d6894..2ca57cbac 100644 --- a/new-luxc/test/test/luxc/lang/translation/structure.lux +++ b/new-luxc/test/test/luxc/lang/translation/structure.lux @@ -77,37 +77,37 @@ (tuples-spec run) (variants-spec run))) -## (context: "[JVM] Structures." -## (<| (times +100) -## (structure-spec run-jvm))) +(context: "[JVM] Structures." + (<| (times +100) + (structure-spec run-jvm))) -## (context: "[JS] Structures." -## (<| (times +100) -## (structure-spec run-js))) +(context: "[JS] Structures." + (<| (times +100) + (structure-spec run-js))) -## (context: "[Lua] Structures." -## (<| (times +100) -## (structure-spec run-lua))) +(context: "[Lua] Structures." + (<| (times +100) + (structure-spec run-lua))) -## (context: "[Ruby] Structures." -## (<| (times +100) -## (structure-spec run-ruby))) +(context: "[Ruby] Structures." + (<| (times +100) + (structure-spec run-ruby))) -## (context: "[Python] Structures." -## (<| (times +100) -## (structure-spec run-python))) +(context: "[Python] Structures." + (<| (times +100) + (structure-spec run-python))) -## (context: "[R] Structures." -## (<| (times +100) -## (structure-spec run-r))) +(context: "[R] Structures." + (<| (times +100) + (structure-spec run-r))) -## (context: "[Scheme] Structures." -## (<| (times +100) -## (structure-spec run-scheme))) +(context: "[Scheme] Structures." + (<| (times +100) + (structure-spec run-scheme))) -## (context: "[Common Lisp] Structures." -## (<| (times +100) -## (structure-spec run-common-lisp))) +(context: "[Common Lisp] Structures." + (<| (times +100) + (structure-spec run-common-lisp))) (context: "[PHP] Structures." (<| (times +100) diff --git a/new-luxc/test/tests.lux b/new-luxc/test/tests.lux index 586869c45..b6e6f3ca8 100644 --- a/new-luxc/test/tests.lux +++ b/new-luxc/test/tests.lux @@ -5,27 +5,27 @@ (concurrency [promise]) [cli #+ program:] [test]) - (test (luxc (lang ## (analysis ["_.A" primitive] - ## ["_.A" structure] - ## ["_.A" reference] - ## ["_.A" case] - ## ["_.A" function] - ## ["_.A" type] - ## (procedure ["_.A" common] - ## ["_.A" host])) - ## (synthesis ["_.S" primitive] - ## ["_.S" structure] - ## (case ["_.S" special]) - ## ["_.S" function] - ## ["_.S" procedure] - ## ["_.S" loop]) - (translation ## ["_.T" primitive] - ## ["_.T" structure] - ## ["_.T" function] - ## ["_.T" reference] - ## ["_.T" case] + (test (luxc (lang (analysis ["_.A" primitive] + ["_.A" structure] + ["_.A" reference] + ["_.A" case] + ["_.A" function] + ["_.A" type] + (procedure ["_.A" common] + ["_.A" host])) + (synthesis ["_.S" primitive] + ["_.S" structure] + (case ["_.S" special]) + ["_.S" function] + ["_.S" procedure] + ["_.S" loop]) + (translation ["_.T" primitive] + ["_.T" structure] + ["_.T" function] + ["_.T" reference] + ["_.T" case] ["_.T" common] - ## ["_.T" jvm] + ["_.T" jvm] ## ["_.T" js] ## ["_.T" lua] ## ["_.T" ruby] |