aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source
diff options
context:
space:
mode:
authorEduardo Julian2019-03-15 00:23:49 -0400
committerEduardo Julian2019-03-15 00:23:49 -0400
commitf9d4d316ef9666f6b122b0eec8180351216e95f8 (patch)
tree2a66da0c7552dcb3642ba37afd53f1bef44eef41 /stdlib/source
parent9449d89f611ba3192373fdeb6848d02707ff1292 (diff)
Changed the convention for the structure opening separator from "/" to ";", to avoid confusion since "/" is used for relative module paths.
Diffstat (limited to 'stdlib/source')
-rw-r--r--stdlib/source/lux.lux730
-rw-r--r--stdlib/source/lux/cli.lux12
-rw-r--r--stdlib/source/lux/control/comonad.lux4
-rw-r--r--stdlib/source/lux/control/concatenative.lux26
-rw-r--r--stdlib/source/lux/control/concurrency/actor.lux26
-rw-r--r--stdlib/source/lux/control/concurrency/frp.lux12
-rw-r--r--stdlib/source/lux/control/concurrency/stm.lux2
-rw-r--r--stdlib/source/lux/control/exception.lux22
-rw-r--r--stdlib/source/lux/control/fold.lux6
-rw-r--r--stdlib/source/lux/control/interval.lux6
-rw-r--r--stdlib/source/lux/control/monad.lux42
-rw-r--r--stdlib/source/lux/control/monad/indexed.lux6
-rw-r--r--stdlib/source/lux/control/parser.lux6
-rw-r--r--stdlib/source/lux/control/pipe.lux6
-rw-r--r--stdlib/source/lux/control/region.lux4
-rw-r--r--stdlib/source/lux/control/remember.lux6
-rw-r--r--stdlib/source/lux/control/security/capability.lux4
-rw-r--r--stdlib/source/lux/data/collection/array.lux16
-rw-r--r--stdlib/source/lux/data/collection/bits.lux4
-rw-r--r--stdlib/source/lux/data/collection/dictionary.lux30
-rw-r--r--stdlib/source/lux/data/collection/dictionary/ordered.lux6
-rw-r--r--stdlib/source/lux/data/collection/dictionary/plist.lux14
-rw-r--r--stdlib/source/lux/data/collection/list.lux10
-rw-r--r--stdlib/source/lux/data/collection/queue.lux8
-rw-r--r--stdlib/source/lux/data/collection/queue/priority.lux6
-rw-r--r--stdlib/source/lux/data/collection/row.lux24
-rw-r--r--stdlib/source/lux/data/collection/sequence.lux4
-rw-r--r--stdlib/source/lux/data/collection/set.lux8
-rw-r--r--stdlib/source/lux/data/collection/set/multi.lux14
-rw-r--r--stdlib/source/lux/data/collection/set/ordered.lux6
-rw-r--r--stdlib/source/lux/data/collection/tree/finger.lux4
-rw-r--r--stdlib/source/lux/data/collection/tree/rose.lux10
-rw-r--r--stdlib/source/lux/data/collection/tree/rose/zipper.lux30
-rw-r--r--stdlib/source/lux/data/color.lux12
-rw-r--r--stdlib/source/lux/data/format/binary.lux18
-rw-r--r--stdlib/source/lux/data/format/css.lux8
-rw-r--r--stdlib/source/lux/data/format/css/value.lux22
-rw-r--r--stdlib/source/lux/data/format/html.lux18
-rw-r--r--stdlib/source/lux/data/format/json.lux86
-rw-r--r--stdlib/source/lux/data/format/markdown.lux8
-rw-r--r--stdlib/source/lux/data/format/xml.lux62
-rw-r--r--stdlib/source/lux/data/name.lux16
-rw-r--r--stdlib/source/lux/data/number/complex.lux58
-rw-r--r--stdlib/source/lux/data/number/int.lux8
-rw-r--r--stdlib/source/lux/data/number/ratio.lux14
-rw-r--r--stdlib/source/lux/data/text.lux4
-rw-r--r--stdlib/source/lux/data/text/buffer.lux6
-rw-r--r--stdlib/source/lux/data/text/format.lux4
-rw-r--r--stdlib/source/lux/data/text/lexer.lux40
-rw-r--r--stdlib/source/lux/data/text/regex.lux28
-rw-r--r--stdlib/source/lux/data/text/unicode.lux4
-rw-r--r--stdlib/source/lux/host.js.lux4
-rw-r--r--stdlib/source/lux/host.jvm.lux194
-rw-r--r--stdlib/source/lux/host/js.lux16
-rw-r--r--stdlib/source/lux/host/jvm/constant.lux8
-rw-r--r--stdlib/source/lux/host/jvm/constant/pool.lux12
-rw-r--r--stdlib/source/lux/host/jvm/descriptor.lux4
-rw-r--r--stdlib/source/lux/host/jvm/encoding.lux2
-rw-r--r--stdlib/source/lux/host/jvm/loader.jvm.lux4
-rw-r--r--stdlib/source/lux/host/jvm/modifier.lux10
-rw-r--r--stdlib/source/lux/host/scheme.lux12
-rw-r--r--stdlib/source/lux/macro.lux76
-rw-r--r--stdlib/source/lux/macro/code.lux20
-rw-r--r--stdlib/source/lux/macro/poly.lux34
-rw-r--r--stdlib/source/lux/macro/poly/equivalence.lux16
-rw-r--r--stdlib/source/lux/macro/poly/functor.lux14
-rw-r--r--stdlib/source/lux/macro/poly/json.lux26
-rw-r--r--stdlib/source/lux/macro/syntax.lux50
-rw-r--r--stdlib/source/lux/macro/syntax/common/reader.lux14
-rw-r--r--stdlib/source/lux/macro/syntax/common/writer.lux8
-rw-r--r--stdlib/source/lux/macro/template.lux6
-rw-r--r--stdlib/source/lux/math/infix.lux24
-rw-r--r--stdlib/source/lux/math/logic/continuous.lux6
-rw-r--r--stdlib/source/lux/math/modular.lux18
-rw-r--r--stdlib/source/lux/math/random.lux8
-rw-r--r--stdlib/source/lux/test.lux16
-rw-r--r--stdlib/source/lux/time/date.lux20
-rw-r--r--stdlib/source/lux/time/duration.lux26
-rw-r--r--stdlib/source/lux/time/instant.lux36
-rw-r--r--stdlib/source/lux/tool/compiler/analysis.lux16
-rw-r--r--stdlib/source/lux/tool/compiler/default/init.lux6
-rw-r--r--stdlib/source/lux/tool/compiler/meta/cache.lux16
-rw-r--r--stdlib/source/lux/tool/compiler/meta/cache/dependency.lux12
-rw-r--r--stdlib/source/lux/tool/compiler/meta/io/context.lux4
-rw-r--r--stdlib/source/lux/tool/compiler/name.lux1
-rw-r--r--stdlib/source/lux/tool/compiler/phase.lux4
-rw-r--r--stdlib/source/lux/tool/compiler/phase/analysis/case.lux10
-rw-r--r--stdlib/source/lux/tool/compiler/phase/analysis/case/coverage.lux32
-rw-r--r--stdlib/source/lux/tool/compiler/phase/analysis/function.lux4
-rw-r--r--stdlib/source/lux/tool/compiler/phase/analysis/inference.lux16
-rw-r--r--stdlib/source/lux/tool/compiler/phase/analysis/module.lux10
-rw-r--r--stdlib/source/lux/tool/compiler/phase/analysis/reference.lux4
-rw-r--r--stdlib/source/lux/tool/compiler/phase/analysis/scope.lux16
-rw-r--r--stdlib/source/lux/tool/compiler/phase/analysis/structure.lux12
-rw-r--r--stdlib/source/lux/tool/compiler/phase/extension.lux8
-rw-r--r--stdlib/source/lux/tool/compiler/phase/extension/analysis/common.lux2
-rw-r--r--stdlib/source/lux/tool/compiler/phase/extension/analysis/host.jvm.lux102
-rw-r--r--stdlib/source/lux/tool/compiler/phase/extension/bundle.lux4
-rw-r--r--stdlib/source/lux/tool/compiler/phase/extension/statement.lux2
-rw-r--r--stdlib/source/lux/tool/compiler/phase/generation.lux4
-rw-r--r--stdlib/source/lux/tool/compiler/phase/generation/js.lux4
-rw-r--r--stdlib/source/lux/tool/compiler/phase/generation/js/case.lux20
-rw-r--r--stdlib/source/lux/tool/compiler/phase/generation/js/extension/common.lux4
-rw-r--r--stdlib/source/lux/tool/compiler/phase/generation/js/function.lux10
-rw-r--r--stdlib/source/lux/tool/compiler/phase/generation/js/loop.lux4
-rw-r--r--stdlib/source/lux/tool/compiler/phase/generation/js/runtime.lux8
-rw-r--r--stdlib/source/lux/tool/compiler/phase/generation/reference.lux6
-rw-r--r--stdlib/source/lux/tool/compiler/phase/generation/scheme.lux4
-rw-r--r--stdlib/source/lux/tool/compiler/phase/generation/scheme/case.jvm.lux16
-rw-r--r--stdlib/source/lux/tool/compiler/phase/generation/scheme/extension/common.jvm.lux4
-rw-r--r--stdlib/source/lux/tool/compiler/phase/generation/scheme/function.jvm.lux10
-rw-r--r--stdlib/source/lux/tool/compiler/phase/generation/scheme/loop.jvm.lux4
-rw-r--r--stdlib/source/lux/tool/compiler/phase/generation/scheme/runtime.jvm.lux18
-rw-r--r--stdlib/source/lux/tool/compiler/phase/macro.lux6
-rw-r--r--stdlib/source/lux/tool/compiler/phase/synthesis.lux12
-rw-r--r--stdlib/source/lux/tool/compiler/phase/synthesis/case.lux32
-rw-r--r--stdlib/source/lux/tool/compiler/phase/synthesis/function.lux42
-rw-r--r--stdlib/source/lux/tool/compiler/phase/synthesis/loop.lux24
-rw-r--r--stdlib/source/lux/tool/compiler/synthesis.lux18
-rw-r--r--stdlib/source/lux/tool/interpreter.lux4
-rw-r--r--stdlib/source/lux/tool/mediator/parallelism.lux18
-rw-r--r--stdlib/source/lux/type.lux66
-rw-r--r--stdlib/source/lux/type/abstract.lux32
-rw-r--r--stdlib/source/lux/type/check.lux46
-rw-r--r--stdlib/source/lux/type/implicit.lux40
-rw-r--r--stdlib/source/lux/type/refinement.lux2
-rw-r--r--stdlib/source/lux/type/resource.lux8
-rw-r--r--stdlib/source/lux/world/db/jdbc.jvm.lux6
-rw-r--r--stdlib/source/lux/world/db/jdbc/input.jvm.lux2
-rw-r--r--stdlib/source/lux/world/db/sql.lux16
-rw-r--r--stdlib/source/lux/world/file.lux14
-rw-r--r--stdlib/source/lux/world/net/http/cookie.lux4
-rw-r--r--stdlib/source/lux/world/net/http/request.lux6
-rw-r--r--stdlib/source/lux/world/net/http/response.lux8
-rw-r--r--stdlib/source/lux/world/net/http/route.lux2
-rw-r--r--stdlib/source/lux/world/service/journal.lux16
-rw-r--r--stdlib/source/lux/world/shell.lux10
-rw-r--r--stdlib/source/program/licentia.lux4
-rw-r--r--stdlib/source/program/licentia/document.lux4
-rw-r--r--stdlib/source/program/licentia/license/black-list.lux8
-rw-r--r--stdlib/source/program/licentia/license/commercial.lux2
-rw-r--r--stdlib/source/program/licentia/license/distribution.lux4
-rw-r--r--stdlib/source/program/licentia/license/extension.lux2
-rw-r--r--stdlib/source/program/licentia/license/notice.lux4
-rw-r--r--stdlib/source/program/licentia/output.lux14
-rw-r--r--stdlib/source/program/scriptum.lux66
-rw-r--r--stdlib/source/test/licentia.lux34
-rw-r--r--stdlib/source/test/lux.lux14
-rw-r--r--stdlib/source/test/lux/cli.lux14
-rw-r--r--stdlib/source/test/lux/compiler/default/phase/analysis/case.lux48
-rw-r--r--stdlib/source/test/lux/compiler/default/phase/analysis/function.lux10
-rw-r--r--stdlib/source/test/lux/compiler/default/phase/analysis/primitive.lux8
-rw-r--r--stdlib/source/test/lux/compiler/default/phase/analysis/procedure/common.lux4
-rw-r--r--stdlib/source/test/lux/compiler/default/phase/analysis/reference.lux14
-rw-r--r--stdlib/source/test/lux/compiler/default/phase/analysis/structure.lux40
-rw-r--r--stdlib/source/test/lux/compiler/default/phase/synthesis/case.lux4
-rw-r--r--stdlib/source/test/lux/compiler/default/phase/synthesis/function.lux14
-rw-r--r--stdlib/source/test/lux/compiler/default/phase/synthesis/structure.lux4
-rw-r--r--stdlib/source/test/lux/compiler/default/syntax.lux32
-rw-r--r--stdlib/source/test/lux/control/apply.lux24
-rw-r--r--stdlib/source/test/lux/control/concurrency/actor.lux6
-rw-r--r--stdlib/source/test/lux/control/concurrency/frp.lux18
-rw-r--r--stdlib/source/test/lux/control/concurrency/promise.lux4
-rw-r--r--stdlib/source/test/lux/control/concurrency/semaphore.lux12
-rw-r--r--stdlib/source/test/lux/control/concurrency/stm.lux4
-rw-r--r--stdlib/source/test/lux/control/continuation.lux14
-rw-r--r--stdlib/source/test/lux/control/equivalence.lux14
-rw-r--r--stdlib/source/test/lux/control/functor.lux18
-rw-r--r--stdlib/source/test/lux/control/interval.lux8
-rw-r--r--stdlib/source/test/lux/control/monad.lux24
-rw-r--r--stdlib/source/test/lux/control/parser.lux36
-rw-r--r--stdlib/source/test/lux/control/pipe.lux10
-rw-r--r--stdlib/source/test/lux/control/reader.lux4
-rw-r--r--stdlib/source/test/lux/control/security/integrity.lux6
-rw-r--r--stdlib/source/test/lux/control/security/privacy.lux4
-rw-r--r--stdlib/source/test/lux/control/state.lux9
-rw-r--r--stdlib/source/test/lux/control/writer.lux8
-rw-r--r--stdlib/source/test/lux/data/collection/dictionary.lux4
-rw-r--r--stdlib/source/test/lux/data/collection/dictionary/ordered.lux12
-rw-r--r--stdlib/source/test/lux/data/collection/list.lux22
-rw-r--r--stdlib/source/test/lux/data/collection/queue.lux4
-rw-r--r--stdlib/source/test/lux/data/collection/row.lux38
-rw-r--r--stdlib/source/test/lux/data/collection/sequence.lux48
-rw-r--r--stdlib/source/test/lux/data/collection/set.lux8
-rw-r--r--stdlib/source/test/lux/data/collection/set/ordered.lux8
-rw-r--r--stdlib/source/test/lux/data/collection/tree/rose.lux18
-rw-r--r--stdlib/source/test/lux/data/collection/tree/rose/zipper.lux6
-rw-r--r--stdlib/source/test/lux/data/color.lux4
-rw-r--r--stdlib/source/test/lux/data/error.lux18
-rw-r--r--stdlib/source/test/lux/data/format/xml.lux24
-rw-r--r--stdlib/source/test/lux/data/identity.lux24
-rw-r--r--stdlib/source/test/lux/data/lazy.lux6
-rw-r--r--stdlib/source/test/lux/data/maybe.lux46
-rw-r--r--stdlib/source/test/lux/data/name.lux42
-rw-r--r--stdlib/source/test/lux/data/number.lux6
-rw-r--r--stdlib/source/test/lux/data/number/complex.lux16
-rw-r--r--stdlib/source/test/lux/data/number/ratio.lux14
-rw-r--r--stdlib/source/test/lux/data/text.lux30
-rw-r--r--stdlib/source/test/lux/data/text/format.lux16
-rw-r--r--stdlib/source/test/lux/data/text/lexer.lux14
-rw-r--r--stdlib/source/test/lux/data/text/regex.lux12
-rw-r--r--stdlib/source/test/lux/host.jvm.lux4
-rw-r--r--stdlib/source/test/lux/macro/code.lux4
-rw-r--r--stdlib/source/test/lux/macro/poly/equivalence.lux8
-rw-r--r--stdlib/source/test/lux/math.lux14
-rw-r--r--stdlib/source/test/lux/math/logic/fuzzy.lux22
-rw-r--r--stdlib/source/test/lux/math/modular.lux20
-rw-r--r--stdlib/source/test/lux/time/date.lux40
-rw-r--r--stdlib/source/test/lux/type.lux30
-rw-r--r--stdlib/source/test/lux/type/check.lux16
-rw-r--r--stdlib/source/test/lux/type/implicit.lux8
-rw-r--r--stdlib/source/test/lux/world/file.lux6
-rw-r--r--stdlib/source/test/lux/world/net/tcp.lux4
213 files changed, 2119 insertions, 2113 deletions
diff --git a/stdlib/source/lux.lux b/stdlib/source/lux.lux
index 83c5fadfb..c6e14e66b 100644
--- a/stdlib/source/lux.lux
+++ b/stdlib/source/lux.lux
@@ -1057,7 +1057,7 @@
(fail "Wrong syntax for $'")}
tokens))
-(def:'' (list/map f xs)
+(def:'' (list;map f xs)
#Nil
(#UnivQ #Nil
(#UnivQ #Nil
@@ -1068,7 +1068,7 @@
#Nil
(#Cons x xs')
- (#Cons (f x) (list/map f xs'))}
+ (#Cons (f x) (list;map f xs'))}
xs))
(def:'' RepEnv
@@ -1086,7 +1086,7 @@
#Nil}
[xs ys]))
-(def:'' (text/= x y)
+(def:'' (text;= x y)
#Nil
(#Function Text (#Function Text Bit))
("lux text =" x y))
@@ -1103,7 +1103,7 @@
#0
(get-rep key env')}
- (text/= k key))}
+ (text;= k key))}
env))
(def:'' (replace-syntax reps syntax)
@@ -1118,13 +1118,13 @@
(get-rep name reps))
[meta (#Form parts)]
- [meta (#Form (list/map (replace-syntax reps) parts))]
+ [meta (#Form (list;map (replace-syntax reps) parts))]
[meta (#Tuple members)]
- [meta (#Tuple (list/map (replace-syntax reps) members))]
+ [meta (#Tuple (list;map (replace-syntax reps) members))]
[meta (#Record slots)]
- [meta (#Record (list/map ("lux check" (#Function (#Product Code Code) (#Product Code Code))
+ [meta (#Record (list;map ("lux check" (#Function (#Product Code Code) (#Product Code Code))
(function'' [slot]
({[k v]
[(replace-syntax reps k) (replace-syntax reps v)]}
@@ -1163,10 +1163,10 @@
#Nil
(#Function Code Code)
({[_ (#Tuple members)]
- (tuple$ (list/map update-parameters members))
+ (tuple$ (list;map update-parameters members))
[_ (#Record pairs)]
- (record$ (list/map ("lux check" (#Function (#Product Code Code) (#Product Code Code))
+ (record$ (list;map ("lux check" (#Function (#Product Code Code) (#Product Code Code))
(function'' [pair]
(let'' [name val] pair
[name (update-parameters val)])))
@@ -1176,7 +1176,7 @@
(form$ (#Cons (tag$ ["lux" "Parameter"]) (#Cons (nat$ (n/+ 2 idx)) #Nil)))
[_ (#Form members)]
- (form$ (list/map update-parameters members))
+ (form$ (list;map update-parameters members))
_
code}
@@ -1204,7 +1204,7 @@
(#Function Nat Code)
(form$ (#Cons (tag$ ["lux" "Parameter"]) (#Cons (nat$ idx) #Nil))))
-(def:'' (list/fold f init xs)
+(def:'' (list;fold f init xs)
#Nil
## (All [a b] (-> (-> b a a) a (List b) a))
(#UnivQ #Nil (#UnivQ #Nil (#Function (#Function (#Parameter 1)
@@ -1217,14 +1217,14 @@
init
(#Cons x xs')
- (list/fold f (f x init) xs')}
+ (list;fold f (f x init) xs')}
xs))
-(def:'' (list/size list)
+(def:'' (list;size list)
#Nil
(#UnivQ #Nil
(#Function ($' List (#Parameter 1)) Nat))
- (list/fold (function'' [_ acc] (n/+ 1 acc)) 0 list))
+ (list;fold (function'' [_ acc] (n/+ 1 acc)) 0 list))
(macro:' #export (All tokens)
(#Cons [(tag$ ["lux" "doc"])
@@ -1245,7 +1245,7 @@
({(#Cons [_ (#Tuple args)] (#Cons body #Nil))
(parse-quantified-args args
(function'' [names]
- (let'' body' (list/fold ("lux check" (#Function Text (#Function Code Code))
+ (let'' body' (list;fold ("lux check" (#Function Text (#Function Code Code))
(function'' [name' body']
(form$ (#Cons (tag$ ["lux" "UnivQ"])
(#Cons (tag$ ["lux" "Nil"])
@@ -1260,10 +1260,10 @@
body'
[#0 _]
- (replace-syntax (#Cons [self-name (make-parameter (n/* 2 (n/- 1 (list/size names))))]
+ (replace-syntax (#Cons [self-name (make-parameter (n/* 2 (n/- 1 (list;size names))))]
#Nil)
body')}
- [(text/= "" self-name) names])
+ [(text;= "" self-name) names])
#Nil)))))
_
@@ -1289,7 +1289,7 @@
({(#Cons [_ (#Tuple args)] (#Cons body #Nil))
(parse-quantified-args args
(function'' [names]
- (let'' body' (list/fold ("lux check" (#Function Text (#Function Code Code))
+ (let'' body' (list;fold ("lux check" (#Function Text (#Function Code Code))
(function'' [name' body']
(form$ (#Cons (tag$ ["lux" "ExQ"])
(#Cons (tag$ ["lux" "Nil"])
@@ -1304,20 +1304,20 @@
body'
[#0 _]
- (replace-syntax (#Cons [self-name (make-parameter (n/* 2 (n/- 1 (list/size names))))]
+ (replace-syntax (#Cons [self-name (make-parameter (n/* 2 (n/- 1 (list;size names))))]
#Nil)
body')}
- [(text/= "" self-name) names])
+ [(text;= "" self-name) names])
#Nil)))))
_
(fail "Wrong syntax for Ex")}
tokens)))
-(def:'' (list/reverse list)
+(def:'' (list;reverse list)
#Nil
(All [a] (#Function ($' List a) ($' List a)))
- (list/fold ("lux check" (All [a] (#Function a (#Function ($' List a) ($' List a))))
+ (list;fold ("lux check" (All [a] (#Function a (#Function ($' List a) ($' List a))))
(function'' [head tail] (#Cons head tail)))
#Nil
list))
@@ -1331,7 +1331,7 @@
"## This is the type of a function that takes 2 Ints and returns an Int.")))]
#Nil)
({(#Cons output inputs)
- (return (#Cons (list/fold ("lux check" (#Function Code (#Function Code Code))
+ (return (#Cons (list;fold ("lux check" (#Function Code (#Function Code Code))
(function'' [i o] (form$ (#Cons (tag$ ["lux" "Function"]) (#Cons i (#Cons o #Nil))))))
output
inputs)
@@ -1339,7 +1339,7 @@
_
(fail "Wrong syntax for ->")}
- (list/reverse tokens)))
+ (list;reverse tokens)))
(macro:' #export (list xs)
(#Cons [(tag$ ["lux" "doc"])
@@ -1347,12 +1347,12 @@
("lux text concat" "## List-construction macro." __paragraph)
"(list +1 +2 +3)"))]
#Nil)
- (return (#Cons (list/fold (function'' [head tail]
+ (return (#Cons (list;fold (function'' [head tail]
(form$ (#Cons (tag$ ["lux" "Cons"])
(#Cons (tuple$ (#Cons [head (#Cons [tail #Nil])]))
#Nil))))
(tag$ ["lux" "Nil"])
- (list/reverse xs))
+ (list;reverse xs))
#Nil)))
(macro:' #export (list& xs)
@@ -1364,7 +1364,7 @@
"(list& +1 +2 +3 (list +4 +5 +6))")))]
#Nil)
({(#Cons last init)
- (return (list (list/fold (function'' [head tail]
+ (return (list (list;fold (function'' [head tail]
(form$ (list (tag$ ["lux" "Cons"])
(tuple$ (list head tail)))))
last
@@ -1372,7 +1372,7 @@
_
(fail "Wrong syntax for list&")}
- (list/reverse xs)))
+ (list;reverse xs)))
(macro:' #export (& tokens)
(#Cons [(tag$ ["lux" "doc"])
@@ -1388,10 +1388,10 @@
(return (list (identifier$ ["lux" "Any"])))
(#Cons last prevs)
- (return (list (list/fold (function'' [left right] (form$ (list (tag$ ["lux" "Product"]) left right)))
+ (return (list (list;fold (function'' [left right] (form$ (list (tag$ ["lux" "Product"]) left right)))
last
prevs)))}
- (list/reverse tokens)))
+ (list;reverse tokens)))
(macro:' #export (| tokens)
(#Cons [(tag$ ["lux" "doc"])
@@ -1407,10 +1407,10 @@
(return (list (identifier$ ["lux" "Nothing"])))
(#Cons last prevs)
- (return (list (list/fold (function'' [left right] (form$ (list (tag$ ["lux" "Sum"]) left right)))
+ (return (list (list;fold (function'' [left right] (form$ (list (tag$ ["lux" "Sum"]) left right)))
last
prevs)))}
- (list/reverse tokens)))
+ (list;reverse tokens)))
(macro:' (function' tokens)
(let'' [name tokens'] ({(#Cons [[_ (#Identifier ["" name])] tokens'])
@@ -1426,12 +1426,12 @@
(#Cons [harg targs])
(return (list (form$ (list (tuple$ (list (identifier$ ["" name])
harg))
- (list/fold (function'' [arg body']
+ (list;fold (function'' [arg body']
(form$ (list (tuple$ (list (identifier$ ["" ""])
arg))
body')))
body
- (list/reverse targs))))))}
+ (list;reverse targs))))))}
args)
_
@@ -1502,14 +1502,14 @@
(macro:' (let' tokens)
({(#Cons [[_ (#Tuple bindings)] (#Cons [body #Nil])])
- (return (list (list/fold ("lux check" (-> (& Code Code) Code
+ (return (list (list;fold ("lux check" (-> (& Code Code) Code
Code)
(function' [binding body]
({[label value]
(form$ (list (record$ (list [label body])) value))}
binding)))
body
- (list/reverse (as-pairs bindings)))))
+ (list;reverse (as-pairs bindings)))))
_
(fail "Wrong syntax for let'")}
@@ -1544,11 +1544,11 @@
(_ann (#Form (list (_ann (#Tag ["lux" "Cons"])) token (untemplate-list tokens'))))}
tokens))
-(def:''' (list/compose xs ys)
+(def:''' (list;compose xs ys)
#Nil
(All [a] (-> ($' List a) ($' List a) ($' List a)))
({(#Cons x xs')
- (#Cons x (list/compose xs' ys))
+ (#Cons x (list;compose xs' ys))
#Nil
ys}
@@ -1568,7 +1568,7 @@
#Nil
(-> Code Code Code Code)
({[_ (#Form parts)]
- (form$ (list/compose parts (list a1 a2)))
+ (form$ (list;compose parts (list a1 a2)))
_
(form$ (list op a1 a2))}
@@ -1586,14 +1586,14 @@
(text$ ("lux text concat"
("lux text concat" "## Left-association for the application of binary functions over variadic arguments." ..new-line)
("lux text concat"
- ("lux text concat" "(_$ text/compose ''Hello, '' name ''. How are you?'')" ..new-line)
+ ("lux text concat" "(_$ text;compose ''Hello, '' name ''. How are you?'')" ..new-line)
("lux text concat"
("lux text concat" "## =>" ..new-line)
- "(text/compose (text/compose ''Hello, '' name) ''. How are you?'')"))))]
+ "(text;compose (text;compose ''Hello, '' name) ''. How are you?'')"))))]
#Nil)
({(#Cons op tokens')
({(#Cons first nexts)
- (return (list (list/fold (function/flip (_$_joiner op)) first nexts)))
+ (return (list (list;fold (function/flip (_$_joiner op)) first nexts)))
_
(fail "Wrong syntax for _$")}
@@ -1608,18 +1608,18 @@
(text$ ("lux text concat"
("lux text concat" "## Right-association for the application of binary functions over variadic arguments." ..new-line)
("lux text concat"
- ("lux text concat" "($_ text/compose ''Hello, '' name ''. How are you?'')" ..new-line)
+ ("lux text concat" "($_ text;compose ''Hello, '' name ''. How are you?'')" ..new-line)
("lux text concat"
("lux text concat" "## =>" ..new-line)
- "(text/compose ''Hello, '' (text/compose name ''. How are you?''))"))))]
+ "(text;compose ''Hello, '' (text;compose name ''. How are you?''))"))))]
#Nil)
({(#Cons op tokens')
({(#Cons last prevs)
- (return (list (list/fold (_$_joiner op) last prevs)))
+ (return (list (list;fold (_$_joiner op) last prevs)))
_
(fail "Wrong syntax for $_")}
- (list/reverse tokens'))
+ (list;reverse tokens'))
_
(fail "Wrong syntax for $_")}
@@ -1676,7 +1676,7 @@
({(#Cons monad (#Cons [_ (#Tuple bindings)] (#Cons body #Nil)))
(let' [g!wrap (identifier$ ["" "wrap"])
g!bind (identifier$ ["" " bind "])
- body' (list/fold ("lux check" (-> (& Code Code) Code Code)
+ body' (list;fold ("lux check" (-> (& Code Code) Code Code)
(function' [binding body']
(let' [[var value] binding]
({[_ (#Tag "" "let")]
@@ -1688,7 +1688,7 @@
value))}
var))))
body
- (list/reverse (as-pairs bindings)))]
+ (list;reverse (as-pairs bindings)))]
(return (list (form$ (list (record$ (list [(record$ (list [(tag$ ["lux" "wrap"]) g!wrap] [(tag$ ["lux" "bind"]) g!bind]))
body']))
monad)))))
@@ -1697,7 +1697,7 @@
(fail "Wrong syntax for do")}
tokens))
-(def:''' (monad/map m f xs)
+(def:''' (monad;map m f xs)
#Nil
## (All [m a b]
## (-> (Monad m) (-> a (m b)) (List a) (m (List b))))
@@ -1713,7 +1713,7 @@
(#Cons x xs')
(do m
[y (f x)
- ys (monad/map m f xs')]
+ ys (monad;map m f xs')]
(wrap (#Cons y ys)))}
xs)))
@@ -1757,7 +1757,7 @@
(All [a]
(-> Text ($' List (& Text a)) ($' Maybe a)))
({(#Cons [[k' v] plist'])
- (if (text/= k k')
+ (if (text;= k k')
(#Some v)
(get k plist'))
@@ -1773,7 +1773,7 @@
(list [k v])
(#Cons [[k' v'] dict'])
- (if (text/= k k')
+ (if (text;= k k')
(#Cons [[k' v] dict'])
(#Cons [[k' v'] (put k v dict')]))}
dict))
@@ -1786,17 +1786,17 @@
(-> Text Any)
("lux io log" message))
-(def:''' (text/compose x y)
+(def:''' (text;compose x y)
#Nil
(-> Text Text Text)
("lux text concat" x y))
-(def:''' (name/encode full-name)
+(def:''' (name;encode full-name)
#Nil
(-> Name Text)
(let' [[module name] full-name]
({"" name
- _ ($_ text/compose module "." name)}
+ _ ($_ text;compose module "." name)}
module)))
(def:''' (get-meta tag def-meta)
@@ -1811,8 +1811,8 @@
_
(get-meta tag (record$ def-meta'))}
- [(text/= prefix prefix')
- (text/= name name')])
+ [(text;= prefix prefix')
+ (text;= name name')])
_
(get-meta tag (record$ def-meta'))}
@@ -1844,11 +1844,11 @@
(get-meta ["lux" "alias"] def-meta))
#None
- (#Left ($_ text/compose "Unknown definition: " (name/encode full-name)))}
+ (#Left ($_ text;compose "Unknown definition: " (name;encode full-name)))}
(get name definitions))
#None
- (#Left ($_ text/compose "Unknown module: " module " @ " (name/encode full-name)))}
+ (#Left ($_ text;compose "Unknown module: " module " @ " (name;encode full-name)))}
(get module modules))))
(def:''' (splice replace? untemplate elems)
@@ -1884,10 +1884,10 @@
leftI))
lastO
inits))}
- (list/reverse elems))
+ (list;reverse elems))
#0
(do meta-monad
- [=elems (monad/map meta-monad untemplate elems)]
+ [=elems (monad;map meta-monad untemplate elems)]
(wrap (untemplate-list =elems)))}
replace?))
@@ -1932,7 +1932,7 @@
[#1 [_ (#Identifier [module name])]]
(do meta-monad
[real-name ({""
- (if (text/= "" subst)
+ (if (text;= "" subst)
(wrap [module name])
(resolve-global-identifier [subst name]))
@@ -1973,7 +1973,7 @@
[_ [_ (#Record fields)]]
(do meta-monad
- [=fields (monad/map meta-monad
+ [=fields (monad;map meta-monad
("lux check" (-> (& Code Code) ($' Meta Code))
(function' [kv]
(let' [[k v] kv]
@@ -2066,17 +2066,17 @@
(list [(tag$ ["lux" "doc"])
(text$ ($_ "lux text concat"
"## Piping macro." __paragraph
- "(|> elems (list/map int/encode) (interpose '' '') (fold text/compose ''''))" __paragraph
+ "(|> elems (list;map int;encode) (interpose '' '') (fold text;compose ''''))" __paragraph
"## =>" __paragraph
- "(fold text/compose '''' (interpose '' '' (list/map int/encode elems)))"))])
+ "(fold text;compose '''' (interpose '' '' (list;map int;encode elems)))"))])
({(#Cons [init apps])
- (return (list (list/fold ("lux check" (-> Code Code Code)
+ (return (list (list;fold ("lux check" (-> Code Code Code)
(function' [app acc]
({[_ (#Tuple parts)]
- (tuple$ (list/compose parts (list acc)))
+ (tuple$ (list;compose parts (list acc)))
[_ (#Form parts)]
- (form$ (list/compose parts (list acc)))
+ (form$ (list;compose parts (list acc)))
_
(` ((~ app) (~ acc)))}
@@ -2092,17 +2092,17 @@
(list [(tag$ ["lux" "doc"])
(text$ ($_ "lux text concat"
"## Reverse piping macro." __paragraph
- "(<| (fold text/compose '''') (interpose '' '') (list/map int/encode) elems)" __paragraph
+ "(<| (fold text;compose '''') (interpose '' '') (list;map int;encode) elems)" __paragraph
"## =>" __paragraph
- "(fold text/compose '''' (interpose '' '' (list/map int/encode elems)))"))])
+ "(fold text;compose '''' (interpose '' '' (list;map int;encode elems)))"))])
({(#Cons [init apps])
- (return (list (list/fold ("lux check" (-> Code Code Code)
+ (return (list (list;fold ("lux check" (-> Code Code Code)
(function' [app acc]
({[_ (#Tuple parts)]
- (tuple$ (list/compose parts (list acc)))
+ (tuple$ (list;compose parts (list acc)))
[_ (#Form parts)]
- (form$ (list/compose parts (list acc)))
+ (form$ (list;compose parts (list acc)))
_
(` ((~ app) (~ acc)))}
@@ -2112,7 +2112,7 @@
_
(fail "Wrong syntax for <|")}
- (list/reverse tokens)))
+ (list;reverse tokens)))
(def:''' (compose f g)
(list [(tag$ ["lux" "doc"])
@@ -2173,13 +2173,13 @@
(get-rep sname env))
[meta (#Tuple elems)]
- [meta (#Tuple (list/map (apply-template env) elems))]
+ [meta (#Tuple (list;map (apply-template env) elems))]
[meta (#Form elems)]
- [meta (#Form (list/map (apply-template env) elems))]
+ [meta (#Form (list;map (apply-template env) elems))]
[meta (#Record members)]
- [meta (#Record (list/map ("lux check" (-> (& Code Code) (& Code Code))
+ [meta (#Record (list;map ("lux check" (-> (& Code Code) (& Code Code))
(function' [kv]
(let' [[slot value] kv]
[(apply-template env slot) (apply-template env value)])))
@@ -2197,14 +2197,14 @@
#Nil
(#Cons [x xs'])
- (list/compose (f x) (join-map f xs'))}
+ (list;compose (f x) (join-map f xs'))}
xs))
(def:''' (every? p xs)
#Nil
(All [a]
(-> (-> a Bit) ($' List a) Bit))
- (list/fold (function' [_2 _1] (if _1 (p _2) #0)) #1 xs))
+ (list;fold (function' [_2 _1] (if _1 (p _2) #0)) #1 xs))
(def:''' #export (n/= test subject)
(list [(tag$ ["lux" "doc"])
@@ -2274,10 +2274,10 @@
({(#Cons [[_ (#Tuple bindings)] (#Cons [[_ (#Tuple templates)] data])])
({[(#Some bindings') (#Some data')]
(let' [apply ("lux check" (-> RepEnv ($' List Code))
- (function' [env] (list/map (apply-template env) templates)))
- num-bindings (list/size bindings')]
+ (function' [env] (list;map (apply-template env) templates)))
+ num-bindings (list;size bindings')]
(if (every? (n/= num-bindings)
- (list/map list/size data'))
+ (list;map list;size data'))
(|> data'
(join-map (compose apply (make-env bindings')))
return)
@@ -2285,8 +2285,8 @@
_
(fail "Wrong syntax for do-template")}
- [(monad/map maybe-monad get-short bindings)
- (monad/map maybe-monad tuple->list data)])
+ [(monad;map maybe-monad get-short bindings)
+ (monad;map maybe-monad tuple->list data)])
_
(fail "Wrong syntax for do-template")}
@@ -2547,7 +2547,7 @@
[f/max Frac f/> "Frac(tion) minimum."]
)
-(def:''' (bit/encode x)
+(def:''' (bit;encode x)
#Nil
(-> Bit Text)
(if x "#1" "#0"))
@@ -2562,7 +2562,7 @@
_ ("lux io error" "undefined")}
digit))
-(def:''' (nat/encode value)
+(def:''' (nat;encode value)
#Nil
(-> Nat Text)
({0
@@ -2574,19 +2574,19 @@
(if (n/= 0 input)
output
(recur (n// 10 input)
- (text/compose (|> input (n/% 10) digit-to-text)
+ (text;compose (|> input (n/% 10) digit-to-text)
output)))))]
(loop value ""))}
value))
-(def:''' (int/abs value)
+(def:''' (int;abs value)
#Nil
(-> Int Int)
(if (i/< +0 value)
(i/* -1 value)
value))
-(def:''' (int/encode value)
+(def:''' (int;encode value)
#Nil
(-> Int Text)
(if (i/= +0 value)
@@ -2597,14 +2597,14 @@
(("lux check" (-> Int Text Text)
(function' recur [input output]
(if (i/= +0 input)
- (text/compose sign output)
+ (text;compose sign output)
(recur (i// +10 input)
- (text/compose (|> input (i/% +10) ("lux coerce" Nat) digit-to-text)
+ (text;compose (|> input (i/% +10) ("lux coerce" Nat) digit-to-text)
output)))))
- (|> value (i// +10) int/abs)
- (|> value (i/% +10) int/abs ("lux coerce" Nat) digit-to-text)))))
+ (|> value (i// +10) int;abs)
+ (|> value (i/% +10) int;abs ("lux coerce" Nat) digit-to-text)))))
-(def:''' (frac/encode x)
+(def:''' (frac;encode x)
#Nil
(-> Frac Text)
("lux frac encode" x))
@@ -2638,7 +2638,7 @@
(#Some ("lux coerce" Macro def-value))
_
- (if (text/= module current-module)
+ (if (text;= module current-module)
(#Some ("lux coerce" Macro def-value))
#None)}
(get-meta ["lux" "export?"] def-meta))
@@ -2690,11 +2690,11 @@
#None #0}
output))))
-(def:''' (list/join xs)
+(def:''' (list;join xs)
#Nil
(All [a]
(-> ($' List ($' List a)) ($' List a)))
- (list/fold list/compose #Nil (list/reverse xs)))
+ (list;fold list;compose #Nil (list;reverse xs)))
(def:''' (interpose sep xs)
#Nil
@@ -2738,8 +2738,8 @@
({(#Some macro)
(do meta-monad
[expansion (macro args)
- expansion' (monad/map meta-monad macro-expand expansion)]
- (wrap (list/join expansion')))
+ expansion' (monad;map meta-monad macro-expand expansion)]
+ (wrap (list;join expansion')))
#None
(return (list token))}
@@ -2759,28 +2759,28 @@
({(#Some macro)
(do meta-monad
[expansion (macro args)
- expansion' (monad/map meta-monad macro-expand-all expansion)]
- (wrap (list/join expansion')))
+ expansion' (monad;map meta-monad macro-expand-all expansion)]
+ (wrap (list;join expansion')))
#None
(do meta-monad
- [args' (monad/map meta-monad macro-expand-all args)]
- (wrap (list (form$ (#Cons (identifier$ macro-name) (list/join args'))))))}
+ [args' (monad;map meta-monad macro-expand-all args)]
+ (wrap (list (form$ (#Cons (identifier$ macro-name) (list;join args'))))))}
?macro))
[_ (#Form members)]
(do meta-monad
- [members' (monad/map meta-monad macro-expand-all members)]
- (wrap (list (form$ (list/join members')))))
+ [members' (monad;map meta-monad macro-expand-all members)]
+ (wrap (list (form$ (list;join members')))))
[_ (#Tuple members)]
(do meta-monad
- [members' (monad/map meta-monad macro-expand-all members)]
- (wrap (list (tuple$ (list/join members')))))
+ [members' (monad;map meta-monad macro-expand-all members)]
+ (wrap (list (tuple$ (list;join members')))))
[_ (#Record pairs)]
(do meta-monad
- [pairs' (monad/map meta-monad
+ [pairs' (monad;map meta-monad
(function' [kv]
(let' [[key val] kv]
(do meta-monad
@@ -2802,10 +2802,10 @@
#Nil
(-> Code Code)
({[_ (#Form (#Cons [_ (#Tag tag)] parts))]
- (form$ (#Cons [(tag$ tag) (list/map walk-type parts)]))
+ (form$ (#Cons [(tag$ tag) (list;map walk-type parts)]))
[_ (#Tuple members)]
- (` (& (~+ (list/map walk-type members))))
+ (` (& (~+ (list;map walk-type members))))
[_ (#Form (#Cons [_ (#Text "lux in-module")]
(#Cons [_ (#Text module)]
@@ -2817,10 +2817,10 @@
expression
[_ (#Form (#Cons type-fn args))]
- (list/fold ("lux check" (-> Code Code Code)
+ (list;fold ("lux check" (-> Code Code Code)
(function' [arg type-fn] (` (#.Apply (~ arg) (~ type-fn)))))
(walk-type type-fn)
- (list/map walk-type args))
+ (list;map walk-type args))
_
type}
@@ -2890,7 +2890,7 @@
(-> ($' List Code) ($' Meta (& Code ($' Maybe ($' List Text)))))
({(#Cons [_ (#Record pairs)] #Nil)
(do meta-monad
- [members (monad/map meta-monad
+ [members (monad;map meta-monad
(: (-> [Code Code] (Meta [Text Code]))
(function' [pair]
({[[_ (#Tag "" member-name)] member-type]
@@ -2900,8 +2900,8 @@
(fail "Wrong syntax for variant case.")}
pair)))
pairs)]
- (return [(` (& (~+ (list/map second members))))
- (#Some (list/map first members))]))
+ (return [(` (& (~+ (list;map second members))))
+ (#Some (list;map first members))]))
(#Cons type #Nil)
({[_ (#Tag "" member-name)]
@@ -2916,7 +2916,7 @@
(#Cons case cases)
(do meta-monad
- [members (monad/map meta-monad
+ [members (monad;map meta-monad
(: (-> Code (Meta [Text Code]))
(function' [case]
({[_ (#Tag "" member-name)]
@@ -2932,8 +2932,8 @@
(fail "Wrong syntax for variant case.")}
case)))
(list& case cases))]
- (return [(` (| (~+ (list/map second members))))
- (#Some (list/map first members))]))
+ (return [(` (| (~+ (list;map second members))))
+ (#Some (list;map first members))]))
_
(fail "Improper type-definition syntax")}
@@ -2952,7 +2952,7 @@
#seed (n/+ 1 seed) #expected expected
#cursor cursor #extensions extensions
#scope-type-vars scope-type-vars}
- (identifier$ ["" ($_ text/compose "__gensym__" prefix (nat/encode seed))]))}
+ (identifier$ ["" ($_ text;compose "__gensym__" prefix (nat;encode seed))]))}
state))
(macro:' #export (Rec tokens)
@@ -2981,7 +2981,7 @@
"''YOLO'')"))])
({(#Cons value actions)
(let' [dummy (identifier$ ["" ""])]
- (return (list (list/fold ("lux check" (-> Code Code Code)
+ (return (list (list;fold ("lux check" (-> Code Code Code)
(function' [pre post] (` ({(~ dummy) (~ post)}
(~ pre)))))
value
@@ -2989,7 +2989,7 @@
_
(fail "Wrong syntax for exec")}
- (list/reverse tokens)))
+ (list;reverse tokens)))
(macro:' (def:' tokens)
(let' [[export? tokens'] ({(#Cons [_ (#Tag ["" "export"])] tokens')
@@ -3045,54 +3045,54 @@
(def:' (code-to-text code)
(-> Code Text)
({[_ (#Bit value)]
- (bit/encode value)
+ (bit;encode value)
[_ (#Nat value)]
- (nat/encode value)
+ (nat;encode value)
[_ (#Int value)]
- (int/encode value)
+ (int;encode value)
[_ (#Rev value)]
("lux io error" "Undefined behavior.")
[_ (#Frac value)]
- (frac/encode value)
+ (frac;encode value)
[_ (#Text value)]
- ($_ text/compose ..double-quote value ..double-quote)
+ ($_ text;compose ..double-quote value ..double-quote)
[_ (#Identifier [prefix name])]
- (if (text/= "" prefix)
+ (if (text;= "" prefix)
name
- ($_ text/compose prefix "." name))
+ ($_ text;compose prefix "." name))
[_ (#Tag [prefix name])]
- (if (text/= "" prefix)
- ($_ text/compose "#" name)
- ($_ text/compose "#" prefix "." name))
+ (if (text;= "" prefix)
+ ($_ text;compose "#" name)
+ ($_ text;compose "#" prefix "." name))
[_ (#Form xs)]
- ($_ text/compose "(" (|> xs
- (list/map code-to-text)
+ ($_ text;compose "(" (|> xs
+ (list;map code-to-text)
(interpose " ")
- list/reverse
- (list/fold text/compose "")) ")")
+ list;reverse
+ (list;fold text;compose "")) ")")
[_ (#Tuple xs)]
- ($_ text/compose "[" (|> xs
- (list/map code-to-text)
+ ($_ text;compose "[" (|> xs
+ (list;map code-to-text)
(interpose " ")
- list/reverse
- (list/fold text/compose "")) "]")
+ list;reverse
+ (list;fold text;compose "")) "]")
[_ (#Record kvs)]
- ($_ text/compose "{" (|> kvs
- (list/map (function' [kv] ({[k v] ($_ text/compose (code-to-text k) " " (code-to-text v))}
+ ($_ text;compose "{" (|> kvs
+ (list;map (function' [kv] ({[k v] ($_ text;compose (code-to-text k) " " (code-to-text v))}
kv)))
(interpose " ")
- list/reverse
- (list/fold text/compose "")) "}")}
+ list;reverse
+ (list;fold text;compose "")) "}")}
code))
(def:' (expander branches)
@@ -3121,11 +3121,11 @@
(do meta-monad [] (wrap (list)))
_
- (fail ($_ text/compose "'lux.case' expects an even number of tokens: " (|> branches
- (list/map code-to-text)
+ (fail ($_ text;compose "'lux.case' expects an even number of tokens: " (|> branches
+ (list;map code-to-text)
(interpose " ")
- list/reverse
- (list/fold text/compose ""))))}
+ list;reverse
+ (list;fold text;compose ""))))}
branches))
(macro:' #export (case tokens)
@@ -3195,9 +3195,9 @@
_
(let' [pairs (|> patterns
- (list/map (function' [pattern] (list pattern body)))
- (list/join))]
- (return (list/compose pairs branches))))
+ (list;map (function' [pattern] (list pattern body)))
+ (list;join))]
+ (return (list;compose pairs branches))))
_
(fail "Wrong syntax for ^or")))
@@ -3220,9 +3220,9 @@
" (op x y))"))])
(case tokens
(^ (list [_ (#Tuple bindings)] body))
- (if (multiple? 2 (list/size bindings))
- (|> bindings as-pairs list/reverse
- (list/fold (: (-> [Code Code] Code Code)
+ (if (multiple? 2 (list;size bindings))
+ (|> bindings as-pairs list;reverse
+ (list;fold (: (-> [Code Code] Code Code)
(function' [lr body']
(let' [[l r] lr]
(if (identifier? l)
@@ -3256,14 +3256,14 @@
(#Some g!name head tail body)
(let [g!blank (identifier$ ["" ""])
g!name (identifier$ ["" g!name])
- body+ (list/fold (: (-> Code Code Code)
+ body+ (list;fold (: (-> Code Code Code)
(function' [arg body']
(if (identifier? arg)
(` ([(~ g!blank) (~ arg)] (~ body')))
(` ([(~ g!blank) (~ g!blank)]
(case (~ g!blank) (~ arg) (~ body')))))))
body
- (list/reverse tail))]
+ (list;reverse tail))]
(return (list (if (identifier? head)
(` ([(~ g!name) (~ head)] (~ body+)))
(` ([(~ g!name) (~ g!blank)] (case (~ g!blank) (~ head) (~ body+))))))))
@@ -3300,13 +3300,13 @@
[_ (#Tuple xs)]
(|> xs
- (list/map process-def-meta-value)
+ (list;map process-def-meta-value)
untemplate-list
(meta-code ["lux" "Tuple"]))
[_ (#Record kvs)]
(|> kvs
- (list/map (: (-> [Code Code] Code)
+ (list;map (: (-> [Code Code] Code)
(function (_ [k v])
(` [(~ (process-def-meta-value k))
(~ (process-def-meta-value v))]))))
@@ -3316,7 +3316,7 @@
(def:' (process-def-meta kvs)
(-> (List [Code Code]) Code)
- (untemplate-list (list/map (: (-> [Code Code] Code)
+ (untemplate-list (list;map (: (-> [Code Code] Code)
(function (_ [k v])
(` [(~ (process-def-meta-value k))
(~ (process-def-meta-value v))])))
@@ -3330,14 +3330,14 @@
_
(` (#.Cons [[(~ cursor-code) (#.Tag ["lux" "func-args"])]
- [(~ cursor-code) (#.Tuple (.list (~+ (list/map (function (_ arg)
+ [(~ cursor-code) (#.Tuple (.list (~+ (list;map (function (_ arg)
(` [(~ cursor-code) (#.Text (~ (text$ (code-to-text arg))))]))
args))))]]
(~ meta)))))
(def:' (with-type-args args)
(-> (List Code) Code)
- (` {#.type-args [(~+ (list/map (function (_ arg) (text$ (code-to-text arg)))
+ (` {#.type-args [(~+ (list;map (function (_ arg) (text$ (code-to-text arg)))
args))]}))
(def:' (export^ tokens)
@@ -3435,7 +3435,7 @@
(-> Code Code Code)
(case addition
[cursor (#Record pairs)]
- (list/fold meta-code-add base pairs)
+ (list;fold meta-code-add base pairs)
_
base))
@@ -3523,9 +3523,9 @@
(#Some name args meta sigs)
(do meta-monad
[name+ (normalize name)
- sigs' (monad/map meta-monad macro-expand sigs)
+ sigs' (monad;map meta-monad macro-expand sigs)
members (: (Meta (List [Text Code]))
- (monad/map meta-monad
+ (monad;map meta-monad
(: (-> Code (Meta [Text Code]))
(function (_ token)
(case token
@@ -3534,10 +3534,10 @@
_
(fail "Signatures require typed members!"))))
- (list/join sigs')))
+ (list;join sigs')))
#let [[_module _name] name+
def-name (identifier$ name)
- sig-type (record$ (list/map (: (-> [Text Code] [Code Code])
+ sig-type (record$ (list;map (: (-> [Text Code] [Code Code])
(function (_ [m-name m-type])
[(tag$ ["" m-name]) m-type]))
members))
@@ -3572,9 +3572,9 @@
(do-template [<name> <form> <message> <doc-msg>]
[(macro: #export (<name> tokens)
{#.doc <doc-msg>}
- (case (list/reverse tokens)
+ (case (list;reverse tokens)
(^ (list& last init))
- (return (list (list/fold (: (-> Code Code Code)
+ (return (list (list;fold (: (-> Code Code Code)
(function (_ pre post) (` <form>)))
last
init)))
@@ -3650,7 +3650,7 @@
_
(#Left "Wrong syntax for default")))
-(def: (text/split-all-with splitter input)
+(def: (text;split-all-with splitter input)
(-> Text Text (List Text))
(case (index-of splitter input)
#None
@@ -3658,7 +3658,7 @@
(#Some idx)
(list& ("lux text clip" input 0 idx)
- (text/split-all-with splitter
+ (text;split-all-with splitter
("lux text clip" input (n/+ 1 idx) ("lux text size" input))))))
(def: (nth idx xs)
@@ -3803,7 +3803,7 @@
(#Right state module)
_
- (#Left ($_ text/compose "Unknown module: " name))))))
+ (#Left ($_ text;compose "Unknown module: " name))))))
(def: get-current-module
(Meta Module)
@@ -3821,7 +3821,7 @@
(return output)
_
- (fail (text/compose "Unknown tag: " (name/encode [module name]))))))
+ (fail (text;compose "Unknown tag: " (name;encode [module name]))))))
(def: (resolve-type-tags type)
(-> Type (Meta (Maybe [(List Name) (List Type)])))
@@ -3871,7 +3871,7 @@
(macro: #export (structure tokens)
{#.doc "Not meant to be used directly. Prefer 'structure:'."}
(do meta-monad
- [tokens' (monad/map meta-monad macro-expand tokens)
+ [tokens' (monad;map meta-monad macro-expand tokens)
struct-type get-expected-type
tags+type (resolve-type-tags struct-type)
tags (: (Meta (List Name))
@@ -3882,9 +3882,9 @@
_
(fail "No tags available for type.")))
#let [tag-mappings (: (List [Text Code])
- (list/map (function (_ tag) [(second tag) (tag$ tag)])
+ (list;map (function (_ tag) [(second tag) (tag$ tag)])
tags))]
- members (monad/map meta-monad
+ members (monad;map meta-monad
(: (-> Code (Meta [Code Code]))
(function (_ token)
(case token
@@ -3894,22 +3894,22 @@
(wrap [tag value])
_
- (fail (text/compose "Unknown structure member: " tag-name)))
+ (fail (text;compose "Unknown structure member: " tag-name)))
_
(fail "Invalid structure member."))))
- (list/join tokens'))]
+ (list;join tokens'))]
(wrap (list (record$ members)))))
-(def: (text/join-with separator parts)
+(def: (text;join-with separator parts)
(-> Text (List Text) Text)
(case parts
#Nil
""
(#Cons head tail)
- (list/fold (function (_ right left)
- ($_ text/compose left separator right))
+ (list;fold (function (_ right left)
+ ($_ text;compose left separator right))
head
tail)))
@@ -4007,7 +4007,7 @@
type-meta (: Code
(case tags??
(#Some tags)
- (` {#.tags [(~+ (list/map text$ tags))]
+ (` {#.tags [(~+ (list;map text$ tags))]
#.type? #1})
_
@@ -4078,7 +4078,7 @@
(def: (extract-defs defs)
(-> (List Code) (Meta (List Text)))
- (monad/map meta-monad
+ (monad;map meta-monad
(: (-> Code (Meta Text))
(function (_ def)
(case def
@@ -4123,7 +4123,7 @@
(^ (list& [_ (#Form (list& [_ (#Text prefix)] structs))] parts'))
(do meta-monad
- [structs' (monad/map meta-monad
+ [structs' (monad;map meta-monad
(function (_ struct)
(case struct
[_ (#Identifier ["" struct-name])]
@@ -4184,23 +4184,23 @@
(count-ups (n/+ 1 ups) input)
ups)))
-(def: (list/take amount list)
+(def: (list;take amount list)
(All [a] (-> Nat (List a) (List a)))
(case [amount list]
(^or [0 _] [_ #Nil])
#Nil
[_ (#Cons head tail)]
- (#Cons head (list/take (n/- 1 amount) tail))))
+ (#Cons head (list;take (n/- 1 amount) tail))))
-(def: (list/drop amount list)
+(def: (list;drop amount list)
(All [a] (-> Nat (List a) (List a)))
(case [amount list]
(^or [0 _] [_ #Nil])
list
[_ (#Cons _ tail)]
- (list/drop (n/- 1 amount) tail)))
+ (list;drop (n/- 1 amount) tail)))
(def: (clean-module nested? relative-root module)
(-> Bit Text Text (Meta Text))
@@ -4211,18 +4211,18 @@
module))
ups
- (let [parts (text/split-all-with ..module-separator relative-root)]
- (if (n/< (list/size parts) (n/- 1 ups))
+ (let [parts (text;split-all-with ..module-separator relative-root)]
+ (if (n/< (list;size parts) (n/- 1 ups))
(let [prefix (|> parts
- list/reverse
- (list/drop (n/- 1 ups))
- list/reverse
+ list;reverse
+ (list;drop (n/- 1 ups))
+ list;reverse
(interpose ..module-separator)
- (text/join-with ""))
+ (text;join-with ""))
clean ("lux text clip" module ups ("lux text size" module))
output (case ("lux text size" clean)
0 prefix
- _ ($_ text/compose prefix ..module-separator clean))]
+ _ ($_ text;compose prefix ..module-separator clean))]
(return output))
(fail ($_ "lux text concat"
"Cannot climb the module hierarchy..." ..new-line
@@ -4232,22 +4232,22 @@
(def: (alter-domain alteration domain import)
(-> Nat Text Importation Importation)
(let [[import-name import-alias import-refer] import
- original (text/split-all-with ..module-separator import-name)
- truncated (list/drop (.nat alteration) original)
+ original (text;split-all-with ..module-separator import-name)
+ truncated (list;drop (.nat alteration) original)
parallel (case domain
""
truncated
_
(list& domain truncated))]
- {#import-name (text/join-with ..module-separator parallel)
+ {#import-name (text;join-with ..module-separator parallel)
#import-alias import-alias
#import-refer import-refer}))
(def: (parse-imports nested? relative-root context-alias imports)
(-> Bit Text Text (List Code) (Meta (List Importation)))
(do meta-monad
- [imports' (monad/map meta-monad
+ [imports' (monad;map meta-monad
(: (-> Code (Meta (List Importation)))
(function (_ token)
(case token
@@ -4300,27 +4300,27 @@
parallel-tree]))])
(do meta-monad
[parallel-imports (parse-imports nested? relative-root context-alias (list parallel-tree))]
- (wrap (list/map (alter-domain alteration domain) parallel-imports)))
+ (wrap (list;map (alter-domain alteration domain) parallel-imports)))
(^ [_ (#Record (list [[_ (#Nat alteration)]
parallel-tree]))])
(do meta-monad
[parallel-imports (parse-imports nested? relative-root context-alias (list parallel-tree))]
- (wrap (list/map (alter-domain alteration "") parallel-imports)))
+ (wrap (list;map (alter-domain alteration "") parallel-imports)))
(^ [_ (#Record (list [[_ (#Tag ["" domain])]
parallel-tree]))])
(do meta-monad
[parallel-imports (parse-imports nested? relative-root context-alias (list parallel-tree))
- #let [alteration (list/size (text/split-all-with ..module-separator domain))]]
- (wrap (list/map (alter-domain alteration domain) parallel-imports)))
+ #let [alteration (list;size (text;split-all-with ..module-separator domain))]]
+ (wrap (list;map (alter-domain alteration domain) parallel-imports)))
_
(do meta-monad
[current-module current-module-name]
- (fail (text/compose "Wrong syntax for import @ " current-module))))))
+ (fail (text;compose "Wrong syntax for import @ " current-module))))))
imports)]
- (wrap (list/join imports'))))
+ (wrap (list;join imports'))))
(def: (exported-definitions module state)
(-> Text (Meta (List Text)))
@@ -4332,7 +4332,7 @@
modules)]
(case (get module modules)
(#Some =module)
- (let [to-alias (list/map (: (-> [Text Definition]
+ (let [to-alias (list;map (: (-> [Text Definition]
(List Text))
(function (_ [name [def-type def-meta def-value]])
(case (get-meta ["lux" "export?"] def-meta)
@@ -4343,10 +4343,10 @@
(list))))
(let [{#module-hash _ #module-aliases _ #definitions definitions #imports _ #tags tags #types types #module-annotations _ #module-state _} =module]
definitions))]
- (#Right state (list/join to-alias)))
+ (#Right state (list;join to-alias)))
#None
- (#Left ($_ text/compose "Unknown module: " module)))
+ (#Left ($_ text;compose "Unknown module: " module)))
))
(def: (filter p xs)
@@ -4362,9 +4362,9 @@
(def: (is-member? cases name)
(-> (List Text) Text Bit)
- (let [output (list/fold (function (_ case prev)
+ (let [output (list;fold (function (_ case prev)
(or prev
- (text/= case name)))
+ (text;= case name)))
#0
cases)]
output))
@@ -4392,7 +4392,7 @@
#captured {#counter _ #mappings closure}}
(try-both (find (: (-> [Text [Type Any]] (Maybe Type))
(function (_ [bname [type _]])
- (if (text/= name bname)
+ (if (text;= name bname)
(#Some type)
#None))))
(: (List [Text [Type Any]]) locals)
@@ -4427,12 +4427,12 @@
#scope-type-vars scope-type-vars} state]
(case (get v-prefix modules)
#None
- (#Left (text/compose "Unknown definition: " (name/encode name)))
+ (#Left (text;compose "Unknown definition: " (name;encode name)))
(#Some {#definitions definitions #module-hash _ #module-aliases _ #imports _ #tags tags #types types #module-annotations _ #module-state _})
(case (get v-name definitions)
#None
- (#Left (text/compose "Unknown definition: " (name/encode name)))
+ (#Left (text;compose "Unknown definition: " (name;encode name)))
(#Some [def-type def-meta def-value])
(#Right [state [def-type def-value]])))))
@@ -4454,7 +4454,7 @@
[#let [[module name] full-name]
current-module current-module-name]
(function (_ compiler)
- (let [temp (if (text/= "" module)
+ (let [temp (if (text;= "" module)
(case (find-in-env name compiler)
(#Some struct-type)
(#Right [compiler struct-type])
@@ -4465,13 +4465,13 @@
(#Right [compiler struct-type])
_
- (#Left ($_ text/compose "Unknown var: " (name/encode full-name)))))
+ (#Left ($_ text;compose "Unknown var: " (name;encode full-name)))))
(case (find-def-type full-name compiler)
(#Some struct-type)
(#Right [compiler struct-type])
_
- (#Left ($_ text/compose "Unknown var: " (name/encode full-name)))))]
+ (#Left ($_ text;compose "Unknown var: " (name;encode full-name)))))]
(case temp
(#Right [compiler (#Var type-id)])
(let [{#info _ #source _ #current-module _ #modules _
@@ -4504,7 +4504,7 @@
_
(list)))
-(def: (type/encode type)
+(def: (type;encode type)
(-> Type Text)
(case type
(#Primitive name params)
@@ -4513,41 +4513,41 @@
name
_
- ($_ text/compose "(" name " " (|> params (list/map type/encode) (interpose " ") list/reverse (list/fold text/compose "")) ")"))
+ ($_ text;compose "(" name " " (|> params (list;map type;encode) (interpose " ") list;reverse (list;fold text;compose "")) ")"))
(#Sum _)
- ($_ text/compose "(| " (|> (flatten-variant type) (list/map type/encode) (interpose " ") list/reverse (list/fold text/compose "")) ")")
+ ($_ text;compose "(| " (|> (flatten-variant type) (list;map type;encode) (interpose " ") list;reverse (list;fold text;compose "")) ")")
(#Product _)
- ($_ text/compose "[" (|> (flatten-tuple type) (list/map type/encode) (interpose " ") list/reverse (list/fold text/compose "")) "]")
+ ($_ text;compose "[" (|> (flatten-tuple type) (list;map type;encode) (interpose " ") list;reverse (list;fold text;compose "")) "]")
(#Function _)
- ($_ text/compose "(-> " (|> (flatten-lambda type) (list/map type/encode) (interpose " ") list/reverse (list/fold text/compose "")) ")")
+ ($_ text;compose "(-> " (|> (flatten-lambda type) (list;map type;encode) (interpose " ") list;reverse (list;fold text;compose "")) ")")
(#Parameter id)
- (nat/encode id)
+ (nat;encode id)
(#Var id)
- ($_ text/compose "⌈v:" (nat/encode id) "⌋")
+ ($_ text;compose "⌈v:" (nat;encode id) "⌋")
(#Ex id)
- ($_ text/compose "⟨e:" (nat/encode id) "⟩")
+ ($_ text;compose "⟨e:" (nat;encode id) "⟩")
(#UnivQ env body)
- ($_ text/compose "(All " (type/encode body) ")")
+ ($_ text;compose "(All " (type;encode body) ")")
(#ExQ env body)
- ($_ text/compose "(Ex " (type/encode body) ")")
+ ($_ text;compose "(Ex " (type;encode body) ")")
(#Apply _)
(let [[func args] (flatten-app type)]
- ($_ text/compose
- "(" (type/encode func) " "
- (|> args (list/map type/encode) (interpose " ") list/reverse (list/fold text/compose ""))
+ ($_ text;compose
+ "(" (type;encode func) " "
+ (|> args (list;map type;encode) (interpose " ") list;reverse (list;fold text;compose ""))
")"))
(#Named [prefix name] _)
- ($_ text/compose prefix "." name)
+ ($_ text;compose prefix "." name)
))
(macro: #export (^open tokens)
@@ -4569,13 +4569,13 @@
struct-evidence (resolve-type-tags init-type)]
(case struct-evidence
#None
- (fail (text/compose "Can only 'open' structs: " (type/encode init-type)))
+ (fail (text;compose "Can only 'open' structs: " (type;encode init-type)))
(#Some tags&members)
(do meta-monad
[full-body ((: (-> Name [(List Name) (List Type)] Code (Meta Code))
(function (recur source [tags members] target)
- (let [pattern (record$ (list/map (function (_ [t-module t-name])
+ (let [pattern (record$ (list;map (function (_ [t-module t-name])
[(tag$ [t-module t-name])
(identifier$ ["" (de-alias "" t-name alias)])])
tags))]
@@ -4609,11 +4609,11 @@
__paragraph
" ## else-branch" ..new-line
" ''???'')"))}
- (if (n/= 0 (n/% 2 (list/size tokens)))
+ (if (n/= 0 (n/% 2 (list;size tokens)))
(fail "cond requires an uneven number of arguments.")
- (case (list/reverse tokens)
+ (case (list;reverse tokens)
(^ (list& else branches'))
- (return (list (list/fold (: (-> [Code Code] Code Code)
+ (return (list (list;fold (: (-> [Code Code] Code Code)
(function (_ branch else)
(let [[right left] branch]
(` (if (~ left) (~ right) (~ else))))))
@@ -4657,7 +4657,7 @@
g!output (gensym "")]
(case (resolve-struct-type type)
(#Some members)
- (let [pattern (record$ (list/map (: (-> [Name [Nat Type]] [Code Code])
+ (let [pattern (record$ (list;map (: (-> [Name [Nat Type]] [Code Code])
(function (_ [[r-prefix r-name] [r-idx r-type]])
[(tag$ [r-prefix r-name])
(if (n/= idx r-idx)
@@ -4670,7 +4670,7 @@
(fail "get@ can only use records.")))
(^ (list [_ (#Tuple slots)] record))
- (return (list (list/fold (: (-> Code Code Code)
+ (return (list (list;fold (: (-> Code Code Code)
(function (_ slot inner)
(` (..get@ (~ slot) (~ inner)))))
record
@@ -4693,11 +4693,11 @@
(case output
(#Some [tags members])
(do meta-monad
- [decls' (monad/map meta-monad
+ [decls' (monad;map meta-monad
(: (-> [Name Type] (Meta (List Code)))
(function (_ [sname stype]) (open-field alias sname source+ stype)))
(zip2 tags members))]
- (return (list/join decls')))
+ (return (list;join decls')))
_
(return (list (` ("lux def" (~ (identifier$ ["" (de-alias "" name alias)]))
@@ -4727,14 +4727,14 @@
(case output
(#Some [tags members])
(do meta-monad
- [decls' (monad/map meta-monad (: (-> [Name Type] (Meta (List Code)))
+ [decls' (monad;map meta-monad (: (-> [Name Type] (Meta (List Code)))
(function (_ [sname stype])
(open-field alias sname source stype)))
(zip2 tags members))]
- (return (list/join decls')))
+ (return (list;join decls')))
_
- (fail (text/compose "Can only 'open:' structs: " (type/encode struct-type)))))
+ (fail (text;compose "Can only 'open:' structs: " (type;encode struct-type)))))
_
(do meta-monad
@@ -4749,9 +4749,9 @@
(macro: #export (|>> tokens)
{#.doc (text$ ($_ "lux text concat"
"## Similar to the piping macro, but rather than taking an initial object to work on, creates a function for taking it." ..new-line
- "(|>> (list/map int/encode) (interpose '' '') (fold text/compose ''''))" ..new-line
+ "(|>> (list;map int;encode) (interpose '' '') (fold text;compose ''''))" ..new-line
"## =>" ..new-line
- "(function (_ <arg>) (fold text/compose '''' (interpose '' '' (list/map int/encode <arg>))))"))}
+ "(function (_ <arg>) (fold text;compose '''' (interpose '' '' (list;map int;encode <arg>))))"))}
(do meta-monad
[g!_ (gensym "_")
g!arg (gensym "arg")]
@@ -4760,9 +4760,9 @@
(macro: #export (<<| tokens)
{#.doc (text$ ($_ "lux text concat"
"## Similar to the piping macro, but rather than taking an initial object to work on, creates a function for taking it." ..new-line
- "(<<| (fold text/compose '''') (interpose '' '') (list/map int/encode))" ..new-line
+ "(<<| (fold text;compose '''') (interpose '' '') (list;map int;encode))" ..new-line
"## =>" ..new-line
- "(function (_ <arg>) (fold text/compose '''' (interpose '' '' (list/map int/encode <arg>))))"))}
+ "(function (_ <arg>) (fold text;compose '''' (interpose '' '' (list;map int;encode <arg>))))"))}
(do meta-monad
[g!_ (gensym "_")
g!arg (gensym "arg")]
@@ -4785,12 +4785,12 @@
current-module current-module-name
#let [test-referrals (: (-> Text (List Text) (List Text) (Meta (List Any)))
(function (_ module-name all-defs referred-defs)
- (monad/map meta-monad
+ (monad;map meta-monad
(: (-> Text (Meta Any))
(function (_ _def)
(if (is-member? all-defs _def)
(return [])
- (fail ($_ text/compose _def " is not defined in module " module-name " @ " current-module)))))
+ (fail ($_ text;compose _def " is not defined in module " module-name " @ " current-module)))))
referred-defs)))]]
(case options
#Nil
@@ -4798,11 +4798,11 @@
#refer-open openings})
_
- (fail ($_ text/compose "Wrong syntax for refer @ " current-module
+ (fail ($_ text;compose "Wrong syntax for refer @ " current-module
..new-line (|> options
- (list/map code-to-text)
+ (list;map code-to-text)
(interpose " ")
- (list/fold text/compose "")))))))
+ (list;fold text;compose "")))))))
(def: (write-refer module-name [r-defs r-opens])
(-> Text Refer (Meta (List Code)))
@@ -4810,12 +4810,12 @@
[current-module current-module-name
#let [test-referrals (: (-> Text (List Text) (List Text) (Meta (List Any)))
(function (_ module-name all-defs referred-defs)
- (monad/map meta-monad
+ (monad;map meta-monad
(: (-> Text (Meta Any))
(function (_ _def)
(if (is-member? all-defs _def)
(return [])
- (fail ($_ text/compose _def " is not defined in module " module-name " @ " current-module)))))
+ (fail ($_ text;compose _def " is not defined in module " module-name " @ " current-module)))))
referred-defs)))]
defs' (case r-defs
#All
@@ -4838,7 +4838,7 @@
#Nothing
(wrap (list)))
- #let [defs (list/map (: (-> Text Code)
+ #let [defs (list;map (: (-> Text Code)
(function (_ def)
(` ("lux def" (~ (identifier$ ["" def]))
(~ (identifier$ [module-name def]))
@@ -4849,11 +4849,11 @@
defs')
openings (join-map (: (-> Openings (List Code))
(function (_ [alias structs])
- (list/map (function (_ name)
+ (list;map (function (_ name)
(` (open: (~ (text$ alias)) (~ (identifier$ [module-name name])))))
structs)))
r-opens)]]
- (wrap (list/compose defs openings))
+ (wrap (list;compose defs openings))
))
(macro: #export (refer tokens)
@@ -4875,19 +4875,19 @@
(list (' #*))
(#Only defs)
- (list (form$ (list& (' #+) (list/map local-identifier$ defs))))
+ (list (form$ (list& (' #+) (list;map local-identifier$ defs))))
(#Exclude defs)
- (list (form$ (list& (' #-) (list/map local-identifier$ defs))))
+ (list (form$ (list& (' #-) (list;map local-identifier$ defs))))
#Ignore
(list)
#Nothing
(list)))
- openings (list/map (function (_ [alias structs])
+ openings (list;map (function (_ [alias structs])
(form$ (list& (text$ (..replace-all ..contextual-reference module-alias alias))
- (list/map local-identifier$ structs))))
+ (list;map local-identifier$ structs))))
r-opens)]
(` (..refer (~ (text$ module-name))
(~+ localizations)
@@ -4906,7 +4906,7 @@
" [''M'' monad #*]]" ..new-line
" [data" ..new-line
" maybe" ..new-line
- " [''.'' name (''name/.'' codec)]]" ..new-line
+ " [''.'' name (''#/.'' codec)]]" ..new-line
" [macro" ..new-line
" code]]" ..new-line
" [//" ..new-line
@@ -4921,11 +4921,11 @@
[(list) tokens]))]
current-module current-module-name
imports (parse-imports #0 current-module "" _imports)
- #let [=imports (list/map (: (-> Importation Code)
+ #let [=imports (list;map (: (-> Importation Code)
(function (_ [m-name m-alias =refer])
(` [(~ (text$ m-name)) (~ (text$ (default "" m-alias)))])))
imports)
- =refers (list/map (: (-> Importation Code)
+ =refers (list;map (: (-> Importation Code)
(function (_ [m-name m-alias =refer])
(refer-to-code m-name m-alias =refer)))
imports)
@@ -4972,19 +4972,19 @@
(case (resolve-struct-type type)
(#Some members)
(do meta-monad
- [pattern' (monad/map meta-monad
+ [pattern' (monad;map meta-monad
(: (-> [Name [Nat Type]] (Meta [Name Nat Code]))
(function (_ [r-slot-name [r-idx r-type]])
(do meta-monad
[g!slot (gensym "")]
(return [r-slot-name r-idx g!slot]))))
(zip2 tags (enumerate members)))]
- (let [pattern (record$ (list/map (: (-> [Name Nat Code] [Code Code])
+ (let [pattern (record$ (list;map (: (-> [Name Nat Code] [Code Code])
(function (_ [r-slot-name r-idx r-var])
[(tag$ r-slot-name)
r-var]))
pattern'))
- output (record$ (list/map (: (-> [Name Nat Code] [Code Code])
+ output (record$ (list;map (: (-> [Name Nat Code] [Code Code])
(function (_ [r-slot-name r-idx r-var])
[(tag$ r-slot-name)
(if (n/= idx r-idx)
@@ -5003,23 +5003,23 @@
_
(do meta-monad
- [bindings (monad/map meta-monad
+ [bindings (monad;map meta-monad
(: (-> Code (Meta Code))
(function (_ _) (gensym "temp")))
slots)
#let [pairs (zip2 slots bindings)
- update-expr (list/fold (: (-> [Code Code] Code Code)
+ update-expr (list;fold (: (-> [Code Code] Code Code)
(function (_ [s b] v)
(` (..set@ (~ s) (~ v) (~ b)))))
value
- (list/reverse pairs))
- [_ accesses'] (list/fold (: (-> [Code Code] [Code (List (List Code))] [Code (List (List Code))])
+ (list;reverse pairs))
+ [_ accesses'] (list;fold (: (-> [Code Code] [Code (List (List Code))] [Code (List (List Code))])
(function (_ [new-slot new-binding] [old-record accesses'])
[(` (get@ (~ new-slot) (~ new-binding)))
(#Cons (list new-binding old-record) accesses')]))
[record (: (List (List Code)) #Nil)]
pairs)
- accesses (list/join (list/reverse accesses'))]]
+ accesses (list;join (list;reverse accesses'))]]
(wrap (list (` (let [(~+ accesses)]
(~ update-expr)))))))
@@ -5059,19 +5059,19 @@
(case (resolve-struct-type type)
(#Some members)
(do meta-monad
- [pattern' (monad/map meta-monad
+ [pattern' (monad;map meta-monad
(: (-> [Name [Nat Type]] (Meta [Name Nat Code]))
(function (_ [r-slot-name [r-idx r-type]])
(do meta-monad
[g!slot (gensym "")]
(return [r-slot-name r-idx g!slot]))))
(zip2 tags (enumerate members)))]
- (let [pattern (record$ (list/map (: (-> [Name Nat Code] [Code Code])
+ (let [pattern (record$ (list;map (: (-> [Name Nat Code] [Code Code])
(function (_ [r-slot-name r-idx r-var])
[(tag$ r-slot-name)
r-var]))
pattern'))
- output (record$ (list/map (: (-> [Name Nat Code] [Code Code])
+ output (record$ (list;map (: (-> [Name Nat Code] [Code Code])
(function (_ [r-slot-name r-idx r-var])
[(tag$ r-slot-name)
(if (n/= idx r-idx)
@@ -5119,7 +5119,7 @@
" (-> (List Type) Type Type)" ..new-line
" (case type" ..new-line
" (#.Primitive name params)" ..new-line
- " (#.Primitive name (list/map (beta-reduce env) params))"
+ " (#.Primitive name (list;map (beta-reduce env) params))"
__paragraph
" (^template [<tag>]" ..new-line
" (<tag> left right)" ..new-line
@@ -5153,17 +5153,17 @@
branches))
(case (: (Maybe (List Code))
(do maybe-monad
- [bindings' (monad/map maybe-monad get-short bindings)
- data' (monad/map maybe-monad tuple->list data)]
- (if (every? (n/= (list/size bindings')) (list/map list/size data'))
+ [bindings' (monad;map maybe-monad get-short bindings)
+ data' (monad;map maybe-monad tuple->list data)]
+ (if (every? (n/= (list;size bindings')) (list;map list;size data'))
(let [apply (: (-> RepEnv (List Code))
- (function (_ env) (list/map (apply-template env) templates)))]
+ (function (_ env) (list;map (apply-template env) templates)))]
(|> data'
(join-map (compose apply (make-env bindings')))
wrap))
#None)))
(#Some output)
- (return (list/compose output branches))
+ (return (list;compose output branches))
#None
(fail "Wrong syntax for ^template"))
@@ -5197,14 +5197,14 @@
(^template [<tag>]
[[_ _ column] (<tag> parts)]
- (list/fold n/min column (list/map find-baseline-column parts)))
+ (list;fold n/min column (list;map find-baseline-column parts)))
([#Form]
[#Tuple])
[[_ _ column] (#Record pairs)]
- (list/fold n/min column
- (list/compose (list/map (|>> first find-baseline-column) pairs)
- (list/map (|>> second find-baseline-column) pairs)))
+ (list;fold n/min column
+ (list;compose (list;map (|>> first find-baseline-column) pairs)
+ (list;map (|>> second find-baseline-column) pairs)))
))
(type: Doc-Fragment
@@ -5220,9 +5220,9 @@
_
(#Doc-Example code)))
-(def: (text/encode original)
+(def: (text;encode original)
(-> Text Text)
- ($_ text/compose ..double-quote original ..double-quote))
+ ($_ text;compose ..double-quote original ..double-quote))
(do-template [<name> <extension> <doc>]
[(def: #export (<name> value)
@@ -5234,9 +5234,9 @@
[dec "lux i64 -" "Decrement function."]
)
-(def: tag/encode
+(def: tag;encode
(-> Name Text)
- (|>> name/encode (text/compose "#")))
+ (|>> name;encode (text;compose "#")))
(def: (repeat n x)
(All [a] (-> Int a (List a)))
@@ -5247,18 +5247,18 @@
(def: (cursor-padding baseline [_ old-line old-column] [_ new-line new-column])
(-> Nat Cursor Cursor Text)
(if (n/= old-line new-line)
- (text/join-with "" (repeat (.int (n/- old-column new-column)) " "))
- (let [extra-lines (text/join-with "" (repeat (.int (n/- old-line new-line)) ..new-line))
- space-padding (text/join-with "" (repeat (.int (n/- baseline new-column)) " "))]
- (text/compose extra-lines space-padding))))
+ (text;join-with "" (repeat (.int (n/- old-column new-column)) " "))
+ (let [extra-lines (text;join-with "" (repeat (.int (n/- old-line new-line)) ..new-line))
+ space-padding (text;join-with "" (repeat (.int (n/- baseline new-column)) " "))]
+ (text;compose extra-lines space-padding))))
-(def: (text/size x)
+(def: (text;size x)
(-> Text Nat)
("lux text size" x))
(def: (update-cursor [file line column] code-text)
(-> Cursor Text Cursor)
- [file line (n/+ column (text/size code-text))])
+ [file line (n/+ column (text;size code-text))])
(def: (delim-update-cursor [file line column])
(-> Cursor Cursor)
@@ -5266,7 +5266,7 @@
(def: rejoin-all-pairs
(-> (List [Code Code]) (List Code))
- (|>> (list/map rejoin-pair) list/join))
+ (|>> (list;map rejoin-pair) list;join))
(def: (doc-example->Text prev-cursor baseline example)
(-> Cursor Nat Code [Cursor Text])
@@ -5275,25 +5275,25 @@
[new-cursor (<tag> value)]
(let [as-text (<encode> value)]
[(update-cursor new-cursor as-text)
- (text/compose (cursor-padding baseline prev-cursor new-cursor)
+ (text;compose (cursor-padding baseline prev-cursor new-cursor)
as-text)]))
- ([#Bit bit/encode]
- [#Nat nat/encode]
- [#Int int/encode]
- [#Frac frac/encode]
- [#Text text/encode]
- [#Identifier name/encode]
- [#Tag tag/encode])
+ ([#Bit bit;encode]
+ [#Nat nat;encode]
+ [#Int int;encode]
+ [#Frac frac;encode]
+ [#Text text;encode]
+ [#Identifier name;encode]
+ [#Tag tag;encode])
(^template [<tag> <open> <close> <prep>]
[group-cursor (<tag> parts)]
- (let [[group-cursor' parts-text] (list/fold (function (_ part [last-cursor text-accum])
+ (let [[group-cursor' parts-text] (list;fold (function (_ part [last-cursor text-accum])
(let [[part-cursor part-text] (doc-example->Text last-cursor baseline part)]
- [part-cursor (text/compose text-accum part-text)]))
+ [part-cursor (text;compose text-accum part-text)]))
[(delim-update-cursor group-cursor) ""]
(<prep> parts))]
[(delim-update-cursor group-cursor')
- ($_ text/compose (cursor-padding baseline prev-cursor group-cursor)
+ ($_ text;compose (cursor-padding baseline prev-cursor group-cursor)
<open>
parts-text
<close>)]))
@@ -5314,15 +5314,15 @@
(case fragment
(#Doc-Comment comment)
(|> comment
- (text/split-all-with ..new-line)
- (list/map (function (_ line) ($_ text/compose "## " line ..new-line)))
- (text/join-with ""))
+ (text;split-all-with ..new-line)
+ (list;map (function (_ line) ($_ text;compose "## " line ..new-line)))
+ (text;join-with ""))
(#Doc-Example example)
(let [baseline (find-baseline-column example)
[cursor _] example
[_ text] (doc-example->Text (with-baseline baseline cursor) baseline example)]
- (text/compose text __paragraph))))
+ (text;compose text __paragraph))))
(macro: #export (doc tokens)
{#.doc (text$ ($_ "lux text concat"
@@ -5338,8 +5338,8 @@
" x)))"))}
(return (list (` [(~ cursor-code)
(#.Text (~ (|> tokens
- (list/map (|>> identify-doc-fragment doc-fragment->Text))
- (text/join-with "")
+ (list;map (|>> identify-doc-fragment doc-fragment->Text))
+ (text;join-with "")
text$)))]))))
(def: (interleave xs ys)
@@ -5360,7 +5360,7 @@
(-> Type Code)
(case type
(#Primitive name params)
- (` (#Primitive (~ (text$ name)) (~ (untemplate-list (list/map type-to-code params)))))
+ (` (#Primitive (~ (text$ name)) (~ (untemplate-list (list;map type-to-code params)))))
(^template [<tag>]
(<tag> left right)
@@ -5380,11 +5380,11 @@
(` (#Ex (~ (nat$ id))))
(#UnivQ env type)
- (let [env' (untemplate-list (list/map type-to-code env))]
+ (let [env' (untemplate-list (list;map type-to-code env))]
(` (#UnivQ (~ env') (~ (type-to-code type)))))
(#ExQ env type)
- (let [env' (untemplate-list (list/map type-to-code env))]
+ (let [env' (untemplate-list (list;map type-to-code env))]
(` (#ExQ (~ env') (~ (type-to-code type)))))
(#Apply arg fun)
@@ -5421,23 +5421,23 @@
(case ?params
(#.Some [name bindings body])
(let [pairs (as-pairs bindings)
- vars (list/map first pairs)
- inits (list/map second pairs)]
+ vars (list;map first pairs)
+ inits (list;map second pairs)]
(if (every? identifier? inits)
(do meta-monad
[inits' (: (Meta (List Name))
- (case (monad/map maybe-monad get-name inits)
+ (case (monad;map maybe-monad get-name inits)
(#Some inits') (return inits')
#None (fail "Wrong syntax for loop")))
- init-types (monad/map meta-monad find-type inits')
+ init-types (monad;map meta-monad find-type inits')
expected get-expected-type]
- (return (list (` (("lux check" (-> (~+ (list/map type-to-code init-types))
+ (return (list (` (("lux check" (-> (~+ (list;map type-to-code init-types))
(~ (type-to-code expected)))
(function ((~ name) (~+ vars))
(~ body)))
(~+ inits))))))
(do meta-monad
- [aliases (monad/map meta-monad
+ [aliases (monad;map meta-monad
(: (-> Code (Meta Code))
(function (_ _) (gensym "")))
inits)]
@@ -5460,7 +5460,7 @@
(case (: (Maybe [Name (List Name)])
(do maybe-monad
[hslot (get-tag hslot')
- tslots (monad/map maybe-monad get-tag tslots')]
+ tslots (monad;map maybe-monad get-tag tslots')]
(wrap [hslot tslots])))
(#Some slots)
(return slots)
@@ -5469,14 +5469,14 @@
(fail "Wrong syntax for ^slots")))
#let [[hslot tslots] slots]
hslot (normalize hslot)
- tslots (monad/map meta-monad normalize tslots)
+ tslots (monad;map meta-monad normalize tslots)
output (resolve-tag hslot)
g!_ (gensym "_")
#let [[idx tags exported? type] output
- slot-pairings (list/map (: (-> Name [Text Code])
+ slot-pairings (list;map (: (-> Name [Text Code])
(function (_ [module name]) [name (identifier$ ["" name])]))
(list& hslot tslots))
- pattern (record$ (list/map (: (-> Name [Code Code])
+ pattern (record$ (list;map (: (-> Name [Code Code])
(function (_ [module name])
(let [tag (tag$ [module name])]
(case (get name slot-pairings)
@@ -5495,22 +5495,22 @@
(#Some (list target))
[_ (#Identifier [prefix name])]
- (if (and (text/= "" prefix)
- (text/= label name))
+ (if (and (text;= "" prefix)
+ (text;= label name))
(#Some tokens)
(#Some (list target)))
(^template [<tag>]
[cursor (<tag> elems)]
(do maybe-monad
- [placements (monad/map maybe-monad (place-tokens label tokens) elems)]
- (wrap (list [cursor (<tag> (list/join placements))]))))
+ [placements (monad;map maybe-monad (place-tokens label tokens) elems)]
+ (wrap (list [cursor (<tag> (list;join placements))]))))
([#Tuple]
[#Form])
[cursor (#Record pairs)]
(do maybe-monad
- [=pairs (monad/map maybe-monad
+ [=pairs (monad;map maybe-monad
(: (-> [Code Code] (Maybe [Code Code]))
(function (_ [slot value])
(do maybe-monad
@@ -5611,13 +5611,13 @@
["Text" Text text$])
_
- (fail (text/compose "Cannot anti-quote type: " (name/encode name))))))
+ (fail (text;compose "Cannot anti-quote type: " (name;encode name))))))
(def: (anti-quote token)
(-> Code (Meta Code))
(case token
[_ (#Identifier [def-prefix def-name])]
- (if (text/= "" def-prefix)
+ (if (text;= "" def-prefix)
(do meta-monad
[current-module current-module-name]
(anti-quote-def [current-module def-name]))
@@ -5626,14 +5626,14 @@
(^template [<tag>]
[meta (<tag> parts)]
(do meta-monad
- [=parts (monad/map meta-monad anti-quote parts)]
+ [=parts (monad;map meta-monad anti-quote parts)]
(wrap [meta (<tag> =parts)])))
([#Form]
[#Tuple])
[meta (#Record pairs)]
(do meta-monad
- [=pairs (monad/map meta-monad
+ [=pairs (monad;map meta-monad
(: (-> [Code Code] (Meta [Code Code]))
(function (_ [slot value])
(do meta-monad
@@ -5677,12 +5677,12 @@
(#Cons init extras)
(do meta-monad
- [extras' (monad/map meta-monad case-level^ extras)]
+ [extras' (monad;map meta-monad case-level^ extras)]
(wrap [init extras']))))
(def: (multi-level-case$ g!_ [[init-pattern levels] body])
(-> Code [Multi-Level-Case Code] (List Code))
- (let [inner-pattern-body (list/fold (function (_ [calculation pattern] success)
+ (let [inner-pattern-body (list;fold (function (_ [calculation pattern] success)
(` (case (~ calculation)
(~ pattern)
(~ success)
@@ -5690,7 +5690,7 @@
(~ g!_)
#.None)))
(` (#.Some (~ body)))
- (: (List [Code Code]) (list/reverse levels)))]
+ (: (List [Code Code]) (list;reverse levels)))]
(list init-pattern inner-pattern-body)))
(macro: #export (^multi tokens)
@@ -5698,7 +5698,7 @@
"Useful in situations where the result of a branch depends on further refinements on the values being matched."
"For example:"
(case (split (size static) uri)
- (^multi (#.Some [chunk uri']) [(text/= static chunk) #1])
+ (^multi (#.Some [chunk uri']) [(text;= static chunk) #1])
(match-uri endpoint? parts' uri')
_
@@ -5707,7 +5707,7 @@
"Short-cuts can be taken when using bit tests."
"The example above can be rewritten as..."
(case (split (size static) uri)
- (^multi (#.Some [chunk uri']) (text/= static chunk))
+ (^multi (#.Some [chunk uri']) (text;= static chunk))
(match-uri endpoint? parts' uri')
_
@@ -5741,8 +5741,8 @@
## 'wrong-syntax-error' for easier maintenance of the error-messages.
(def: wrong-syntax-error
(-> Name Text)
- (|>> name/encode
- (text/compose "Wrong syntax for ")))
+ (|>> name;encode
+ (text;compose "Wrong syntax for ")))
(macro: #export (name-of tokens)
{#.doc (doc "Given an identifier or a tag, gives back a 2 tuple with the prefix and name parts, both as Text."
@@ -5796,7 +5796,7 @@
"In the example below, 0 corresponds to the 'a' variable."
(def: #export (from-list list)
(All [a] (-> (List a) (Row a)))
- (list/fold add
+ (list;fold add
(: (Row ($ 0))
empty)
list)))}
@@ -5804,12 +5804,12 @@
(^ (list [_ (#Nat idx)]))
(do meta-monad
[stvs get-scope-type-vars]
- (case (list-at idx (list/reverse stvs))
+ (case (list-at idx (list;reverse stvs))
(#Some var-id)
(wrap (list (` (#Ex (~ (nat$ var-id))))))
#None
- (fail (text/compose "Indexed-type does not exist: " (nat/encode idx)))))
+ (fail (text;compose "Indexed-type does not exist: " (nat;encode idx)))))
_
(fail (..wrong-syntax-error (name-of ..$)))))
@@ -5828,7 +5828,7 @@
(macro: #export (^@ tokens)
{#.doc (doc "Allows you to simultaneously bind and de-structure a value."
(def: (hash (^@ set [Hash<a> _]))
- (list/fold (function (_ elem acc) (n/+ (:: Hash<a> hash elem) acc))
+ (list;fold (function (_ elem acc) (n/+ (:: Hash<a> hash elem) acc))
0
(to-list set))))}
(case tokens
@@ -5915,7 +5915,7 @@
(case tokens
(^ (list& [_ (#Form (list& [_ (#Identifier ["" name])] args'))] tokens'))
(do meta-monad
- [args (monad/map meta-monad
+ [args (monad;map meta-monad
(function (_ arg')
(case arg'
[_ (#Identifier ["" arg-name])]
@@ -5987,7 +5987,7 @@
g!tokens (gensym "tokens")
g!compiler (gensym "compiler")
g!_ (gensym "_")
- #let [rep-env (list/map (function (_ arg)
+ #let [rep-env (list;map (function (_ arg)
[arg (` ((~' ~) (~ (identifier$ ["" arg]))))])
args)]
this-module current-module-name]
@@ -5995,9 +5995,9 @@
((~ (identifier$ ["" name])) (~ g!tokens) (~ g!compiler))
(~ anns)
(case (~ g!tokens)
- (^ (list (~+ (list/map (|>> [""] identifier$) args))))
+ (^ (list (~+ (list;map (|>> [""] identifier$) args))))
(#.Right [(~ g!compiler)
- (list (~+ (list/map (function (_ template)
+ (list (~+ (list;map (function (_ template)
(` (`' (~ (replace-syntax rep-env template)))))
input-templates)))])
@@ -6034,7 +6034,7 @@
(#Cons [key value] options')
(case key
(^multi [_ (#Text platform)]
- (text/= target platform))
+ (text;= target platform))
(#Some value)
_
@@ -6051,7 +6051,7 @@
(wrap (list pick))
#None
- (fail ($_ text/compose "No code for target platform: " target)))
+ (fail ($_ text;compose "No code for target platform: " target)))
(^ (list [_ (#Record options)] default))
(wrap (list (..default default (pick-for-target target options))))
@@ -6079,24 +6079,24 @@
(^template [<tag>]
[ann (<tag> parts)]
(do meta-monad
- [=parts (monad/map meta-monad label-code parts)]
- (wrap [(list/fold list/compose (list) (list/map left =parts))
- [ann (<tag> (list/map right =parts))]])))
+ [=parts (monad;map meta-monad label-code parts)]
+ (wrap [(list;fold list;compose (list) (list;map left =parts))
+ [ann (<tag> (list;map right =parts))]])))
([#Form] [#Tuple])
[ann (#Record kvs)]
(do meta-monad
- [=kvs (monad/map meta-monad
+ [=kvs (monad;map meta-monad
(function (_ [key val])
(do meta-monad
[=key (label-code key)
=val (label-code val)
#let [[key-labels key-labelled] =key
[val-labels val-labelled] =val]]
- (wrap [(list/compose key-labels val-labels) [key-labelled val-labelled]])))
+ (wrap [(list;compose key-labels val-labels) [key-labelled val-labelled]])))
kvs)]
- (wrap [(list/fold list/compose (list) (list/map left =kvs))
- [ann (#Record (list/map right =kvs))]]))
+ (wrap [(list;fold list;compose (list) (list;map left =kvs))
+ [ann (#Record (list;map right =kvs))]]))
_
(return [(list) code])))
@@ -6108,8 +6108,8 @@
[=raw (label-code raw)
#let [[labels labelled] =raw]]
(wrap (list (` (with-expansions [(~+ (|> labels
- (list/map (function (_ [label expansion]) (list label expansion)))
- list/join))]
+ (list;map (function (_ [label expansion]) (list label expansion)))
+ list;join))]
(~ labelled))))))
_
@@ -6148,7 +6148,7 @@
[_ (#Record fields)]
(do meta-monad
- [=fields (monad/map meta-monad
+ [=fields (monad;map meta-monad
(function (_ [key value])
(do meta-monad
[=key (untemplate-pattern key)
@@ -6166,17 +6166,17 @@
(^template [<tag>]
[_ (<tag> elems)]
- (case (list/reverse elems)
+ (case (list;reverse elems)
(#Cons [_ (#Form (#Cons [[_ (#Identifier ["" "~+"])] (#Cons [spliced #Nil])]))]
inits)
(do meta-monad
- [=inits (monad/map meta-monad untemplate-pattern (list/reverse inits))
+ [=inits (monad;map meta-monad untemplate-pattern (list;reverse inits))
g!meta (gensym "g!meta")]
(wrap (` [(~ g!meta) (<tag> (~ (untemplate-list& spliced =inits)))])))
_
(do meta-monad
- [=elems (monad/map meta-monad untemplate-pattern elems)
+ [=elems (monad;map meta-monad untemplate-pattern elems)
g!meta (gensym "g!meta")]
(wrap (` [(~ g!meta) (<tag> (~ (untemplate-list =elems)))])))))
([#Tuple] [#Form])
@@ -6247,9 +6247,9 @@
(-> Cursor Text)
(let [separator ", "
fields ($_ "lux text concat"
- (text/encode file) separator
- (nat/encode line) separator
- (nat/encode column))]
+ (text;encode file) separator
+ (nat;encode line) separator
+ (nat;encode column))]
($_ "lux text concat" "[" fields "]")))
(do-template [<zero> <one>]
diff --git a/stdlib/source/lux/cli.lux b/stdlib/source/lux/cli.lux
index 69a7cae7f..8af410d54 100644
--- a/stdlib/source/lux/cli.lux
+++ b/stdlib/source/lux/cli.lux
@@ -7,8 +7,8 @@
["." process]]]
[data
[collection
- ["." list ("#/." monoid monad)]]
- ["." text ("#/." equivalence)
+ ["." list ("#;." monoid monad)]]
+ ["." text ("#;." equivalence)
format]
["." error (#+ Error)]]
[macro (#+ with-gensyms)
@@ -63,7 +63,7 @@
(function (_ inputs)
(do error.monad
[[remaining raw] (any inputs)]
- (if (text/= reference raw)
+ (if (text;= reference raw)
(wrap [remaining []])
(error.fail (format "Missing token: '" reference "'"))))))
@@ -131,7 +131,7 @@
(wrap [])))
(program: [name]
- (io (log! (text/compose "Hello, " name))))
+ (io (log! (text;compose "Hello, " name))))
(program: [{config config^}]
(do io.monad
@@ -153,9 +153,9 @@
(case ((: (~! (..CLI (io.IO .Any)))
((~! do) (~! p.monad)
[(~+ (|> args
- (list/map (function (_ [binding parser])
+ (list;map (function (_ [binding parser])
(list binding parser)))
- list/join))
+ list;join))
(~ g!_) ..end]
((~' wrap) ((~! do) (~! io.monad)
[(~ g!output) (~ body)
diff --git a/stdlib/source/lux/control/comonad.lux b/stdlib/source/lux/control/comonad.lux
index 10171d0ae..1d6ac49e5 100644
--- a/stdlib/source/lux/control/comonad.lux
+++ b/stdlib/source/lux/control/comonad.lux
@@ -2,7 +2,7 @@
[lux #*
[data
[collection
- ["." list ("#/." fold)]]]]
+ ["." list ("#;." fold)]]]]
[//
["." functor (#+ Functor)]])
@@ -36,7 +36,7 @@
(let [g!_ (: Code [_cursor (#.Identifier ["" " _ "])])
g!map (: Code [_cursor (#.Identifier ["" " map "])])
g!split (: Code [_cursor (#.Identifier ["" " split "])])
- body' (list/fold (: (-> [Code Code] Code Code)
+ body' (list;fold (: (-> [Code Code] Code Code)
(function (_ binding body')
(let [[var value] binding]
(case var
diff --git a/stdlib/source/lux/control/concatenative.lux b/stdlib/source/lux/control/concatenative.lux
index c99526fb6..caae325a2 100644
--- a/stdlib/source/lux/control/concatenative.lux
+++ b/stdlib/source/lux/control/concatenative.lux
@@ -5,14 +5,14 @@
r/+ r/- r/* r// r/% r/= r/< r/<= r/> r/>=
f/+ f/- f/* f// f/% f/= f/< f/<= f/> f/>=)
[control
- ["p" parser ("#/." monad)]
+ ["p" parser ("#;." monad)]
["." monad]]
[data
["." text
format]
- ["." maybe ("#/." monad)]
+ ["." maybe ("#;." monad)]
[collection
- ["." list ("#/." fold functor)]]]
+ ["." list ("#;." fold functor)]]]
["." macro (#+ with-gensyms)
["." code]
["s" syntax (#+ syntax:)]
@@ -43,12 +43,12 @@
(s.Syntax Stack)
(p.either (p.and (p.maybe bottom^)
(s.tuple (p.some s.any)))
- (p.and (|> bottom^ (p/map (|>> #.Some)))
- (p/wrap (list)))))
+ (p.and (|> bottom^ (p;map (|>> #.Some)))
+ (p;wrap (list)))))
(def: (stack-fold tops bottom)
(-> (List Code) Code Code)
- (list/fold (function (_ top bottom)
+ (list;fold (function (_ top bottom)
(` [(~ bottom) (~ top)]))
bottom
tops))
@@ -63,18 +63,18 @@
_
(macro.fail (format "Cannot expand to more than a single AST/Code node:" text.new-line
- (|> expansion (list/map %code) (text.join-with " ")))))))
+ (|> expansion (list;map %code) (text.join-with " ")))))))
(syntax: #export (=> {aliases aliases^}
{inputs stack^}
{outputs stack^})
(let [de-alias (function (_ aliased)
- (list/fold (function (_ [from to] pre)
+ (list;fold (function (_ [from to] pre)
(code.replace (code.local-identifier from) to pre))
aliased
aliases))]
- (case [(|> inputs (get@ #bottom) (maybe/map (|>> code.nat (~) #.Parameter (`))))
- (|> outputs (get@ #bottom) (maybe/map (|>> code.nat (~) #.Parameter (`))))]
+ (case [(|> inputs (get@ #bottom) (maybe;map (|>> code.nat (~) #.Parameter (`))))
+ (|> outputs (get@ #bottom) (maybe;map (|>> code.nat (~) #.Parameter (`))))]
[(#.Some bottomI) (#.Some bottomO)]
(monad.do @
[inputC (singleton (macro.expand-all (stack-fold (get@ #top inputs) bottomI)))
@@ -109,13 +109,13 @@
(` (..push (~ command)))
[_ (#.Tuple block)]
- (` (..push (|>> (~+ (list/map prepare block)))))
+ (` (..push (|>> (~+ (list;map prepare block)))))
_
command))
(syntax: #export (||> {commands (p.some s.any)})
- (wrap (list (` (|> (~! ..begin!) (~+ (list/map prepare commands)) (~! ..end!))))))
+ (wrap (list (` (|> (~! ..begin!) (~+ (list;map prepare commands)) (~! ..end!))))))
(syntax: #export (word:
{export csr.export}
@@ -126,7 +126,7 @@
(wrap (list (` (def: (~+ (csw.export export)) (~ (code.local-identifier name))
(~ (csw.annotations annotations))
(~ type)
- (|>> (~+ (list/map prepare commands))))))))
+ (|>> (~+ (list;map prepare commands))))))))
(syntax: #export (apply {arity (|> s.nat (p.filter (.n/> 0)))})
(with-gensyms [g! g!func g!stack g!output]
diff --git a/stdlib/source/lux/control/concurrency/actor.lux b/stdlib/source/lux/control/concurrency/actor.lux
index 7cd6a8fe1..92cf0207e 100644
--- a/stdlib/source/lux/control/concurrency/actor.lux
+++ b/stdlib/source/lux/control/concurrency/actor.lux
@@ -4,14 +4,14 @@
[control monad
["p" parser]
["ex" exception (#+ exception:)]]
- ["." io (#+ IO io) ("#/." monad)]
+ ["." io (#+ IO io) ("#;." monad)]
[data
["." product]
["." error (#+ Error)]
[text
format]
[collection
- ["." list ("#/." monoid monad fold)]]]
+ ["." list ("#;." monoid monad fold)]]]
["." macro (#+ with-gensyms monad)
["." code]
["s" syntax (#+ syntax: Syntax)]
@@ -23,7 +23,7 @@
abstract]]
[//
["." atom (#+ Atom atom)]
- ["." promise (#+ Promise Resolver) ("#/." monad)]])
+ ["." promise (#+ Promise Resolver) ("#;." monad)]])
(exception: #export poisoned)
@@ -133,7 +133,7 @@
(#.Some [_ |mailbox|'])
(recur |mailbox|')))))
- (io/wrap #0)))
+ (io;wrap #0)))
)
)
@@ -143,7 +143,7 @@
(def: (default-end cause state)
(All [s] (-> Text s (Promise Any)))
- (promise/wrap []))
+ (promise;wrap []))
(def: #export default-behavior
(All [s] (Behavior s))
@@ -244,7 +244,7 @@
g!behavior (code.local-identifier (behavior-name _name))
g!actor (code.local-identifier _name)
g!new (code.local-identifier (new-name _name))
- g!vars (list/map code.local-identifier _vars)]]
+ g!vars (list;map code.local-identifier _vars)]]
(wrap (list (` (type: (~+ (csw.export export)) ((~ g!type) (~+ g!vars))
(~ state-type)))
(` (type: (~+ (csw.export export)) ((~ g!actor) (~+ g!vars))
@@ -334,24 +334,24 @@
#let [message-name [current-module (get@ #name signature)]
g!type (code.identifier (product.both function.identity state-name actor-name))
g!message (code.local-identifier (get@ #name signature))
- g!actor-vars (list/map code.local-identifier actor-vars)
+ g!actor-vars (list;map code.local-identifier actor-vars)
actorC (` ((~ (code.identifier actor-name)) (~+ g!actor-vars)))
- g!all-vars (|> (get@ #vars signature) (list/map code.local-identifier) (list/compose g!actor-vars))
- g!inputsC (|> (get@ #inputs signature) (list/map product.left))
- g!inputsT (|> (get@ #inputs signature) (list/map product.right))
+ g!all-vars (|> (get@ #vars signature) (list;map code.local-identifier) (list;compose g!actor-vars))
+ g!inputsC (|> (get@ #inputs signature) (list;map product.left))
+ g!inputsT (|> (get@ #inputs signature) (list;map product.right))
g!state (|> signature (get@ #state) code.local-identifier)
g!self (|> signature (get@ #self) code.local-identifier)
g!actor-refs (: (List Code)
(if (list.empty? actor-vars)
(list)
- (|> actor-vars list.size list.indices (list/map (|>> code.nat (~) ($) (`))))))
+ (|> actor-vars list.size list.indices (list;map (|>> code.nat (~) ($) (`))))))
ref-replacements (|> (if (list.empty? actor-vars)
(list)
- (|> actor-vars list.size list.indices (list/map (|>> code.nat (~) ($) (`)))))
+ (|> actor-vars list.size list.indices (list;map (|>> code.nat (~) ($) (`)))))
(: (List Code))
(list.zip2 g!all-vars)
(: (List [Code Code])))
- g!outputT (list/fold (function (_ [g!var g!ref] outputT)
+ g!outputT (list;fold (function (_ [g!var g!ref] outputT)
(code.replace g!var g!ref outputT))
(get@ #output signature)
ref-replacements)]]
diff --git a/stdlib/source/lux/control/concurrency/frp.lux b/stdlib/source/lux/control/concurrency/frp.lux
index 0dae2798e..a91a4f531 100644
--- a/stdlib/source/lux/control/concurrency/frp.lux
+++ b/stdlib/source/lux/control/concurrency/frp.lux
@@ -9,15 +9,15 @@
["." monad (#+ Monad do)]
["ex" exception (#+ exception:)]]
[data
- ["." maybe ("#/." functor)]
+ ["." maybe ("#;." functor)]
["." error (#+ Error)]
[collection
- ["." list ("#/." monoid)]]]
+ ["." list ("#;." monoid)]]]
[type (#+ :share)
abstract]]
[//
["." atom (#+ Atom)]
- ["." promise (#+ Promise) ("#/." functor)]])
+ ["." promise (#+ Promise) ("#;." functor)]])
(type: #export (Channel a)
{#.doc "An asynchronous channel to distribute values."}
@@ -101,8 +101,8 @@
(structure: #export functor (Functor Channel)
(def: (map f)
- (promise/map
- (maybe/map
+ (promise;map
+ (maybe;map
(function (_ [head tail])
[(f head) (map f tail)])))))
@@ -148,7 +148,7 @@
(def: #export (from-promise promise)
(All [a] (-> (Promise a) (Channel a)))
- (promise/map (function (_ value)
+ (promise;map (function (_ value)
(#.Some [value (promise.resolved #.None)]))
promise))
diff --git a/stdlib/source/lux/control/concurrency/stm.lux b/stdlib/source/lux/control/concurrency/stm.lux
index 8b26eb699..6d1fd0d3b 100644
--- a/stdlib/source/lux/control/concurrency/stm.lux
+++ b/stdlib/source/lux/control/concurrency/stm.lux
@@ -15,7 +15,7 @@
[//
["." atom (#+ Atom atom)]
["." promise (#+ Promise Resolver)]
- ["." frp ("#/." functor)]])
+ ["." frp ("#;." functor)]])
(type: #export (Observer a)
(-> a (IO Any)))
diff --git a/stdlib/source/lux/control/exception.lux b/stdlib/source/lux/control/exception.lux
index 9a357d8a1..71cfa3414 100644
--- a/stdlib/source/lux/control/exception.lux
+++ b/stdlib/source/lux/control/exception.lux
@@ -7,9 +7,9 @@
["//" error (#+ Error)]
["." maybe]
["." product]
- ["." text ("#/." monoid)]
+ ["." text ("#;." monoid)]
[collection
- ["." list ("#/." functor fold)]]]
+ ["." list ("#;." functor fold)]]]
["." macro
["." code]
["s" syntax (#+ syntax: Syntax)]
@@ -97,36 +97,36 @@
(macro.with-gensyms [g!descriptor]
(do @
[current-module macro.current-module-name
- #let [descriptor ($_ text/compose "{" current-module "." name "}" text.new-line)
+ #let [descriptor ($_ text;compose "{" current-module "." name "}" text.new-line)
g!self (code.local-identifier name)]]
(wrap (list (` (def: (~+ (csw.export export))
(~ g!self)
(All [(~+ (csw.type-variables t-vars))]
- (..Exception [(~+ (list/map (get@ #cs.input-type) inputs))]))
+ (..Exception [(~+ (list;map (get@ #cs.input-type) inputs))]))
(let [(~ g!descriptor) (~ (code.text descriptor))]
{#..label (~ g!descriptor)
- #..constructor (function ((~ g!self) [(~+ (list/map (get@ #cs.input-binding) inputs))])
- ((~! text/compose) (~ g!descriptor)
+ #..constructor (function ((~ g!self) [(~+ (list;map (get@ #cs.input-binding) inputs))])
+ ((~! text;compose) (~ g!descriptor)
(~ (maybe.default (' "") body))))})))))
)))
(def: #export (report' entries)
(-> (List [Text Text]) Text)
(let [largest-header-size (|> entries
- (list/map (|>> product.left text.size))
- (list/fold n/max 0))]
+ (list;map (|>> product.left text.size))
+ (list;fold n/max 0))]
(|> entries
- (list/map (function (_ [header message])
+ (list;map (function (_ [header message])
(let [padding (|> " "
(list.repeat (n/- (text.size header)
largest-header-size))
(text.join-with ""))]
- ($_ text/compose padding header ": " message text.new-line))))
+ ($_ text;compose padding header ": " message text.new-line))))
(text.join-with ""))))
(syntax: #export (report {entries (p.many (s.tuple (p.and s.any s.any)))})
(wrap (list (` (report' (list (~+ (|> entries
- (list/map (function (_ [header message])
+ (list;map (function (_ [header message])
(` [(~ header) (~ message)])))))))))))
(def: separator
diff --git a/stdlib/source/lux/control/fold.lux b/stdlib/source/lux/control/fold.lux
index d38b151bc..504f41f58 100644
--- a/stdlib/source/lux/control/fold.lux
+++ b/stdlib/source/lux/control/fold.lux
@@ -12,7 +12,7 @@
(def: #export (with-monoid monoid fold value)
(All [F a]
(-> (Monoid a) (Fold F) (F a) a))
- (let [(^open "monoid/.") monoid]
- (fold monoid/compose
- monoid/identity
+ (let [(^open "monoid;.") monoid]
+ (fold monoid;compose
+ monoid;identity
value)))
diff --git a/stdlib/source/lux/control/interval.lux b/stdlib/source/lux/control/interval.lux
index f4faa0ea7..a001e3a44 100644
--- a/stdlib/source/lux/control/interval.lux
+++ b/stdlib/source/lux/control/interval.lux
@@ -136,9 +136,9 @@
(structure: #export equivalence (All [a] (Equivalence (Interval a)))
(def: (= reference sample)
- (let [(^open "_/.") reference]
- (and (_/= _/bottom (:: sample bottom))
- (_/= _/top (:: sample top))))))
+ (let [(^open "_;.") reference]
+ (and (_;= _;bottom (:: sample bottom))
+ (_;= _;top (:: sample top))))))
(def: #export (nested? reference sample)
(All [a] (-> (Interval a) (Interval a) Bit))
diff --git a/stdlib/source/lux/control/monad.lux b/stdlib/source/lux/control/monad.lux
index 67f1fb047..513f55b1e 100644
--- a/stdlib/source/lux/control/monad.lux
+++ b/stdlib/source/lux/control/monad.lux
@@ -3,7 +3,7 @@
[//
["." functor (#+ Functor)]])
-(def: (list/fold f init xs)
+(def: (list;fold f init xs)
(All [a b]
(-> (-> b a a) a (List b) a))
(case xs
@@ -11,9 +11,9 @@
init
(#.Cons x xs')
- (list/fold f (f x init) xs')))
+ (list;fold f (f x init) xs')))
-(def: (list/size xs)
+(def: (list;size xs)
(All [a] (-> (List a) Nat))
(loop [counter 0
xs xs]
@@ -27,7 +27,7 @@
(def: (reverse xs)
(All [a]
(-> (List a) (List a)))
- (list/fold (function (_ head tail) (#.Cons head tail))
+ (list;fold (function (_ head tail) (#.Cons head tail))
#.Nil
xs))
@@ -60,11 +60,11 @@
(wrap (f3 z))))}
(case tokens
(#.Cons monad (#.Cons [_ (#.Tuple bindings)] (#.Cons body #.Nil)))
- (if (|> bindings list/size (n/% 2) (n/= 0))
+ (if (|> bindings list;size (n/% 2) (n/= 0))
(let [g!_ (: Code [_cursor (#.Identifier ["" " _ "])])
g!map (: Code [_cursor (#.Identifier ["" " map "])])
g!join (: Code [_cursor (#.Identifier ["" " join "])])
- body' (list/fold (: (-> [Code Code] Code Code)
+ body' (list;fold (: (-> [Code Code] Code Code)
(function (_ binding body')
(let [[var value] binding]
(case var
@@ -94,55 +94,55 @@
(All [M a]
(-> (Monad M) (List (M a))
(M (List a))))
- (let [(^open "!/.") monad]
+ (let [(^open "!;.") monad]
(function (recur xs)
(case xs
#.Nil
- (!/wrap #.Nil)
+ (!;wrap #.Nil)
(#.Cons x xs')
(|> x
- (!/map (function (_ _x)
- (!/map (|>> (#.Cons _x)) (recur xs'))))
- !/join)))))
+ (!;map (function (_ _x)
+ (!;map (|>> (#.Cons _x)) (recur xs'))))
+ !;join)))))
(def: #export (map monad f)
{#.doc "Apply a monadic function to all values in a list."}
(All [M a b]
(-> (Monad M) (-> a (M b)) (List a)
(M (List b))))
- (let [(^open "!/.") monad]
+ (let [(^open "!;.") monad]
(function (recur xs)
(case xs
#.Nil
- (!/wrap #.Nil)
+ (!;wrap #.Nil)
(#.Cons x xs')
(|> (f x)
- (!/map (function (_ _x)
- (!/map (|>> (#.Cons _x)) (recur xs'))))
- !/join)))))
+ (!;map (function (_ _x)
+ (!;map (|>> (#.Cons _x)) (recur xs'))))
+ !;join)))))
(def: #export (filter Monad<!> f)
{#.doc "Filter the values in a list with a monadic function."}
(All [! a b]
(-> (Monad !) (-> a (! Bit)) (List a)
(! (List a))))
- (let [(^open "!/.") Monad<!>]
+ (let [(^open "!;.") Monad<!>]
(function (recur xs)
(case xs
#.Nil
- (!/wrap #.Nil)
+ (!;wrap #.Nil)
(#.Cons head xs')
(|> (f head)
- (!/map (function (_ verdict)
- (!/map (function (_ tail)
+ (!;map (function (_ verdict)
+ (!;map (function (_ tail)
(if verdict
(#.Cons head tail)
tail))
(recur xs'))))
- !/join)))))
+ !;join)))))
(def: #export (fold monad f init xs)
{#.doc "Fold a list with a monadic function."}
diff --git a/stdlib/source/lux/control/monad/indexed.lux b/stdlib/source/lux/control/monad/indexed.lux
index d5ce955a0..57a18c109 100644
--- a/stdlib/source/lux/control/monad/indexed.lux
+++ b/stdlib/source/lux/control/monad/indexed.lux
@@ -5,7 +5,7 @@
["p" parser]]
[data
[collection
- ["." list ("#/." functor fold)]]]
+ ["." list ("#;." functor fold)]]]
["." macro
["s" syntax (#+ Syntax syntax:)]]])
@@ -47,11 +47,11 @@
(wrap (list (` (let [(~' @) (~ monad)
{#..wrap (~' wrap)
#..bind (~ g!bind)} (~' @)]
- (~ (list/fold (function (_ context next)
+ (~ (list;fold (function (_ context next)
(case context
(#Let bindings)
(` (let [(~+ (|> bindings
- (list/map pair-list)
+ (list;map pair-list)
list.concat))]
(~ next)))
diff --git a/stdlib/source/lux/control/parser.lux b/stdlib/source/lux/control/parser.lux
index 2a724d596..035576cab 100644
--- a/stdlib/source/lux/control/parser.lux
+++ b/stdlib/source/lux/control/parser.lux
@@ -7,7 +7,7 @@
[codec (#+ Codec)]]
[data
[collection
- ["." list ("#/." functor monoid)]]
+ ["." list ("#;." functor monoid)]]
["." product]
["." error (#+ Error)]]])
@@ -162,7 +162,7 @@
(do ..monad
[min (exactly n p)
extra (some p)]
- (wrap (list/compose min extra))))
+ (wrap (list;compose min extra))))
(def: #export (at-most n p)
{#.doc "Parse at most N times."}
@@ -201,7 +201,7 @@
(#.Some x)
(do @
[xs' (some (..and sep p))]
- (wrap (#.Cons x (list/map product.right xs'))))
+ (wrap (#.Cons x (list;map product.right xs'))))
)))
(def: #export (not p)
diff --git a/stdlib/source/lux/control/pipe.lux b/stdlib/source/lux/control/pipe.lux
index 8e8209b89..8700217e2 100644
--- a/stdlib/source/lux/control/pipe.lux
+++ b/stdlib/source/lux/control/pipe.lux
@@ -6,7 +6,7 @@
[data
["e" error]
[collection
- ["." list ("#/." fold monad)]]]
+ ["." list ("#;." fold monad)]]]
[macro (#+ with-gensyms)
["s" syntax (#+ syntax: Syntax)]
["." code]]])
@@ -129,7 +129,7 @@
"Will become: [+50 +2 '+5']")}
(with-gensyms [g!temp]
(wrap (list (` (let [(~ g!temp) (~ prev)]
- [(~+ (list/map (function (_ body) (` (|> (~ g!temp) (~+ body))))
+ [(~+ (list;map (function (_ body) (` (|> (~ g!temp) (~+ body))))
paths))]))))))
(syntax: #export (case> {branches (p.many (p.and s.any s.any))}
@@ -149,5 +149,5 @@
+9 "nine"
_ "???")))}
(wrap (list (` (case (~ prev)
- (~+ (list/join (list/map (function (_ [pattern body]) (list pattern body))
+ (~+ (list;join (list;map (function (_ [pattern body]) (list pattern body))
branches))))))))
diff --git a/stdlib/source/lux/control/region.lux b/stdlib/source/lux/control/region.lux
index 8e12c7675..596b1a0d4 100644
--- a/stdlib/source/lux/control/region.lux
+++ b/stdlib/source/lux/control/region.lux
@@ -10,7 +10,7 @@
["." text
format]
[collection
- ["." list ("#/." fold)]]]])
+ ["." list ("#;." fold)]]]])
(type: (Cleaner r m)
(-> r (m (Error Any))))
@@ -56,7 +56,7 @@
[[cleaners output] (computation [[] (list)])
results (monad.map @ (function (_ cleaner) (cleaner []))
cleaners)]
- (wrap (list/fold combine-outcomes output results))))
+ (wrap (list;fold combine-outcomes output results))))
(def: #export (acquire Monad<m> cleaner value)
(All [m a] (-> (Monad m) (-> a (m (Error Any))) a
diff --git a/stdlib/source/lux/control/remember.lux b/stdlib/source/lux/control/remember.lux
index f497677cf..6bd64a798 100644
--- a/stdlib/source/lux/control/remember.lux
+++ b/stdlib/source/lux/control/remember.lux
@@ -2,7 +2,7 @@
[lux #*
[control
[monad (#+ do)]
- ["p" parser ("#/." functor)]
+ ["p" parser ("#;." functor)]
["ex" exception (#+ exception:)]]
[data
["." error]
@@ -10,7 +10,7 @@
format]]
[time
["." instant]
- ["." date (#+ Date) ("#/." order codec)]]
+ ["." date (#+ Date) ("#;." order codec)]]
["." macro
["." code]
["s" syntax (#+ Syntax syntax:)]]
@@ -28,7 +28,7 @@
(def: deadline
(Syntax Date)
($_ p.either
- (p/map (|>> instant.from-millis instant.date)
+ (p;map (|>> instant.from-millis instant.date)
s.int)
(do p.monad
[raw s.text]
diff --git a/stdlib/source/lux/control/security/capability.lux b/stdlib/source/lux/control/security/capability.lux
index 7e0dd5a6d..595c573d5 100644
--- a/stdlib/source/lux/control/security/capability.lux
+++ b/stdlib/source/lux/control/security/capability.lux
@@ -10,7 +10,7 @@
[text
format]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
[type
abstract]
["." macro
@@ -54,7 +54,7 @@
(~ capability)))
(` (def: (~+ (writer.export export))
(~ (code.local-identifier forge))
- (All [(~+ (list/map code.local-identifier vars))]
+ (All [(~+ (list;map code.local-identifier vars))]
(-> (-> (~ input) (~ output))
(~ capability)))
(~! ..forge)))
diff --git a/stdlib/source/lux/data/collection/array.lux b/stdlib/source/lux/data/collection/array.lux
index 0871e1a86..8677ceb62 100644
--- a/stdlib/source/lux/data/collection/array.lux
+++ b/stdlib/source/lux/data/collection/array.lux
@@ -10,7 +10,7 @@
["." product]
["." maybe]
[collection
- ["." list ("#/." fold)]]]
+ ["." list ("#;." fold)]]]
[tool
[compiler
["." host]]]])
@@ -89,7 +89,7 @@
(Array a)))
(if (n/= 0 length)
dest-array
- (list/fold (function (_ offset target)
+ (list;fold (function (_ offset target)
(case (read (n/+ offset src-start) src-array)
#.None
target
@@ -102,7 +102,7 @@
(def: #export (occupied array)
{#.doc "Finds out how many cells in an array are occupied."}
(All [a] (-> (Array a) Nat))
- (list/fold (function (_ idx count)
+ (list;fold (function (_ idx count)
(case (read idx array)
#.None
count
@@ -120,7 +120,7 @@
(def: #export (filter! p xs)
(All [a]
(-> (-> a Bit) (Array a) (Array a)))
- (list/fold (function (_ idx xs')
+ (list;fold (function (_ idx xs')
(case (read idx xs)
#.None
xs'
@@ -168,7 +168,7 @@
(def: #export (clone xs)
(All [a] (-> (Array a) (Array a)))
(let [arr-size (size xs)]
- (list/fold (function (_ idx ys)
+ (list;fold (function (_ idx ys)
(case (read idx xs)
#.None
ys
@@ -180,7 +180,7 @@
(def: #export (from-list xs)
(All [a] (-> (List a) (Array a)))
- (product.right (list/fold (function (_ x [idx arr])
+ (product.right (list;fold (function (_ x [idx arr])
[(inc idx) (write idx x arr)])
[0 (new (list.size xs))]
xs)))
@@ -217,7 +217,7 @@
(let [sxs (size xs)
sxy (size ys)]
(and (n/= sxy sxs)
- (list/fold (function (_ idx prev)
+ (list;fold (function (_ idx prev)
(and prev
(case [(read idx xs) (read idx ys)]
[#.None #.None]
@@ -246,7 +246,7 @@
(let [arr-size (size ma)]
(if (n/= 0 arr-size)
(new arr-size)
- (list/fold (function (_ idx mb)
+ (list;fold (function (_ idx mb)
(case (read idx ma)
#.None
mb
diff --git a/stdlib/source/lux/data/collection/bits.lux b/stdlib/source/lux/data/collection/bits.lux
index 47af962d6..975605fdc 100644
--- a/stdlib/source/lux/data/collection/bits.lux
+++ b/stdlib/source/lux/data/collection/bits.lux
@@ -10,7 +10,7 @@
[text
format]
[collection
- ["." array (#+ Array) ("#/." fold)]]]])
+ ["." array (#+ Array) ("#;." fold)]]]])
(type: #export Chunk I64)
@@ -27,7 +27,7 @@
(def: #export (size bits)
(-> Bits Nat)
- (array/fold (function (_ chunk total)
+ (array;fold (function (_ chunk total)
(|> chunk i64.count (n/+ total)))
0
bits))
diff --git a/stdlib/source/lux/data/collection/dictionary.lux b/stdlib/source/lux/data/collection/dictionary.lux
index 3a670642c..a1f16311d 100644
--- a/stdlib/source/lux/data/collection/dictionary.lux
+++ b/stdlib/source/lux/data/collection/dictionary.lux
@@ -9,8 +9,8 @@
["." number
["." i64]]
[collection
- ["." list ("#/." fold functor monoid)]
- ["." array (#+ Array) ("#/." functor fold)]]]
+ ["." list ("#;." fold functor monoid)]
+ ["." array (#+ Array) ("#;." functor fold)]]]
])
## This implementation of Hash Array Mapped Trie (HAMT) is based on
@@ -219,7 +219,7 @@
## nodes to save space.
(def: (demote-hierarchy except-idx [h-size h-array])
(All [k v] (-> Index (Hierarchy k v) [BitMap (Base k v)]))
- (product.right (list/fold (function (_ idx [insertion-idx node])
+ (product.right (list;fold (function (_ idx [insertion-idx node])
(let [[bitmap base] node]
(case (array.read idx h-array)
#.None [insertion-idx node]
@@ -243,7 +243,7 @@
(Hash k) Level
BitMap (Base k v)
(Array (Node k v))))
- (product.right (list/fold (function (_ hierarchy-idx (^@ default [base-idx h-array]))
+ (product.right (list;fold (function (_ hierarchy-idx (^@ default [base-idx h-array]))
(if (bit-position-is-set? (->bit-position hierarchy-idx)
bitmap)
[(inc base-idx)
@@ -500,10 +500,10 @@
(All [k v] (-> (Node k v) Nat))
(case node
(#Hierarchy _size hierarchy)
- (array/fold n/+ 0 (array/map size' hierarchy))
+ (array;fold n/+ 0 (array;map size' hierarchy))
(#Base _ base)
- (array/fold n/+ 0 (array/map (function (_ sub-node')
+ (array;fold n/+ 0 (array;map (function (_ sub-node')
(case sub-node'
(#.Left sub-node) (size' sub-node)
(#.Right _) 1))
@@ -517,15 +517,15 @@
(All [k v] (-> (Node k v) (List [k v])))
(case node
(#Hierarchy _size hierarchy)
- (array/fold (function (_ sub-node tail) (list/compose (entries' sub-node) tail))
+ (array;fold (function (_ sub-node tail) (list;compose (entries' sub-node) tail))
#.Nil
hierarchy)
(#Base bitmap base)
- (array/fold (function (_ branch tail)
+ (array;fold (function (_ branch tail)
(case branch
(#.Left sub-node)
- (list/compose (entries' sub-node) tail)
+ (list;compose (entries' sub-node) tail)
(#.Right [key' val'])
(#.Cons [key' val'] tail)))
@@ -533,7 +533,7 @@
base)
(#Collisions hash colls)
- (array/fold (function (_ [key' val'] tail) (#.Cons [key' val'] tail))
+ (array;fold (function (_ [key' val'] tail) (#.Cons [key' val'] tail))
#.Nil
colls)))
@@ -609,7 +609,7 @@
(def: #export (from-list Hash<k> kvs)
(All [k v] (-> (Hash k) (List [k v]) (Dictionary k v)))
- (list/fold (function (_ [k v] dict)
+ (list;fold (function (_ [k v] dict)
(put k v dict))
(new Hash<k>)
kvs))
@@ -617,7 +617,7 @@
(do-template [<name> <elem-type> <side>]
[(def: #export (<name> dict)
(All [k v] (-> (Dictionary k v) (List <elem-type>)))
- (|> dict entries (list/map <side>)))]
+ (|> dict entries (list;map <side>)))]
[keys k product.left]
[values v product.right]
@@ -627,7 +627,7 @@
{#.doc (doc "Merges 2 dictionaries."
"If any collisions with keys occur, the values of dict2 will overwrite those of dict1.")}
(All [k v] (-> (Dictionary k v) (Dictionary k v) (Dictionary k v)))
- (list/fold (function (_ [key val] dict) (put key val dict))
+ (list;fold (function (_ [key val] dict) (put key val dict))
dict1
(entries dict2)))
@@ -635,7 +635,7 @@
{#.doc (doc "Merges 2 dictionaries."
"If any collisions with keys occur, a new value will be computed by applying 'f' to the values of dict2 and dict1.")}
(All [k v] (-> (-> v v v) (Dictionary k v) (Dictionary k v) (Dictionary k v)))
- (list/fold (function (_ [key val2] dict)
+ (list;fold (function (_ [key val2] dict)
(case (get key dict)
#.None
(put key val2 dict)
@@ -660,7 +660,7 @@
{#.doc "Creates a sub-set of the given dict, with only the specified keys."}
(All [k v] (-> (List k) (Dictionary k v) (Dictionary k v)))
(let [[Hash<k> _] dict]
- (list/fold (function (_ key new-dict)
+ (list;fold (function (_ key new-dict)
(case (get key dict)
#.None new-dict
(#.Some val) (put key val new-dict)))
diff --git a/stdlib/source/lux/data/collection/dictionary/ordered.lux b/stdlib/source/lux/data/collection/dictionary/ordered.lux
index 956f4a1b6..8b384ca4c 100644
--- a/stdlib/source/lux/data/collection/dictionary/ordered.lux
+++ b/stdlib/source/lux/data/collection/dictionary/ordered.lux
@@ -8,7 +8,7 @@
["p" product]
["." maybe]
[collection
- ["." list ("#/." monoid fold)]]]
+ ["." list ("#;." monoid fold)]]]
["." macro
["." code]
["s" syntax (#+ syntax: Syntax)]]])
@@ -530,7 +530,7 @@
(def: #export (from-list Order<l> list)
(All [k v] (-> (Order k) (List [k v]) (Dictionary k v)))
- (list/fold (function (_ [key value] dict)
+ (list;fold (function (_ [key value] dict)
(put key value dict))
(new Order<l>)
list))
@@ -544,7 +544,7 @@
(list)
(#.Some node')
- ($_ list/compose
+ ($_ list;compose
(recur (get@ #left node'))
(list <output>)
(recur (get@ #right node'))))))]
diff --git a/stdlib/source/lux/data/collection/dictionary/plist.lux b/stdlib/source/lux/data/collection/dictionary/plist.lux
index 9bc43bb9f..269c8bd02 100644
--- a/stdlib/source/lux/data/collection/dictionary/plist.lux
+++ b/stdlib/source/lux/data/collection/dictionary/plist.lux
@@ -2,9 +2,9 @@
[lux #*
[data
["." product]
- ["." text ("#/." equivalence)]
+ ["." text ("#;." equivalence)]
[collection
- ["." list ("#/." functor)]]]])
+ ["." list ("#;." functor)]]]])
(type: #export (PList a)
(List [Text a]))
@@ -16,14 +16,14 @@
#.None
(#.Cons [k' v'] properties')
- (if (text/= key k')
+ (if (text;= key k')
(#.Some v')
(get key properties'))))
(do-template [<name> <type> <access>]
[(def: #export <name>
(All [a] (-> (PList a) (List <type>)))
- (list/map <access>))]
+ (list;map <access>))]
[keys Text product.left]
[values a product.right]
@@ -45,7 +45,7 @@
(list [key val])
(#.Cons [k' v'] properties')
- (if (text/= key k')
+ (if (text;= key k')
(#.Cons [key val]
properties')
(#.Cons [k' v']
@@ -58,7 +58,7 @@
#.Nil
(#.Cons [k' v'] properties')
- (if (text/= key k')
+ (if (text;= key k')
(#.Cons [k' (f v')] properties')
(#.Cons [k' v'] (update key f properties')))))
@@ -69,7 +69,7 @@
properties
(#.Cons [k' v'] properties')
- (if (text/= key k')
+ (if (text;= key k')
properties'
(#.Cons [k' v']
(remove key properties')))))
diff --git a/stdlib/source/lux/data/collection/list.lux b/stdlib/source/lux/data/collection/list.lux
index a6b12b670..46d47e398 100644
--- a/stdlib/source/lux/data/collection/list.lux
+++ b/stdlib/source/lux/data/collection/list.lux
@@ -391,7 +391,7 @@
(-> Text Code)
[["" 0 0] (#.Identifier "" name)])
-(def: (nat/encode value)
+(def: (nat;encode value)
(-> Nat Text)
(loop [input value
output ""]
@@ -423,7 +423,7 @@
(if (n/> 0 num-lists)
(let [(^open ".") ..functor
indices (..indices num-lists)
- type-vars (: (List Code) (map (|>> nat/encode identifier$) indices))
+ type-vars (: (List Code) (map (|>> nat;encode identifier$) indices))
zip-type (` (All [(~+ type-vars)]
(-> (~+ (map (: (-> Code Code) (function (_ var) (` (List (~ var)))))
type-vars))
@@ -431,7 +431,7 @@
vars+lists (|> indices
(map inc)
(map (function (_ idx)
- (let [base (nat/encode idx)]
+ (let [base (nat;encode idx)]
[(identifier$ base)
(identifier$ ("lux text concat" base "'"))]))))
pattern (` [(~+ (map (function (_ [v vs]) (` (#.Cons (~ v) (~ vs))))
@@ -469,7 +469,7 @@
indices (..indices num-lists)
g!return-type (identifier$ "0return-type0")
g!func (identifier$ "0func0")
- type-vars (: (List Code) (map (|>> nat/encode identifier$) indices))
+ type-vars (: (List Code) (map (|>> nat;encode identifier$) indices))
zip-type (` (All [(~+ type-vars) (~ g!return-type)]
(-> (-> (~+ type-vars) (~ g!return-type))
(~+ (map (: (-> Code Code) (function (_ var) (` (List (~ var)))))
@@ -478,7 +478,7 @@
vars+lists (|> indices
(map inc)
(map (function (_ idx)
- (let [base (nat/encode idx)]
+ (let [base (nat;encode idx)]
[(identifier$ base)
(identifier$ ("lux text concat" base "'"))]))))
pattern (` [(~+ (map (function (_ [v vs]) (` (#.Cons (~ v) (~ vs))))
diff --git a/stdlib/source/lux/data/collection/queue.lux b/stdlib/source/lux/data/collection/queue.lux
index c5644e7bf..699440648 100644
--- a/stdlib/source/lux/data/collection/queue.lux
+++ b/stdlib/source/lux/data/collection/queue.lux
@@ -5,7 +5,7 @@
[functor (#+ Functor)]]
[data
[collection
- ["." list ("#/." monoid functor)]]]])
+ ["." list ("#;." monoid functor)]]]])
(type: #export (Queue a)
{#front (List a)
@@ -24,7 +24,7 @@
(def: #export (to-list queue)
(All [a] (-> (Queue a) (List a)))
(let [(^slots [#front #rear]) queue]
- (list/compose front (list.reverse rear))))
+ (list;compose front (list.reverse rear))))
(def: #export peek
(All [a] (-> (Queue a) (Maybe a)))
@@ -77,5 +77,5 @@
(structure: #export functor (Functor Queue)
(def: (map f fa)
- {#front (|> fa (get@ #front) (list/map f))
- #rear (|> fa (get@ #rear) (list/map f))}))
+ {#front (|> fa (get@ #front) (list;map f))
+ #rear (|> fa (get@ #rear) (list;map f))}))
diff --git a/stdlib/source/lux/data/collection/queue/priority.lux b/stdlib/source/lux/data/collection/queue/priority.lux
index 5f882c170..1e7d40022 100644
--- a/stdlib/source/lux/data/collection/queue/priority.lux
+++ b/stdlib/source/lux/data/collection/queue/priority.lux
@@ -6,7 +6,7 @@
[data
["." maybe]
[number
- ["." nat ("#/." interval)]]
+ ["." nat ("#;." interval)]]
[collection
[tree
["." finger (#+ Tree)]]]]])
@@ -16,8 +16,8 @@
(type: #export (Queue a)
(Maybe (Tree Priority a)))
-(def: #export max Priority nat/top)
-(def: #export min Priority nat/bottom)
+(def: #export max Priority nat;top)
+(def: #export min Priority nat;bottom)
(def: #export empty
Queue
diff --git a/stdlib/source/lux/data/collection/row.lux b/stdlib/source/lux/data/collection/row.lux
index 1e74054e5..dff272a91 100644
--- a/stdlib/source/lux/data/collection/row.lux
+++ b/stdlib/source/lux/data/collection/row.lux
@@ -15,8 +15,8 @@
[number
["." i64]]
[collection
- ["." list ("#/." fold functor monoid)]
- ["." array (#+ Array) ("#/." functor fold)]]]
+ ["." list ("#;." fold functor monoid)]
+ ["." array (#+ Array) ("#;." functor fold)]]]
[macro (#+ with-gensyms)
["." code]
["s" syntax (#+ syntax: Syntax)]]])
@@ -169,7 +169,7 @@
(|> hierarchy
array.to-list
list.reverse
- (list/fold (function (_ sub acc) (list/compose (to-list' sub) acc))
+ (list;fold (function (_ sub acc) (list;compose (to-list' sub) acc))
#.Nil))))
## [Types]
@@ -323,12 +323,12 @@
(def: #export (to-list vec)
(All [a] (-> (Row a) (List a)))
- (list/compose (to-list' (#Hierarchy (get@ #root vec)))
+ (list;compose (to-list' (#Hierarchy (get@ #root vec)))
(to-list' (#Base (get@ #tail vec)))))
(def: #export from-list
(All [a] (-> (List a) (Row a)))
- (list/fold ..add ..empty))
+ (list;fold ..add ..empty))
(def: #export (member? a/Equivalence vec val)
(All [a] (-> (Equivalence a) (Row a) a Bit))
@@ -370,10 +370,10 @@
(def: (fold f init xs)
(case xs
(#Base base)
- (array/fold f init base)
+ (array;fold f init base)
(#Hierarchy hierarchy)
- (array/fold (function (_ node init') (fold f init' node))
+ (array;fold (function (_ node init') (fold f init' node))
init
hierarchy))))
@@ -390,23 +390,23 @@
(def: identity ..empty)
(def: (compose xs ys)
- (list/fold add xs (..to-list ys))))
+ (list;fold add xs (..to-list ys))))
(structure: node-functor (Functor Node)
(def: (map f xs)
(case xs
(#Base base)
- (#Base (array/map f base))
+ (#Base (array;map f base))
(#Hierarchy hierarchy)
- (#Hierarchy (array/map (map f) hierarchy)))))
+ (#Hierarchy (array;map (map f) hierarchy)))))
(structure: #export functor (Functor Row)
(def: (map f xs)
{#level (get@ #level xs)
#size (get@ #size xs)
- #root (|> xs (get@ #root) (array/map (:: node-functor map f)))
- #tail (|> xs (get@ #tail) (array/map f))}))
+ #root (|> xs (get@ #root) (array;map (:: node-functor map f)))
+ #tail (|> xs (get@ #tail) (array;map f))}))
(structure: #export apply (Apply Row)
(def: &functor ..functor)
diff --git a/stdlib/source/lux/data/collection/sequence.lux b/stdlib/source/lux/data/collection/sequence.lux
index 9cb65d0f4..bff7b621e 100644
--- a/stdlib/source/lux/data/collection/sequence.lux
+++ b/stdlib/source/lux/data/collection/sequence.lux
@@ -11,7 +11,7 @@
[data
["." bit]
[collection
- ["." list ("#/." monad)]]]])
+ ["." list ("#;." monad)]]]])
(type: #export (Sequence a)
{#.doc "An infinite sequence of values."}
@@ -138,7 +138,7 @@
(let [(^sequence& x y z _tail) (some-sequence-func +1 +2 +3)]
(func x y z)))}
(with-gensyms [g!sequence]
- (let [body+ (` (let [(~+ (list/join (list/map (function (_ pattern)
+ (let [body+ (` (let [(~+ (list;join (list;map (function (_ pattern)
(list (` [(~ pattern) (~ g!sequence)])
(` ((~! continuation.run) (~ g!sequence)))))
patterns)))]
diff --git a/stdlib/source/lux/data/collection/set.lux b/stdlib/source/lux/data/collection/set.lux
index 7b3e803a3..0a195f4eb 100644
--- a/stdlib/source/lux/data/collection/set.lux
+++ b/stdlib/source/lux/data/collection/set.lux
@@ -7,7 +7,7 @@
[data
[collection
["dict" dictionary (#+ Dictionary)]
- ["." list ("#/." fold)]]]
+ ["." list ("#;." fold)]]]
[type
abstract]])
@@ -46,7 +46,7 @@
(def: #export (difference sub base)
(All [a] (-> (Set a) (Set a) (Set a)))
- (list/fold ..remove base (..to-list sub)))
+ (list;fold ..remove base (..to-list sub)))
(def: #export (intersection filter base)
(All [a] (-> (Set a) (Set a) (Set a)))
@@ -64,7 +64,7 @@
(def: (hash set)
(let [[hash _] (:representation set)]
- (list/fold (function (_ elem acc) (n/+ (:: hash hash elem) acc))
+ (list;fold (function (_ elem acc) (n/+ (:: hash hash elem) acc))
0
(..to-list set)))))
)
@@ -75,7 +75,7 @@
(def: #export (from-list hash elements)
(All [a] (-> (Hash a) (List a) (Set a)))
- (list/fold ..add (..new hash) elements))
+ (list;fold ..add (..new hash) elements))
(def: #export (sub? super sub)
(All [a] (-> (Set a) (Set a) Bit))
diff --git a/stdlib/source/lux/data/collection/set/multi.lux b/stdlib/source/lux/data/collection/set/multi.lux
index e509d41cf..012224e31 100644
--- a/stdlib/source/lux/data/collection/set/multi.lux
+++ b/stdlib/source/lux/data/collection/set/multi.lux
@@ -10,7 +10,7 @@
[////
["." maybe]]
[///
- ["." list ("#/." fold)]
+ ["." list ("#;." fold)]
["." dictionary (#+ Dictionary)]]
["." //])
@@ -25,7 +25,7 @@
(def: #export size
(All [a] (-> (Set a) Nat))
- (|>> :representation dictionary.values (list/fold n/+ 0)))
+ (|>> :representation dictionary.values (list;fold n/+ 0)))
(def: #export (add/* count elem set)
(All [a] (-> Nat a (Set a) (Set a)))
@@ -68,7 +68,7 @@
_ (|> output (#.Cons elem) (append elem (dec count))))))]
(|>> :representation
dictionary.entries
- (list/fold (function (_ [elem count] output)
+ (list;fold (function (_ [elem count] output)
(append elem count output))
#.Nil))))
@@ -81,7 +81,7 @@
(|> parameter
:representation
dictionary.entries
- (list/fold (function (_ [elem count] output)
+ (list;fold (function (_ [elem count] output)
(remove/* count elem output))
subject)))
@@ -90,7 +90,7 @@
(|> parameter
:representation
dictionary.entries
- (list/fold (function (_ [elem count] (^:representation output))
+ (list;fold (function (_ [elem count] (^:representation output))
(:abstraction (if (dictionary.contains? elem output)
(dictionary.update elem (n/min count) output)
output)))
@@ -132,7 +132,7 @@
(def: (hash (^:representation set))
(let [[Hash<a> _] set]
- (list/fold (function (_ [elem count] acc)
+ (list;fold (function (_ [elem count] acc)
(|> elem (:: Hash<a> hash) (n/* count) (n/+ acc)))
0
(dictionary.entries set)))))
@@ -148,7 +148,7 @@
(def: #export (from-list Hash<a> subject)
(All [a] (-> (Hash a) (List a) (Set a)))
- (list/fold ..add/1 (..new Hash<a>) subject))
+ (list;fold ..add/1 (..new Hash<a>) subject))
(def: #export super?
(All [a] (-> (Set a) (Set a) Bit))
diff --git a/stdlib/source/lux/data/collection/set/ordered.lux b/stdlib/source/lux/data/collection/set/ordered.lux
index a3aef2c24..32702ed7f 100644
--- a/stdlib/source/lux/data/collection/set/ordered.lux
+++ b/stdlib/source/lux/data/collection/set/ordered.lux
@@ -5,7 +5,7 @@
[order (#+ Order)]]
[data
[collection
- ["." list ("#/." fold)]
+ ["." list ("#;." fold)]
[dictionary
["/" ordered]]]]
[type
@@ -56,11 +56,11 @@
(def: #export (from-list Order<a> list)
(All [a] (-> (Order a) (List a) (Set a)))
- (list/fold add (new Order<a>) list))
+ (list;fold add (new Order<a>) list))
(def: #export (union left right)
(All [a] (-> (Set a) (Set a) (Set a)))
- (list/fold ..add right (..to-list left)))
+ (list;fold ..add right (..to-list left)))
(def: #export (intersection left right)
(All [a] (-> (Set a) (Set a) (Set a)))
diff --git a/stdlib/source/lux/data/collection/tree/finger.lux b/stdlib/source/lux/data/collection/tree/finger.lux
index 84859dca5..e3aed3b0d 100644
--- a/stdlib/source/lux/data/collection/tree/finger.lux
+++ b/stdlib/source/lux/data/collection/tree/finger.lux
@@ -40,7 +40,7 @@
(def: #export (search pred tree)
(All [m a] (-> (-> m Bit) (Tree m a) (Maybe a)))
- (let [tag/compose (get@ [#monoid #m.compose] tree)]
+ (let [tag;compose (get@ [#monoid #m.compose] tree)]
(if (pred (tag tree))
(loop [_tag (get@ [#monoid #m.identity] tree)
_node (get@ #node tree)]
@@ -49,7 +49,7 @@
(#.Some value)
(#Branch _ left right)
- (let [shifted-tag (tag/compose _tag (tag (set@ #node left tree)))]
+ (let [shifted-tag (tag;compose _tag (tag (set@ #node left tree)))]
(if (pred shifted-tag)
(recur _tag left)
(recur shifted-tag right)))))
diff --git a/stdlib/source/lux/data/collection/tree/rose.lux b/stdlib/source/lux/data/collection/tree/rose.lux
index ab2c04059..7043c2afd 100644
--- a/stdlib/source/lux/data/collection/tree/rose.lux
+++ b/stdlib/source/lux/data/collection/tree/rose.lux
@@ -8,7 +8,7 @@
fold]
[data
[collection
- ["." list ("#/." monad fold)]]]
+ ["." list ("#;." monad fold)]]]
["." macro
["." code]
["s" syntax (#+ syntax: Syntax)]]])
@@ -22,7 +22,7 @@
(def: #export (flatten tree)
(All [a] (-> (Tree a) (List a)))
(#.Cons (get@ #value tree)
- (list/join (list/map flatten (get@ #children tree)))))
+ (list;join (list;map flatten (get@ #children tree)))))
(def: #export (leaf value)
(All [a] (-> a (Tree a)))
@@ -54,7 +54,7 @@
+40 {}}]))}
(wrap (list (` (~ (loop [[value children] root]
(` {#value (~ value)
- #children (list (~+ (list/map recur children)))})))))))
+ #children (list (~+ (list;map recur children)))})))))))
## [Structs]
(structure: #export (equivalence Equivalence<a>) (All [a] (-> (Equivalence a) (Equivalence (Tree a))))
@@ -65,12 +65,12 @@
(structure: #export functor (Functor Tree)
(def: (map f fa)
{#value (f (get@ #value fa))
- #children (list/map (map f)
+ #children (list;map (map f)
(get@ #children fa))}))
(structure: #export fold (Fold Tree)
(def: (fold f init tree)
- (list/fold (function (_ tree' init') (fold f init' tree'))
+ (list;fold (function (_ tree' init') (fold f init' tree'))
(f (get@ #value tree)
init)
(get@ #children tree))))
diff --git a/stdlib/source/lux/data/collection/tree/rose/zipper.lux b/stdlib/source/lux/data/collection/tree/rose/zipper.lux
index 663090cf2..61de6d585 100644
--- a/stdlib/source/lux/data/collection/tree/rose/zipper.lux
+++ b/stdlib/source/lux/data/collection/tree/rose/zipper.lux
@@ -4,14 +4,14 @@
functor
comonad]
[data
- ["." maybe ("#/." monad)]
+ ["." maybe ("#;." monad)]
[collection
- ["." list ("#/." functor fold monoid)]
+ ["." list ("#;." functor fold monoid)]
["." stack (#+ Stack)]]]
["." macro
["." code]
["s" syntax (#+ Syntax syntax:)]]]
- ["." // (#+ Tree) ("#/." functor)])
+ ["." // (#+ Tree) ("#;." functor)])
## Adapted from the clojure.zip namespace in the Clojure standard library.
@@ -88,12 +88,12 @@
## TODO: Remove once new-luxc becomes the standard compiler.
(update@ #node (: (-> (Tree ($ 0)) (Tree ($ 0)))
(function (_ node)
- (set@ #//.children (list/compose (list.reverse (get@ #lefts zipper))
+ (set@ #//.children (list;compose (list.reverse (get@ #lefts zipper))
(#.Cons (get@ #node zipper)
(get@ #rights zipper)))
node))))
## (update@ #node (function (_ node)
- ## (set@ #//.children (list/compose (list.reverse (get@ #lefts zipper))
+ ## (set@ #//.children (list;compose (list.reverse (get@ #lefts zipper))
## (#.Cons (get@ #node zipper)
## (get@ #rights zipper)))
## node)))
@@ -122,7 +122,7 @@
(def: #export (<all-name> zipper)
(All [a] (-> (Zipper a) (Zipper a)))
- (list/fold (function (_ _) <one-name>) zipper (get@ <side> zipper)))]
+ (list;fold (function (_ _) <one-name>) zipper (get@ <side> zipper)))]
[right rightmost #rights #lefts]
[left leftmost #lefts #rights]
@@ -167,7 +167,7 @@
(All [a] (-> a (Zipper a) (Zipper a)))
(update@ [#node #//.children]
(function (_ children)
- (list/compose children
+ (list;compose children
## TODO: Remove once new-luxc becomes the standard compiler.
(list (: (Tree ($ 0))
(//.tree [value {}])))
@@ -216,10 +216,10 @@
(structure: #export functor (Functor Zipper)
(def: (map f fa)
- {#parent (|> fa (get@ #parent) (maybe/map (map f)))
- #lefts (|> fa (get@ #lefts) (list/map (///map f)))
- #rights (|> fa (get@ #rights) (list/map (///map f)))
- #node (///map f (get@ #node fa))}))
+ {#parent (|> fa (get@ #parent) (maybe;map (map f)))
+ #lefts (|> fa (get@ #lefts) (list;map (//;map f)))
+ #rights (|> fa (get@ #rights) (list;map (//;map f)))
+ #node (//;map f (get@ #node fa))}))
## TODO: Add again once new-luxc becomes the standard compiler.
## (structure: #export comonad (CoMonad Zipper)
@@ -230,9 +230,9 @@
## (def: (split wa)
## (let [tree-splitter (function (tree-splitter tree)
## {#//.value (zip tree)
-## #//.children (list/map tree-splitter
+## #//.children (list;map tree-splitter
## (get@ #//.children tree))})]
-## {#parent (|> wa (get@ #parent) (maybe/map split))
-## #lefts (|> wa (get@ #lefts) (list/map tree-splitter))
-## #rights (|> wa (get@ #rights) (list/map tree-splitter))
+## {#parent (|> wa (get@ #parent) (maybe;map split))
+## #lefts (|> wa (get@ #lefts) (list;map tree-splitter))
+## #rights (|> wa (get@ #rights) (list;map tree-splitter))
## #node (|> fa (get@ #node) tree-splitter)})))
diff --git a/stdlib/source/lux/data/color.lux b/stdlib/source/lux/data/color.lux
index 6fae765ca..7ca1764aa 100644
--- a/stdlib/source/lux/data/color.lux
+++ b/stdlib/source/lux/data/color.lux
@@ -4,9 +4,9 @@
[equivalence (#+ Equivalence)]]
[data
[number
- ["." rev ("#/." interval)]]
+ ["." rev ("#;." interval)]]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
["." math]
[type
abstract]])
@@ -334,7 +334,7 @@
(list)
(let [[hue saturation luminance] (to-hsl color)
slice (normalize slice)]
- (list/map (function (_ idx)
+ (list;map (function (_ idx)
(from-hsl [(|> idx .int int-to-frac (f/* slice) (f/+ hue) normalize)
saturation
luminance]))
@@ -347,7 +347,7 @@
(let [[hue saturation brightness] (to-hsb color)
slice (|> +1.0 (f// (|> results .int int-to-frac)))]
(|> (list.indices results)
- (list/map (|>> .int int-to-frac
+ (list;map (|>> .int int-to-frac
(f/* slice)
(f/+ brightness)
normalize
@@ -358,7 +358,7 @@
(def: #export transparent
Alpha
- rev/bottom)
+ rev;bottom)
(def: #export translucent
Alpha
@@ -366,7 +366,7 @@
(def: #export opaque
Alpha
- rev/top)
+ rev;top)
(type: #export Pigment
{#color Color
diff --git a/stdlib/source/lux/data/format/binary.lux b/stdlib/source/lux/data/format/binary.lux
index 361748c49..be2e105ee 100644
--- a/stdlib/source/lux/data/format/binary.lux
+++ b/stdlib/source/lux/data/format/binary.lux
@@ -4,7 +4,7 @@
[monoid (#+ Monoid)]
["." fold]
[monad (#+ do Monad)]
- ["." parser (#+ Parser) ("#/." functor)]
+ ["." parser (#+ Parser) ("#;." functor)]
["ex" exception (#+ exception:)]
[equivalence (#+ Equivalence)]]
[data
@@ -17,7 +17,7 @@
[format (#+ %n)]]
[collection
["." list]
- ["." row (#+ Row) ("#/." functor)]]]
+ ["." row (#+ Row) ("#;." functor)]]]
[type (#+ :share)]
[world
["." binary (#+ Binary)]]])
@@ -78,9 +78,9 @@
(-> a' a)
(Format a)
(Format a')))
- (let [(^open "_/.") format]
- {#reader (|> _/reader (parser/map post-read))
- #writer (|>> pre-write _/writer)}))
+ (let [(^open "_;.") format]
+ {#reader (|> _;reader (parser;map post-read))
+ #writer (|>> pre-write _;writer)}))
(def: #export (read format input)
(All [a] (-> (Format a) Binary (Error a)))
@@ -287,13 +287,13 @@
value (if (n/= original-count capped-count)
value
(|> value row.to-list (list.take capped-count) row.from-list))
- (^open "mutation/.") ..monoid
+ (^open "mutation;.") ..monoid
[size mutation] (|> value
- (row/map (get@ #writer valueF))
+ (row;map (get@ #writer valueF))
(:: row.fold fold
(function (_ post pre)
- (mutation/compose pre post))
- mutation/identity))]
+ (mutation;compose pre post))
+ mutation;identity))]
[(n/+ <size> size)
(function (_ offset binary)
(error.assume
diff --git a/stdlib/source/lux/data/format/css.lux b/stdlib/source/lux/data/format/css.lux
index accc59e0e..736a5e6f3 100644
--- a/stdlib/source/lux/data/format/css.lux
+++ b/stdlib/source/lux/data/format/css.lux
@@ -8,7 +8,7 @@
format
["." encoding (#+ Encoding)]]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
[type
abstract]
[world
@@ -59,7 +59,7 @@
["font-style" (|> font (get@ #/font.style) (maybe.default /value.normal-style) /value.value)]
["font-weight" (|> font (get@ #/font.weight) (maybe.default /value.normal-weight) /value.value)]
with-unicode)
- (list/map (function (_ [property value])
+ (list;map (function (_ [property value])
(format property ": " value ";")))
(text.join-with /style.separator)
(text.enclose ["{" "}"])
@@ -87,7 +87,7 @@
(-> (Value Animation) (List Frame) (CSS Special))
(:abstraction (format "@keyframes " (/value.value animation) " {"
(|> frames
- (list/map (function (_ frame)
+ (list;map (function (_ frame)
(format (/value.percentage (get@ #when frame)) " {"
(/style.inline (get@ #what frame))
"}")))
@@ -107,7 +107,7 @@
(|> css
:representation
(text.split-all-with ..css-separator)
- (list/map (|>> (format (/selector.selector (|> selector (combinator (/selector.tag "")))))))
+ (list;map (|>> (format (/selector.selector (|> selector (combinator (/selector.tag "")))))))
(text.join-with ..css-separator)
:abstraction))
diff --git a/stdlib/source/lux/data/format/css/value.lux b/stdlib/source/lux/data/format/css/value.lux
index a681bde1a..8967ed90a 100644
--- a/stdlib/source/lux/data/format/css/value.lux
+++ b/stdlib/source/lux/data/format/css/value.lux
@@ -9,7 +9,7 @@
["." text
format]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
[type
abstract]
[macro
@@ -797,7 +797,7 @@
(def: #export (cubic-bezier p0 p1 p2 p3)
(-> Frac Frac Frac Frac (Value Timing))
(|> (list p0 p1 p2 p3)
- (list/map %number)
+ (list;map %number)
(..apply "cubic-bezier")))
(do-template [<name> <brand>]
@@ -963,7 +963,7 @@
(let [[now after] next]
(..apply <function> (list& (:representation Angle angle)
(with-hint now)
- (list/map with-hint after)))))]
+ (list;map with-hint after)))))]
[linear-gradient "linear-gradient"]
[repeating-linear-gradient "repeating-linear-gradient"]
@@ -1090,7 +1090,7 @@
[now after] next]
(..apply <function> (list& (..shape shape)
(with-hint now)
- (list/map with-hint after)))))]
+ (list;map with-hint after)))))]
[radial-gradient "radial-gradient"]
[repeating-radial-gradient "repeating-radial-gradient"]
@@ -1162,7 +1162,7 @@
(case options
(#.Cons _)
(|> options
- (list/map ..font-name)
+ (list;map ..font-name)
(text.join-with ",")
(:abstraction Value))
@@ -1201,7 +1201,7 @@
(-> (List (List (Maybe (Value Grid)))) (Value Grid-Template))
(let [empty (: (Value Grid)
(:abstraction "."))]
- (|>> (list/map (|>> (list/map (|>> (maybe.default empty)
+ (|>> (list;map (|>> (list;map (|>> (maybe.default empty)
:representation))
(text.join-with ..grid-column-separator)
(text.enclose ["'" "'"])))
@@ -1238,7 +1238,7 @@
(def: #export (quotes [left0 right0] [left1 right1])
(-> [Quote Quote] [Quote Quote] (Value Quotes))
(|> (list left0 right0 left1 right1)
- (list/map (|>> ..quote-text %t))
+ (list;map (|>> ..quote-text %t))
(text.join-with ..quote-separator)
:abstraction))
@@ -1248,7 +1248,7 @@
[Frac Frac]
(Value Transform))
(|> (list a b c d tx ty)
- (list/map %number)
+ (list;map %number)
(..apply "matrix")))
(def: #export (matrix-3d [a0 b0 c0 d0] [a1 b1 c1 d1] [a2 b2 c2 d2] [a3 b3 c3 d3])
@@ -1258,14 +1258,14 @@
[Frac Frac Frac Frac]
(Value Transform))
(|> (list a0 b0 c0 d0 a1 b1 c1 d1 a2 b2 c2 d2 a3 b3 c3 d3)
- (list/map %number)
+ (list;map %number)
(..apply "matrix3d")))
(do-template [<name> <function> <input-types> <input-values>]
[(`` (def: #export (<name> [(~~ (template.splice <input-values>))])
(-> [(~~ (template.splice <input-types>))] (Value Transform))
(|> (list (~~ (template.splice <input-values>)))
- (list/map %number)
+ (list;map %number)
(..apply <function>))))]
[translate-2d "translate" [Frac Frac] [x y]]
@@ -1287,7 +1287,7 @@
[(`` (def: #export (<name> [(~~ (template.splice <input-values>))])
(-> [(~~ (template.splice <input-types>))] (Value Transform))
(|> (list (~~ (template.splice <input-values>)))
- (list/map ..angle)
+ (list;map ..angle)
(..apply <function>))))]
[rotate-2d "rotate" [Angle] [angle]]
diff --git a/stdlib/source/lux/data/format/html.lux b/stdlib/source/lux/data/format/html.lux
index a8766b651..0cf59690c 100644
--- a/stdlib/source/lux/data/format/html.lux
+++ b/stdlib/source/lux/data/format/html.lux
@@ -6,7 +6,7 @@
["." text
format]
[collection
- ["." list ("#/." functor fold)]]]
+ ["." list ("#;." functor fold)]]]
["." function]
[type
abstract]
@@ -58,7 +58,7 @@
(def: attributes
(-> Attributes Text)
- (|>> (list/map (function (_ [key val])
+ (|>> (list;map (function (_ [key val])
(format key "=" text.double-quote (..sanitize val) text.double-quote)))
(text.join-with " ")))
@@ -253,7 +253,7 @@
(def: (%polygon [first second third extra])
(Format Polygon)
(|> (list& first second third extra)
- (list/map %coord)
+ (list;map %coord)
(text.join-with ..coord-separator)))
(type: #export Shape
@@ -289,13 +289,13 @@
(-> Attributes (List [Attributes Shape]) Image Image)
($_ ..and
for
- (case (list/map (product.uncurry ..area) areas)
+ (case (list;map (product.uncurry ..area) areas)
#.Nil
(..empty "map" attributes)
(#.Cons head tail)
(..tag "map" attributes
- (list/fold (function.flip ..and) head tail)))))
+ (list;fold (function.flip ..and) head tail)))))
(do-template [<name> <tag> <type>]
[(def: #export <name>
@@ -449,7 +449,7 @@
(def: #export (description-list attributes descriptions)
(-> Attributes (List [Content Element]) Element)
- (case (list/map (function (_ [term description])
+ (case (list;map (function (_ [term description])
($_ ..and
(..term term)
(..description description)))
@@ -459,7 +459,7 @@
(#.Cons head tail)
(..tag "dl" attributes
- (list/fold (function.flip ..and) head tail))))
+ (list;fold (function.flip ..and) head tail))))
(def: #export p ..paragraph)
@@ -511,14 +511,14 @@
(def: #export (table attributes caption columns headers rows footer)
(-> Attributes (Maybe Content) (Maybe Column) Header (List Cell) (Maybe Cell) Element)
(let [head (..table-head (..table-row headers))
- content (case (list/map table-row rows)
+ content (case (list;map table-row rows)
#.Nil
head
(#.Cons first rest)
(..and head
(..table-body
- (list/fold (function.flip ..and) first rest))))
+ (list;fold (function.flip ..and) first rest))))
content (case footer
#.None
content
diff --git a/stdlib/source/lux/data/format/json.lux b/stdlib/source/lux/data/format/json.lux
index f2f7eef35..a213fa1d0 100644
--- a/stdlib/source/lux/data/format/json.lux
+++ b/stdlib/source/lux/data/format/json.lux
@@ -5,7 +5,7 @@
["." monad (#+ Monad do)]
[equivalence (#+ Equivalence)]
codec
- ["p" parser (#+ Parser) ("#/." monad)]
+ ["p" parser (#+ Parser) ("#;." monad)]
["ex" exception (#+ exception:)]]
[data
["." bit]
@@ -14,12 +14,12 @@
["." sum]
["." product]
[number
- ["." frac ("#/." decimal)]]
- ["." text ("#/." equivalence monoid)
+ ["." frac ("#;." decimal)]]
+ ["." text ("#;." equivalence monoid)
["l" lexer]]
[collection
- ["." list ("#/." fold monad)]
- ["." row (#+ Row row) ("#/." monad)]
+ ["." list ("#;." fold monad)]
+ ["." row (#+ Row row) ("#;." monad)]
["." dictionary (#+ Dictionary)]]]
["." macro (#+ monad with-gensyms)
["s" syntax (#+ syntax:)]
@@ -76,7 +76,7 @@
(wrap (list (` (: JSON #Null))))
[_ (#.Tuple members)]
- (wrap (list (` (: JSON (#Array ((~! row) (~+ (list/map wrapper members))))))))
+ (wrap (list (` (: JSON (#Array ((~! row) (~+ (list;map wrapper members))))))))
[_ (#.Record pairs)]
(do ..monad
@@ -102,7 +102,7 @@
(#error.Success (dictionary.keys obj))
_
- (#error.Failure ($_ text/compose "Cannot get the fields of a non-object."))))
+ (#error.Failure ($_ text;compose "Cannot get the fields of a non-object."))))
(def: #export (get key json)
{#.doc "A JSON object field getter."}
@@ -114,10 +114,10 @@
(#error.Success value)
#.None
- (#error.Failure ($_ text/compose "Missing field '" key "' on object.")))
+ (#error.Failure ($_ text;compose "Missing field '" key "' on object.")))
_
- (#error.Failure ($_ text/compose "Cannot get field '" key "' of a non-object."))))
+ (#error.Failure ($_ text;compose "Cannot get field '" key "' of a non-object."))))
(def: #export (set key value json)
{#.doc "A JSON object field setter."}
@@ -127,18 +127,18 @@
(#error.Success (#Object (dictionary.put key value obj)))
_
- (#error.Failure ($_ text/compose "Cannot set field '" key "' of a non-object."))))
+ (#error.Failure ($_ text;compose "Cannot set field '" key "' of a non-object."))))
(do-template [<name> <tag> <type> <desc>]
[(def: #export (<name> key json)
- {#.doc (code.text ($_ text/compose "A JSON object field getter for " <desc> "."))}
+ {#.doc (code.text ($_ text;compose "A JSON object field getter for " <desc> "."))}
(-> Text JSON (Error <type>))
(case (get key json)
(#error.Success (<tag> value))
(#error.Success value)
(#error.Success _)
- (#error.Failure ($_ text/compose "Wrong value type at key: " key))
+ (#error.Failure ($_ text;compose "Wrong value type at key: " key))
(#error.Failure error)
(#error.Failure error)))]
@@ -165,7 +165,7 @@
[(#Array xs) (#Array ys)]
(and (n/= (row.size xs) (row.size ys))
- (list/fold (function (_ idx prev)
+ (list;fold (function (_ idx prev)
(and prev
(maybe.default #0
(do maybe.monad
@@ -177,7 +177,7 @@
[(#Object xs) (#Object ys)]
(and (n/= (dictionary.size xs) (dictionary.size ys))
- (list/fold (function (_ [xk xv] prev)
+ (list;fold (function (_ [xk xv] prev)
(and prev
(case (dictionary.get xk ys)
#.None #0
@@ -208,16 +208,16 @@
(def: (show-array show-json elems)
(-> (-> JSON Text) (-> Array Text))
- ($_ text/compose "["
- (|> elems (row/map show-json) row.to-list (text.join-with ","))
+ ($_ text;compose "["
+ (|> elems (row;map show-json) row.to-list (text.join-with ","))
"]"))
(def: (show-object show-json object)
(-> (-> JSON Text) (-> Object Text))
- ($_ text/compose "{"
+ ($_ text;compose "{"
(|> object
dictionary.entries
- (list/map (function (_ [key value]) ($_ text/compose (show-string key) ":" (show-json value))))
+ (list;map (function (_ [key value]) ($_ text;compose (show-string key) ":" (show-json value))))
(text.join-with ","))
"}"))
@@ -241,7 +241,7 @@
(exception: #export (unconsumed-input {input (List JSON)})
(|> input
- (list/map show-json)
+ (list;map show-json)
(text.join-with text.new-line)))
(exception: #export (empty-input)
@@ -279,7 +279,7 @@
(do-template [<name> <type> <tag> <desc>]
[(def: #export <name>
- {#.doc (code.text ($_ text/compose "Reads a JSON value as " <desc> "."))}
+ {#.doc (code.text ($_ text;compose "Reads a JSON value as " <desc> "."))}
(Reader <type>)
(do p.monad
[head any]
@@ -288,7 +288,7 @@
(wrap value)
_
- (fail ($_ text/compose "JSON value is not " <desc> ".")))))]
+ (fail ($_ text;compose "JSON value is not " <desc> ".")))))]
[null Any #Null "null"]
[boolean Bit #Boolean "boolean"]
@@ -298,7 +298,7 @@
(do-template [<test> <check> <type> <eq> <encoder> <tag> <desc>]
[(def: #export (<test> test)
- {#.doc (code.text ($_ text/compose "Asks whether a JSON value is a " <desc> "."))}
+ {#.doc (code.text ($_ text;compose "Asks whether a JSON value is a " <desc> "."))}
(-> <type> (Reader Bit))
(do p.monad
[head any]
@@ -307,10 +307,10 @@
(wrap (:: <eq> = test value))
_
- (fail ($_ text/compose "JSON value is not " <desc> ".")))))
+ (fail ($_ text;compose "JSON value is not " <desc> ".")))))
(def: #export (<check> test)
- {#.doc (code.text ($_ text/compose "Ensures a JSON value is a " <desc> "."))}
+ {#.doc (code.text ($_ text;compose "Ensures a JSON value is a " <desc> "."))}
(-> <type> (Reader Any))
(do p.monad
[head any]
@@ -318,10 +318,10 @@
(<tag> value)
(if (:: <eq> = test value)
(wrap [])
- (fail ($_ text/compose "Value mismatch: " (<encoder> test) " =/= " (<encoder> value))))
+ (fail ($_ text;compose "Value mismatch: " (<encoder> test) " =/= " (<encoder> value))))
_
- (fail ($_ text/compose "JSON value is not a " <desc> ".")))))]
+ (fail ($_ text;compose "JSON value is not a " <desc> ".")))))]
[boolean? boolean! Bit bit.equivalence encode-boolean #Boolean "boolean"]
[number? number! Frac frac.equivalence (:: frac.decimal encode) #Number "number"]
@@ -353,7 +353,7 @@
(fail (ex.construct unconsumed-input remainder))))
_
- (fail (text/compose "JSON value is not an array: " (show-json head))))))
+ (fail (text;compose "JSON value is not an array: " (show-json head))))))
(def: #export (object parser)
{#.doc "Parses a JSON object. Use this with the 'field' combinator."}
@@ -364,7 +364,7 @@
(#Object kvs)
(case (p.run (|> kvs
dictionary.entries
- (list/map (function (_ [key value])
+ (list;map (function (_ [key value])
(list (#String key) value)))
list.concat)
parser)
@@ -380,7 +380,7 @@
(fail (ex.construct unconsumed-input remainder))))
_
- (fail (text/compose "JSON value is not an object: " (show-json head))))))
+ (fail (text;compose "JSON value is not an object: " (show-json head))))))
(def: #export (field field-name parser)
{#.doc "Parses a field inside a JSON object. Use this inside the 'object' combinator."}
@@ -388,7 +388,7 @@
(function (recur inputs)
(case inputs
(^ (list& (#String key) value inputs'))
- (if (text/= key field-name)
+ (if (text;= key field-name)
(case (p.run (list value) parser)
(#error.Success [#.Nil output])
(#error.Success [inputs' output])
@@ -456,8 +456,8 @@
[mark (l.one-of "eE")
signed?' (l.this? "-")
offset (l.many l.decimal)]
- (wrap ($_ text/compose mark (if signed?' "-" "") offset))))]
- (case (frac/decode ($_ text/compose (if signed? "-" "") digits "." decimals exp))
+ (wrap ($_ text;compose mark (if signed?' "-" "") offset))))]
+ (case (frac;decode ($_ text;compose (if signed? "-" "") digits "." decimals exp))
(#error.Failure message)
(p.fail message)
@@ -468,32 +468,32 @@
(l.Lexer Text)
($_ p.either
(p.after (l.this "\t")
- (p/wrap text.tab))
+ (p;wrap text.tab))
(p.after (l.this "\b")
- (p/wrap text.back-space))
+ (p;wrap text.back-space))
(p.after (l.this "\n")
- (p/wrap text.new-line))
+ (p;wrap text.new-line))
(p.after (l.this "\r")
- (p/wrap text.carriage-return))
+ (p;wrap text.carriage-return))
(p.after (l.this "\f")
- (p/wrap text.form-feed))
- (p.after (l.this (text/compose "\" text.double-quote))
- (p/wrap text.double-quote))
+ (p;wrap text.form-feed))
+ (p.after (l.this (text;compose "\" text.double-quote))
+ (p;wrap text.double-quote))
(p.after (l.this "\\")
- (p/wrap "\"))))
+ (p;wrap "\"))))
(def: string~
(l.Lexer String)
(<| (l.enclosed [text.double-quote text.double-quote])
(loop [_ []])
(do p.monad
- [chars (l.some (l.none-of (text/compose "\" text.double-quote)))
+ [chars (l.some (l.none-of (text;compose "\" text.double-quote)))
stop l.peek])
- (if (text/= "\" stop)
+ (if (text;= "\" stop)
(do @
[escaped escaped~
next-chars (recur [])]
- (wrap ($_ text/compose chars escaped next-chars)))
+ (wrap ($_ text;compose chars escaped next-chars)))
(wrap chars))))
(def: (kv~ json~)
diff --git a/stdlib/source/lux/data/format/markdown.lux b/stdlib/source/lux/data/format/markdown.lux
index 58f1f14b3..81c7118e7 100644
--- a/stdlib/source/lux/data/format/markdown.lux
+++ b/stdlib/source/lux/data/format/markdown.lux
@@ -4,7 +4,7 @@
["." text
format]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
[type
abstract]
[world
@@ -87,7 +87,7 @@
(def: (prefix with)
(-> Text (-> Text Text))
(|>> (text.split-all-with text.new-line)
- (list/map (function (_ line)
+ (list;map (function (_ line)
(if (text.empty? line)
line
(format with line))))
@@ -107,7 +107,7 @@
(-> (List [(Markdown Span) (Maybe (Markdown Block))])
(Markdown Block))
(|>> list.enumerate
- (list/map (function (_ [idx [summary detail]])
+ (list;map (function (_ [idx [summary detail]])
(format (%n (inc idx)) ". " (:representation summary) text.new-line
(case detail
(#.Some detail)
@@ -121,7 +121,7 @@
(def: #export bullet-list
(-> (List [(Markdown Span) (Maybe (Markdown Block))])
(Markdown Block))
- (|>> (list/map (function (_ [summary detail])
+ (|>> (list;map (function (_ [summary detail])
(format "*. " (:representation summary) text.new-line
(case detail
(#.Some detail)
diff --git a/stdlib/source/lux/data/format/xml.lux b/stdlib/source/lux/data/format/xml.lux
index a00ff24fa..85081f86c 100644
--- a/stdlib/source/lux/data/format/xml.lux
+++ b/stdlib/source/lux/data/format/xml.lux
@@ -4,18 +4,18 @@
monad
[equivalence (#+ Equivalence)]
codec
- ["p" parser ("#/." monad)]
+ ["p" parser ("#;." monad)]
["ex" exception (#+ exception:)]]
[data
["." error (#+ Error)]
["." product]
- ["." name ("#/." equivalence codec)]
+ ["." name ("#;." equivalence codec)]
[number
["." int]]
- ["." text ("#/." equivalence monoid)
+ ["." text ("#;." equivalence monoid)
["l" lexer]]
[collection
- ["." list ("#/." monad)]
+ ["." list ("#;." monad)]
["d" dictionary]]]])
(type: #export Tag Name)
@@ -30,11 +30,11 @@
(def: xml-standard-escape-char^
(l.Lexer Text)
($_ p.either
- (p.after (l.this "&lt;") (p/wrap "<"))
- (p.after (l.this "&gt;") (p/wrap ">"))
- (p.after (l.this "&amp;") (p/wrap "&"))
- (p.after (l.this "&apos;") (p/wrap "'"))
- (p.after (l.this "&quot;") (p/wrap text.double-quote))))
+ (p.after (l.this "&lt;") (p;wrap "<"))
+ (p.after (l.this "&gt;") (p;wrap ">"))
+ (p.after (l.this "&amp;") (p;wrap "&"))
+ (p.after (l.this "&apos;") (p;wrap "'"))
+ (p.after (l.this "&quot;") (p;wrap text.double-quote))))
(def: xml-unicode-escape-char^
(l.Lexer Text)
@@ -57,7 +57,7 @@
(def: xml-char^
(l.Lexer Text)
- (p.either (l.none-of ($_ text/compose "<>&'" text.double-quote))
+ (p.either (l.none-of ($_ text;compose "<>&'" text.double-quote))
xml-escape-char^))
(def: xml-identifier
@@ -67,7 +67,7 @@
l.alpha)
tail (l.some (p.either (l.one-of "_.-")
l.alpha-num))]
- (wrap ($_ text/compose head tail))))
+ (wrap ($_ text;compose head tail))))
(def: namespaced-symbol^
(l.Lexer Name)
@@ -111,10 +111,10 @@
spaced^
(p.after (l.this "/"))
(l.enclosed ["<" ">"]))]
- (p.assert ($_ text/compose "Close tag does not match open tag." text.new-line
- "Expected: " (name/encode expected) text.new-line
- " Actual: " (name/encode actual) text.new-line)
- (name/= expected actual))))
+ (p.assert ($_ text;compose "Close tag does not match open tag." text.new-line
+ "Expected: " (name;encode expected) text.new-line
+ " Actual: " (name;encode actual) text.new-line)
+ (name;= expected actual))))
(def: comment^
(l.Lexer Text)
@@ -142,7 +142,7 @@
(l.Lexer XML)
(|> (p.either cdata^
(l.many xml-char^))
- (p/map (|>> #Text))))
+ (p;map (|>> #Text))))
(def: xml^
(l.Lexer XML)
@@ -188,23 +188,23 @@
(-> Tag Text)
(case namespace
"" name
- _ ($_ text/compose namespace ":" name)))
+ _ ($_ text;compose namespace ":" name)))
(def: (write-attrs attrs)
(-> Attrs Text)
(|> attrs
d.entries
- (list/map (function (_ [key value])
- ($_ text/compose (write-tag key) "=" text.double-quote (sanitize-value value) text.double-quote)))
+ (list;map (function (_ [key value])
+ ($_ text;compose (write-tag key) "=" text.double-quote (sanitize-value value) text.double-quote)))
(text.join-with " ")))
(def: xml-header
Text
- ($_ text/compose "<?xml version=" text.double-quote "1.0" text.double-quote " encoding=" text.double-quote "UTF-8" text.double-quote "?>"))
+ ($_ text;compose "<?xml version=" text.double-quote "1.0" text.double-quote " encoding=" text.double-quote "UTF-8" text.double-quote "?>"))
(def: #export (write input)
(-> XML Text)
- ($_ text/compose xml-header
+ ($_ text;compose xml-header
(loop [input input]
(case input
(#Text value)
@@ -214,12 +214,12 @@
(let [tag (write-tag xml-tag)
attrs (if (d.empty? xml-attrs)
""
- ($_ text/compose " " (write-attrs xml-attrs)))]
+ ($_ text;compose " " (write-attrs xml-attrs)))]
(if (list.empty? xml-children)
- ($_ text/compose "<" tag attrs "/>")
- ($_ text/compose "<" tag attrs ">"
+ ($_ text;compose "<" tag attrs "/>")
+ ($_ text;compose "<" tag attrs ">"
(|> xml-children
- (list/map recur)
+ (list;map recur)
(text.join-with ""))
"</" tag ">")))))))
@@ -231,11 +231,11 @@
(def: (= reference sample)
(case [reference sample]
[(#Text reference/value) (#Text sample/value)]
- (text/= reference/value sample/value)
+ (text;= reference/value sample/value)
[(#Node reference/tag reference/attrs reference/children)
(#Node sample/tag sample/attrs sample/children)]
- (and (name/= reference/tag sample/tag)
+ (and (name;= reference/tag sample/tag)
(:: (d.equivalence text.equivalence) = reference/attrs sample/attrs)
(n/= (list.size reference/children)
(list.size sample/children))
@@ -253,13 +253,13 @@
(exception: #export unknown-attribute)
(exception: #export (wrong-tag {tag Name})
- (name/encode tag))
+ (name;encode tag))
-(def: blank-line ($_ text/compose text.new-line text.new-line))
+(def: blank-line ($_ text;compose text.new-line text.new-line))
(exception: #export (unconsumed-inputs {inputs (List XML)})
(|> inputs
- (list/map (:: ..codec encode))
+ (list;map (:: ..codec encode))
(text.join-with blank-line)))
(def: #export text
@@ -321,7 +321,7 @@
(ex.throw unexpected-input [])
(#Node _tag _attrs _children)
- (if (name/= tag _tag)
+ (if (name;= tag _tag)
(#error.Success [docs []])
(ex.throw wrong-tag tag))))))
diff --git a/stdlib/source/lux/data/name.lux b/stdlib/source/lux/data/name.lux
index 6f33e115e..0c658678b 100644
--- a/stdlib/source/lux/data/name.lux
+++ b/stdlib/source/lux/data/name.lux
@@ -5,7 +5,7 @@
[codec (#+ Codec)]
hash]
[data
- ["." text ("#/." monoid hash)]]])
+ ["." text ("#;." monoid hash)]]])
## [Types]
## (type: Name
@@ -24,18 +24,18 @@
## [Structures]
(structure: #export equivalence (Equivalence Name)
(def: (= [xmodule xname] [ymodule yname])
- (and (text/= xmodule ymodule)
- (text/= xname yname))))
+ (and (text;= xmodule ymodule)
+ (text;= xname yname))))
(structure: #export codec (Codec Text Name)
(def: (encode [module short])
(case module
"" short
- _ ($_ text/compose module "." short)))
+ _ ($_ text;compose module "." short)))
(def: (decode input)
- (if (text/= "" input)
- (#.Left (text/compose "Invalid format for Name: " input))
+ (if (text;= "" input)
+ (#.Left (text;compose "Invalid format for Name: " input))
(case (text.split-all-with "." input)
(^ (list short))
(#.Right ["" short])
@@ -44,10 +44,10 @@
(#.Right [module short])
_
- (#.Left (text/compose "Invalid format for Name: " input))))))
+ (#.Left (text;compose "Invalid format for Name: " input))))))
(structure: #export hash (Hash Name)
(def: &equivalence ..equivalence)
(def: (hash [module name])
- (n/+ (text/hash module) (text/hash name))))
+ (n/+ (text;hash module) (text;hash name))))
diff --git a/stdlib/source/lux/data/number/complex.lux b/stdlib/source/lux/data/number/complex.lux
index 62928d75e..d8c365bd5 100644
--- a/stdlib/source/lux/data/number/complex.lux
+++ b/stdlib/source/lux/data/number/complex.lux
@@ -10,10 +10,10 @@
[data
["." maybe]
[number
- ["." frac ("#/." number)]]
- ["." text ("#/." monoid)]
+ ["." frac ("#;." number)]]
+ ["." text ("#;." monoid)]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
["." macro
["." code]
["s" syntax (#+ syntax: Syntax)]]])
@@ -65,17 +65,17 @@
(def: #export negate
(-> Complex Complex)
- (|>> (update@ #real frac/negate)
- (update@ #imaginary frac/negate)))
+ (|>> (update@ #real frac;negate)
+ (update@ #imaginary frac;negate)))
(def: #export signum
(-> Complex Complex)
- (|>> (update@ #real frac/signum)
- (update@ #imaginary frac/signum)))
+ (|>> (update@ #real frac;signum)
+ (update@ #imaginary frac;signum)))
(def: #export conjugate
(-> Complex Complex)
- (update@ #imaginary frac/negate))
+ (update@ #imaginary frac;negate))
(def: #export (*' param input)
(-> Frac Complex Complex)
@@ -98,8 +98,8 @@
(def: #export (/ param input)
(-> Complex Complex Complex)
(let [(^slots [#real #imaginary]) param]
- (if (f/< (frac/abs imaginary)
- (frac/abs real))
+ (if (f/< (frac;abs imaginary)
+ (frac;abs real))
(let [quot (f// imaginary real)
denom (|> real (f/* quot) (f/+ imaginary))]
{#real (|> (get@ #real input) (f/* quot) (f/+ (get@ #imaginary input)) (f// denom))
@@ -129,7 +129,7 @@
(let [(^slots [#real #imaginary]) subject]
{#real (f/* (math.cosh imaginary)
(math.cos real))
- #imaginary (frac/negate (f/* (math.sinh imaginary)
+ #imaginary (frac;negate (f/* (math.sinh imaginary)
(math.sin real)))}))
(def: #export (cosh subject)
@@ -177,18 +177,18 @@
(def: #export (abs subject)
(-> Complex Complex)
(let [(^slots [#real #imaginary]) subject]
- (complex (if (f/< (frac/abs imaginary)
- (frac/abs real))
+ (complex (if (f/< (frac;abs imaginary)
+ (frac;abs real))
(if (f/= +0.0 imaginary)
- (frac/abs real)
+ (frac;abs real)
(let [q (f// imaginary real)]
(f/* (math.pow +0.5 (f/+ +1.0 (f/* q q)))
- (frac/abs imaginary))))
+ (frac;abs imaginary))))
(if (f/= +0.0 real)
- (frac/abs imaginary)
+ (frac;abs imaginary)
(let [q (f// real imaginary)]
(f/* (math.pow +0.5 (f/+ +1.0 (f/* q q)))
- (frac/abs real))))
+ (frac;abs real))))
))))
(structure: #export number (Number Complex)
@@ -199,13 +199,13 @@
(def: % ..%)
(def: (negate x)
(|> x
- (update@ #real frac/negate)
- (update@ #imaginary frac/negate)))
+ (update@ #real frac;negate)
+ (update@ #imaginary frac;negate)))
(def: abs ..abs)
(def: (signum x)
(|> x
- (update@ #real frac/signum)
- (update@ #imaginary frac/signum))))
+ (update@ #real frac;signum)
+ (update@ #imaginary frac;signum))))
(def: #export (exp subject)
(-> Complex Complex)
@@ -231,17 +231,17 @@
(def: (copy-sign sign magnitude)
(-> Frac Frac Frac)
- (f/* (frac/signum sign) magnitude))
+ (f/* (frac;signum sign) magnitude))
(def: #export (root2 (^@ input (^slots [#real #imaginary])))
(-> Complex Complex)
- (let [t (|> input ..abs (get@ #real) (f/+ (frac/abs real)) (f// +2.0) (math.pow +0.5))]
+ (let [t (|> input ..abs (get@ #real) (f/+ (frac;abs real)) (f// +2.0) (math.pow +0.5))]
(if (f/>= +0.0 real)
{#real t
#imaginary (f// (f/* +2.0 t)
imaginary)}
{#real (f// (f/* +2.0 t)
- (frac/abs imaginary))
+ (frac;abs imaginary))
#imaginary (f/* t (copy-sign imaginary +1.0))})))
(def: #export (root2-1z input)
@@ -250,18 +250,18 @@
(def: #export (reciprocal (^slots [#real #imaginary]))
(-> Complex Complex)
- (if (f/< (frac/abs imaginary)
- (frac/abs real))
+ (if (f/< (frac;abs imaginary)
+ (frac;abs real))
(let [q (f// imaginary real)
scale (f// (|> real (f/* q) (f/+ imaginary))
+1.0)]
{#real (f/* q scale)
- #imaginary (frac/negate scale)})
+ #imaginary (frac;negate scale)})
(let [q (f// real imaginary)
scale (f// (|> imaginary (f/* q) (f/+ real))
+1.0)]
{#real scale
- #imaginary (|> scale frac/negate (f/* q))})))
+ #imaginary (|> scale frac;negate (f/* q))})))
(def: #export (acos input)
(-> Complex Complex)
@@ -299,7 +299,7 @@
nth-phi (|> input argument (f// r-nth))
slice (|> math.pi (f/* +2.0) (f// r-nth))]
(|> (list.indices nth)
- (list/map (function (_ nth')
+ (list;map (function (_ nth')
(let [inner (|> nth' .int int-to-frac
(f/* slice)
(f/+ nth-phi))
diff --git a/stdlib/source/lux/data/number/int.lux b/stdlib/source/lux/data/number/int.lux
index 6e534caea..679147008 100644
--- a/stdlib/source/lux/data/number/int.lux
+++ b/stdlib/source/lux/data/number/int.lux
@@ -65,13 +65,13 @@
[minimum i/min (:: ..interval top)]
)
-(def: (int/sign!! value)
+(def: (int;sign!! value)
(-> Int Text)
(if (i/< +0 value)
"-"
"+"))
-(def: (int/sign?? representation)
+(def: (int;sign?? representation)
(-> Text (Maybe Int))
(case ("lux text char" representation 0)
(^ (char "-"))
@@ -107,7 +107,7 @@
<to-character>
maybe.assume)]
(if (i/= +0 input)
- ("lux text concat" (int/sign!! value) output)
+ ("lux text concat" (int;sign!! value) output)
(let [digit (maybe.assume (<to-character> (.nat (i/% <base> input))))]
(recur (i// <base> input)
("lux text concat" digit output)))))))
@@ -115,7 +115,7 @@
(def: (decode repr)
(let [input-size ("lux text size" repr)]
(if (n/> 1 input-size)
- (case (int/sign?? repr)
+ (case (int;sign?? repr)
(#.Some sign)
(int-decode-loop input-size repr sign <base> <to-value> <error>)
diff --git a/stdlib/source/lux/data/number/ratio.lux b/stdlib/source/lux/data/number/ratio.lux
index 3303b07c9..907cb950f 100644
--- a/stdlib/source/lux/data/number/ratio.lux
+++ b/stdlib/source/lux/data/number/ratio.lux
@@ -12,8 +12,8 @@
["." product]
["." maybe]
[number
- ["." nat ("#/." decimal)]]
- ["." text ("#/." monoid)
+ ["." nat ("#;." decimal)]]
+ ["." text ("#;." monoid)
format]]
["." function]
["." math]
@@ -132,23 +132,23 @@
(def: part-encode
(-> Nat Text)
- (|>> nat/encode (text.split 1) maybe.assume product.right))
+ (|>> nat;encode (text.split 1) maybe.assume product.right))
(structure: #export codec (Codec Text Ratio)
(def: (encode (^slots [#numerator #denominator]))
- ($_ text/compose (part-encode numerator) separator (part-encode denominator)))
+ ($_ text;compose (part-encode numerator) separator (part-encode denominator)))
(def: (decode input)
(case (text.split-with separator input)
(#.Some [num denom])
(do error.monad
- [numerator (nat/decode num)
- denominator (nat/decode denom)]
+ [numerator (nat;decode num)
+ denominator (nat;decode denom)]
(wrap (normalize {#numerator numerator
#denominator denominator})))
#.None
- (#.Left (text/compose "Invalid syntax for ratio: " input)))))
+ (#.Left (text;compose "Invalid syntax for ratio: " input)))))
(syntax: #export (ratio numerator {?denominator (p.maybe s.any)})
{#.doc (doc "Rational literals."
diff --git a/stdlib/source/lux/data/text.lux b/stdlib/source/lux/data/text.lux
index 29bbd98ab..00ad654e2 100644
--- a/stdlib/source/lux/data/text.lux
+++ b/stdlib/source/lux/data/text.lux
@@ -12,7 +12,7 @@
[number
["." i64]]
[collection
- ["." list ("#/." fold)]]]
+ ["." list ("#;." fold)]]]
[tool
[compiler
["." host]]]])
@@ -221,7 +221,7 @@
(def: #export concat
(-> (List Text) Text)
(let [(^open ".") ..monoid]
- (|>> list.reverse (list/fold compose identity))))
+ (|>> list.reverse (list;fold compose identity))))
(def: #export (join-with sep texts)
(-> Text (List Text) Text)
diff --git a/stdlib/source/lux/data/text/buffer.lux b/stdlib/source/lux/data/text/buffer.lux
index 061f5a164..6260894c6 100644
--- a/stdlib/source/lux/data/text/buffer.lux
+++ b/stdlib/source/lux/data/text/buffer.lux
@@ -5,7 +5,7 @@
[text
format]
[collection
- ["." row (#+ Row) ("#/." fold)]]]
+ ["." row (#+ Row) ("#;." fold)]]]
[compiler
["_" host]]
[type
@@ -57,7 +57,7 @@
(for {(~~ (static _.jvm))
(|> buffer :representation product.left)}
## default
- (row/fold (function (_ chunk total)
+ (row;fold (function (_ chunk total)
(n/+ (//.size chunk) total))
0
(:representation buffer))))
@@ -70,7 +70,7 @@
transform
StringBuilder::toString))}
## default
- (row/fold (function (_ chunk total)
+ (row;fold (function (_ chunk total)
(format total chunk))
""
(:representation buffer))))
diff --git a/stdlib/source/lux/data/text/format.lux b/stdlib/source/lux/data/text/format.lux
index b93aec640..83701c972 100644
--- a/stdlib/source/lux/data/text/format.lux
+++ b/stdlib/source/lux/data/text/format.lux
@@ -16,7 +16,7 @@
["." xml]
["." json]]
[collection
- ["." list ("#/." monad)]]]
+ ["." list ("#;." monad)]]]
[time
["." instant]
["." duration]
@@ -85,4 +85,4 @@
"(list)"
_
- (format "(list " (text.join-with " " (list/map formatter values)) ")"))))
+ (format "(list " (text.join-with " " (list;map formatter values)) ")"))))
diff --git a/stdlib/source/lux/data/text/lexer.lux b/stdlib/source/lux/data/text/lexer.lux
index 8b77ac4f6..923fb91a8 100644
--- a/stdlib/source/lux/data/text/lexer.lux
+++ b/stdlib/source/lux/data/text/lexer.lux
@@ -9,12 +9,12 @@
["." maybe]
["." error (#+ Error)]
[number
- ["." nat ("#/." decimal)]]
+ ["." nat ("#;." decimal)]]
[collection
- ["." list ("#/." fold)]]]
+ ["." list ("#;." fold)]]]
[macro
["." code]]]
- ["." // ("#/." monoid)])
+ ["." // ("#;." monoid)])
(type: #export Offset Nat)
@@ -34,8 +34,8 @@
(|> tape (//.split offset) maybe.assume product.right))
(exception: #export (unconsumed-input {offset Offset} {tape Text})
- (ex.report ["Offset" (nat/encode offset)]
- ["Input size" (nat/encode (//.size tape))]
+ (ex.report ["Offset" (nat;encode offset)]
+ ["Input size" (nat;encode (//.size tape))]
["Remaining input" (remaining offset tape)]))
(def: #export (run input lexer)
@@ -59,7 +59,7 @@
(do p.monad
[offset ..offset
slices lexer]
- (wrap (list/fold (function (_ [slice::basis slice::distance]
+ (wrap (list;fold (function (_ [slice::basis slice::distance]
[total::basis total::distance])
[total::basis ("lux i64 +" slice::distance total::distance)])
{#basis offset
@@ -110,10 +110,10 @@
(if (n/= offset where)
(#error.Success [[("lux i64 +" (//.size reference) offset) tape]
[]])
- (#error.Failure ($_ ///compose "Could not match: " (//.encode reference) " @ " (maybe.assume (//.clip' offset tape)))))
+ (#error.Failure ($_ //;compose "Could not match: " (//.encode reference) " @ " (maybe.assume (//.clip' offset tape)))))
_
- (#error.Failure ($_ ///compose "Could not match: " (//.encode reference))))))
+ (#error.Failure ($_ //;compose "Could not match: " (//.encode reference))))))
(def: #export (this? reference)
{#.doc "Lex a text if it matches the given sample."}
@@ -164,14 +164,14 @@
(do p.monad
[char any
#let [char' (maybe.assume (//.nth 0 char))]
- _ (p.assert ($_ ///compose "Character is not within range: " (//.from-code bottom) "-" (//.from-code top))
+ _ (p.assert ($_ //;compose "Character is not within range: " (//.from-code bottom) "-" (//.from-code top))
(.and (n/>= bottom char')
(n/<= top char')))]
(wrap char)))
(do-template [<name> <bottom> <top> <desc>]
[(def: #export <name>
- {#.doc (code.text ($_ ///compose "Only lex " <desc> " characters."))}
+ {#.doc (code.text ($_ //;compose "Only lex " <desc> " characters."))}
(Lexer Text)
(range (char <bottom>) (char <top>)))]
@@ -201,7 +201,7 @@
(do-template [<name> <description-modifier> <modifier>]
[(def: #export (<name> options)
- {#.doc (code.text ($_ ///compose "Only lex characters that are" <description-modifier> " part of a piece of text."))}
+ {#.doc (code.text ($_ //;compose "Only lex characters that are" <description-modifier> " part of a piece of text."))}
(-> Text (Lexer Text))
(function (_ [offset tape])
(case (//.nth offset tape)
@@ -209,7 +209,7 @@
(let [output (//.from-code output)]
(if (<modifier> (//.contains? output options))
(#error.Success [[("lux i64 +" 1 offset) tape] output])
- (#error.Failure ($_ ///compose "Character (" output
+ (#error.Failure ($_ //;compose "Character (" output
") is should " <description-modifier>
"be one of: " options))))
@@ -222,7 +222,7 @@
(do-template [<name> <description-modifier> <modifier>]
[(def: #export (<name> options)
- {#.doc (code.text ($_ ///compose "Only lex characters that are" <description-modifier> " part of a piece of text."))}
+ {#.doc (code.text ($_ //;compose "Only lex characters that are" <description-modifier> " part of a piece of text."))}
(-> Text (Lexer Slice))
(function (_ [offset tape])
(case (//.nth offset tape)
@@ -232,7 +232,7 @@
(#error.Success [[("lux i64 +" 1 offset) tape]
{#basis offset
#distance 1}])
- (#error.Failure ($_ ///compose "Character (" output
+ (#error.Failure ($_ //;compose "Character (" output
") is should " <description-modifier>
"be one of: " options))))
@@ -251,7 +251,7 @@
(#.Some output)
(if (p output)
(#error.Success [[("lux i64 +" 1 offset) tape] (//.from-code output)])
- (#error.Failure ($_ ///compose "Character does not satisfy predicate: " (//.from-code output))))
+ (#error.Failure ($_ //;compose "Character does not satisfy predicate: " (//.from-code output))))
_
(#error.Failure cannot-lex-error))))
@@ -266,7 +266,7 @@
(do p.monad
[=left left
=right right]
- (wrap ($_ ///compose =left =right))))
+ (wrap ($_ //;compose =left =right))))
(def: #export (and! left right)
(-> (Lexer Slice) (Lexer Slice) (Lexer Slice))
@@ -277,7 +277,7 @@
(do-template [<name> <base> <doc-modifier>]
[(def: #export (<name> lexer)
- {#.doc (code.text ($_ ///compose "Lex " <doc-modifier> " characters as a single continuous text."))}
+ {#.doc (code.text ($_ //;compose "Lex " <doc-modifier> " characters as a single continuous text."))}
(-> (Lexer Text) (Lexer Text))
(|> lexer <base> (:: p.monad map //.concat)))]
@@ -287,7 +287,7 @@
(do-template [<name> <base> <doc-modifier>]
[(def: #export (<name> lexer)
- {#.doc (code.text ($_ ///compose "Lex " <doc-modifier> " characters as a single continuous text."))}
+ {#.doc (code.text ($_ //;compose "Lex " <doc-modifier> " characters as a single continuous text."))}
(-> (Lexer Slice) (Lexer Slice))
(with-slices (<base> lexer)))]
@@ -297,7 +297,7 @@
(do-template [<name> <base> <doc-modifier>]
[(def: #export (<name> amount lexer)
- {#.doc (code.text ($_ ///compose "Lex " <doc-modifier> " N characters."))}
+ {#.doc (code.text ($_ //;compose "Lex " <doc-modifier> " N characters."))}
(-> Nat (Lexer Text) (Lexer Text))
(|> lexer (<base> amount) (:: p.monad map //.concat)))]
@@ -308,7 +308,7 @@
(do-template [<name> <base> <doc-modifier>]
[(def: #export (<name> amount lexer)
- {#.doc (code.text ($_ ///compose "Lex " <doc-modifier> " N characters."))}
+ {#.doc (code.text ($_ //;compose "Lex " <doc-modifier> " N characters."))}
(-> Nat (Lexer Slice) (Lexer Slice))
(with-slices (<base> amount lexer)))]
diff --git a/stdlib/source/lux/data/text/regex.lux b/stdlib/source/lux/data/text/regex.lux
index 51a2b097e..2897a09fa 100644
--- a/stdlib/source/lux/data/text/regex.lux
+++ b/stdlib/source/lux/data/text/regex.lux
@@ -2,15 +2,15 @@
[lux #*
[control
monad
- ["p" parser ("#/." monad)]]
+ ["p" parser ("#;." monad)]]
[data
["." product]
["." error]
["." maybe]
["." number (#+ hex)
- ["." int ("#/." codec)]]
+ ["." int ("#;." codec)]]
[collection
- ["." list ("#/." fold monad)]]]
+ ["." list ("#;." fold monad)]]]
["." macro (#+ with-gensyms)
["." code]
["s" syntax (#+ syntax:)]]]
@@ -45,7 +45,7 @@
(def: (copy reference)
(-> Text (l.Lexer Text))
- (p.after (l.this reference) (p/wrap reference)))
+ (p.after (l.this reference) (p;wrap reference)))
(def: (join-text^ part^)
(-> (l.Lexer (List Text)) (l.Lexer Text))
@@ -68,10 +68,10 @@
(def: (name^ current-module)
(-> Text (l.Lexer Name))
($_ p.either
- (p.and (p/wrap current-module) (p.after (l.this "..") name-part^))
+ (p.and (p;wrap current-module) (p.after (l.this "..") name-part^))
(p.and name-part^ (p.after (l.this ".") name-part^))
- (p.and (p/wrap "lux") (p.after (l.this ".") name-part^))
- (p.and (p/wrap "") name-part^)))
+ (p.and (p;wrap "lux") (p.after (l.this ".") name-part^))
+ (p.and (p;wrap "") name-part^)))
(def: (re-var^ current-module)
(-> Text (l.Lexer Code))
@@ -116,7 +116,7 @@
[_ (wrap [])
init re-user-class^'
rest (p.some (p.after (l.this "&&") (l.enclosed ["[" "]"] re-user-class^')))]
- (wrap (list/fold (function (_ refinement base)
+ (wrap (list;fold (function (_ refinement base)
(` ((~! refine^) (~ refinement) (~ base))))
init
rest))))
@@ -192,7 +192,7 @@
(p.either (do p.monad
[_ (l.this "\")
id number^]
- (wrap (` ((~! ..copy) (~ (code.identifier ["" (int/encode (.int id))]))))))
+ (wrap (` ((~! ..copy) (~ (code.identifier ["" (int;encode (.int id))]))))))
(do p.monad
[_ (l.this "\k<")
captured-name name-part^
@@ -271,7 +271,7 @@
(re-scoped^ current-module)))
#let [g!total (code.identifier ["" "0total"])
g!temp (code.identifier ["" "0temp"])
- [_ names steps] (list/fold (: (-> (Either Code [Re-Group Code])
+ [_ names steps] (list;fold (: (-> (Either Code [Re-Group Code])
[Int (List Code) (List (List Code))]
[Int (List Code) (List (List Code))])
(function (_ part [idx names steps])
@@ -289,7 +289,7 @@
[idx (code.identifier ["" _name])]
#.None
- [(inc idx) (code.identifier ["" (int/encode idx)])])
+ [(inc idx) (code.identifier ["" (int;encode idx)])])
access (if (n/> 0 num-captures)
(` ((~! product.left) (~ name!)))
name!)]
@@ -308,7 +308,7 @@
0)
(` (do p.monad
[(~ (' #let)) [(~ g!total) ""]
- (~+ (|> steps list.reverse list/join))]
+ (~+ (|> steps list.reverse list;join))]
((~ (' wrap)) [(~ g!total) (~+ (list.reverse names))])))])
))
@@ -364,13 +364,13 @@
#let [g!op (code.identifier ["" " alt "])]]
(if (list.empty? tail)
(wrap head)
- (wrap [(list/fold n/max (product.left head) (list/map product.left tail))
+ (wrap [(list;fold n/max (product.left head) (list;map product.left tail))
(` (let [(~ g!op) (~ (if capturing?
(` (~! |||^))
(` (~! |||_^))))]
($_ (~ g!op)
(~ (prep-alternative head))
- (~+ (list/map prep-alternative tail)))))]))))
+ (~+ (list;map prep-alternative tail)))))]))))
(def: (re-scoped^ current-module)
(-> Text (l.Lexer [Re-Group Code]))
diff --git a/stdlib/source/lux/data/text/unicode.lux b/stdlib/source/lux/data/text/unicode.lux
index 00c60f365..951bfe761 100644
--- a/stdlib/source/lux/data/text/unicode.lux
+++ b/stdlib/source/lux/data/text/unicode.lux
@@ -5,7 +5,7 @@
[monoid (#+ Monoid)]]
[data
[number (#+ hex)
- ["." nat ("#/." interval)]]
+ ["." nat ("#;." interval)]]
[collection
["." list]
[tree
@@ -18,7 +18,7 @@
{}
(Interval Char)
- (def: empty (:abstraction (interval.between nat.enum nat/top nat/bottom)))
+ (def: empty (:abstraction (interval.between nat.enum nat;top nat;bottom)))
(structure: monoid (Monoid Segment)
(def: identity ..empty)
diff --git a/stdlib/source/lux/host.js.lux b/stdlib/source/lux/host.js.lux
index 09d7d2fea..7c182f363 100644
--- a/stdlib/source/lux/host.js.lux
+++ b/stdlib/source/lux/host.js.lux
@@ -5,7 +5,7 @@
["p" parser]]
[data
[collection
- ["." list #* ("#/." fold)]]]
+ ["." list #* ("#;." fold)]]]
[macro (#+ with-gensyms)
["." code]
["s" syntax (#+ syntax: Syntax)]]])
@@ -49,7 +49,7 @@
{#.doc (doc "A way to create JavaScript objects."
(object)
(object "foo" foo "bar" (inc bar)))}
- (wrap (list (list/fold (function (_ [k v] object)
+ (wrap (list (list;fold (function (_ [k v] object)
(` (set! (~ k) (~ v) (~ object))))
(` ("js object"))
kvs))))
diff --git a/stdlib/source/lux/host.jvm.lux b/stdlib/source/lux/host.jvm.lux
index b85bdf2a0..cdef88e92 100644
--- a/stdlib/source/lux/host.jvm.lux
+++ b/stdlib/source/lux/host.jvm.lux
@@ -8,15 +8,15 @@
["." maybe]
["." product]
["." error (#+ Error)]
- ["." bit ("#/." codec)]
+ ["." bit ("#;." codec)]
number
- ["." text ("#/." equivalence monoid)
+ ["." text ("#;." equivalence monoid)
format]
[collection
["." array (#+ Array)]
- ["." list ("#/." monad fold monoid)]]]
+ ["." list ("#;." monad fold monoid)]]]
["." function]
- ["." type ("#/." equivalence)]
+ ["." type ("#;." equivalence)]
["." macro (#+ with-gensyms)
["." code]
["s" syntax (#+ syntax: Syntax)]]
@@ -290,7 +290,7 @@
[[name params] _ _]
(let [name (sanitize name)
- =params (list/map (class->type' mode type-params in-array?) params)]
+ =params (list;map (class->type' mode type-params in-array?) params)]
(` (primitive (~ (code.text name)) [(~+ =params)])))))
(def: (class->type' mode type-params in-array? class)
@@ -298,7 +298,7 @@
(case class
(#GenericTypeVar name)
(case (list.find (function (_ [pname pbounds])
- (and (text/= name pname)
+ (and (text;= name pname)
(not (list.empty? pbounds))))
type-params)
#.None
@@ -332,7 +332,7 @@
(def: (class-decl-type$ (^slots [#class-name #class-params]))
(-> Class-Declaration Code)
- (let [=params (list/map (: (-> Type-Paramameter Code)
+ (let [=params (list;map (: (-> Type-Paramameter Code)
(function (_ [pname pbounds])
(case pbounds
#.Nil
@@ -351,7 +351,7 @@
(def: (get-import name imports)
(-> Text Class-Imports (Maybe Text))
(:: maybe.functor map product.right
- (list.find (|>> product.left (text/= name))
+ (list.find (|>> product.left (text;= name))
imports)))
(def: (add-import short+full imports)
@@ -365,7 +365,7 @@
(do macro.monad
[current-module macro.current-module-name
definitions (macro.definitions current-module)]
- (wrap (list/fold (: (-> [Text Definition] Class-Imports Class-Imports)
+ (wrap (list;fold (: (-> [Text Definition] Class-Imports Class-Imports)
(function (_ [short-name [_ meta _]] imports)
(case (macro.get-text-ann (name-of #..jvm-class) meta)
(#.Some full-class-name)
@@ -474,7 +474,7 @@
(case class
(#GenericTypeVar name)
(case (list.find (function (_ [pname pbounds])
- (and (text/= name pname)
+ (and (text;= name pname)
(not (list.empty? pbounds))))
env)
#.None
@@ -540,12 +540,12 @@
(case (f input)
(^template [<tag>]
[meta (<tag> parts)]
- [meta (<tag> (list/map (pre-walk-replace f) parts))])
+ [meta (<tag> (list;map (pre-walk-replace f) parts))])
([#.Form]
[#.Tuple])
[meta (#.Record pairs)]
- [meta (#.Record (list/map (: (-> [Code Code] [Code Code])
+ [meta (#.Record (list;map (: (-> [Code Code] [Code Code])
(function (_ [key val])
[(pre-walk-replace f key) (pre-walk-replace f val)]))
pairs))]
@@ -579,7 +579,7 @@
[args (: (Syntax (List Code))
(s.form (p.after (s.this (' ::new!))
(s.tuple (p.exactly (list.size arg-decls) s.any)))))
- #let [arg-decls' (: (List Text) (list/map (|>> product.right (simple-class$ params)) arg-decls))]]
+ #let [arg-decls' (: (List Text) (list;map (|>> product.right (simple-class$ params)) arg-decls))]]
(wrap (` ((~ (code.text (format "jvm new" ":" class-name ":" (text.join-with "," arg-decls'))))
(~+ args))))))
@@ -590,7 +590,7 @@
args (: (Syntax (List Code))
(s.form (p.after (s.this (code.identifier ["" dotted-name]))
(s.tuple (p.exactly (list.size arg-decls) s.any)))))
- #let [arg-decls' (: (List Text) (list/map (|>> product.right (simple-class$ params)) arg-decls))]]
+ #let [arg-decls' (: (List Text) (list;map (|>> product.right (simple-class$ params)) arg-decls))]]
(wrap (`' ((~ (code.text (format "jvm invokestatic" ":" class-name ":" method-name ":" (text.join-with "," arg-decls'))))
(~+ args))))))
@@ -602,7 +602,7 @@
args (: (Syntax (List Code))
(s.form (p.after (s.this (code.identifier ["" dotted-name]))
(s.tuple (p.exactly (list.size arg-decls) s.any)))))
- #let [arg-decls' (: (List Text) (list/map (|>> product.right (simple-class$ params)) arg-decls))]]
+ #let [arg-decls' (: (List Text) (list;map (|>> product.right (simple-class$ params)) arg-decls))]]
(wrap (`' ((~ (code.text (format <jvm-op> ":" class-name ":" method-name ":" (text.join-with "," arg-decls'))))
(~' _jvm_this) (~+ args))))))]
@@ -677,7 +677,7 @@
(do p.monad
[name (full-class-name^ imports)
_ (assert-no-periods name)]
- (if (list.member? text.equivalence (list/map product.left type-vars) name)
+ (if (list.member? text.equivalence (list;map product.left type-vars) name)
(wrap (#GenericTypeVar name))
(wrap (#GenericClass name (list)))))
(s.form (do p.monad
@@ -703,7 +703,7 @@
_ (assert-no-periods name)
params (p.some (generic-type^ imports type-vars))
_ (p.assert (format name " cannot be a type-parameter!")
- (not (list.member? text.equivalence (list/map product.left type-vars) name)))]
+ (not (list.member? text.equivalence (list;map product.left type-vars) name)))]
(wrap (#GenericClass name params))))
))
@@ -844,7 +844,7 @@
[pm privacy-modifier^
strict-fp? (s.this? (' #strict))
method-vars (p.default (list) (type-params^ imports))
- #let [total-vars (list/compose class-vars method-vars)]
+ #let [total-vars (list;compose class-vars method-vars)]
[_ arg-decls] (s.form (p.and (s.this (' new))
(arg-decls^ imports total-vars)))
constructor-args (constructor-args^ imports total-vars)
@@ -863,7 +863,7 @@
strict-fp? (s.this? (' #strict))
final? (s.this? (' #final))
method-vars (p.default (list) (type-params^ imports))
- #let [total-vars (list/compose class-vars method-vars)]
+ #let [total-vars (list;compose class-vars method-vars)]
[name arg-decls] (s.form (p.and s.local-identifier
(arg-decls^ imports total-vars)))
return-type (generic-type^ imports total-vars)
@@ -881,7 +881,7 @@
[strict-fp? (s.this? (' #strict))
owner-class (class-decl^ imports)
method-vars (p.default (list) (type-params^ imports))
- #let [total-vars (list/compose (product.right owner-class) method-vars)]
+ #let [total-vars (list;compose (product.right owner-class) method-vars)]
[name arg-decls] (s.form (p.and s.local-identifier
(arg-decls^ imports total-vars)))
return-type (generic-type^ imports total-vars)
@@ -1000,7 +1000,7 @@
[tvars (p.default (list) (type-params^ imports))
_ (s.this (' new))
?alias import-member-alias^
- #let [total-vars (list/compose owner-vars tvars)]
+ #let [total-vars (list;compose owner-vars tvars)]
?prim-mode (p.maybe primitive-mode^)
args (import-member-args^ imports total-vars)
[io? try? maybe?] import-member-return-flags^]
@@ -1021,7 +1021,7 @@
tvars (p.default (list) (type-params^ imports))
name s.local-identifier
?alias import-member-alias^
- #let [total-vars (list/compose owner-vars tvars)]
+ #let [total-vars (list;compose owner-vars tvars)]
?prim-mode (p.maybe primitive-mode^)
args (import-member-args^ imports total-vars)
[io? try? maybe?] import-member-return-flags^
@@ -1086,7 +1086,7 @@
(def: (annotation$ [name params])
(-> Annotation JVM-Code)
- (format "(" name " " "{" (text.join-with text.tab (list/map annotation-param$ params)) "}" ")"))
+ (format "(" name " " "{" (text.join-with text.tab (list;map annotation-param$ params)) "}" ")"))
(def: (bound-kind$ kind)
(-> BoundKind JVM-Code)
@@ -1101,7 +1101,7 @@
name
(#GenericClass name params)
- (format "(" (sanitize name) " " (spaced (list/map generic-type$ params)) ")")
+ (format "(" (sanitize name) " " (spaced (list;map generic-type$ params)) ")")
(#GenericArray param)
(format "(" array.type-name " " (generic-type$ param) ")")
@@ -1114,25 +1114,25 @@
(def: (type-param$ [name bounds])
(-> Type-Paramameter JVM-Code)
- (format "(" name " " (spaced (list/map generic-type$ bounds)) ")"))
+ (format "(" name " " (spaced (list;map generic-type$ bounds)) ")"))
(def: (class-decl$ (^open "."))
(-> Class-Declaration JVM-Code)
- (format "(" (sanitize class-name) " " (spaced (list/map type-param$ class-params)) ")"))
+ (format "(" (sanitize class-name) " " (spaced (list;map type-param$ class-params)) ")"))
(def: (super-class-decl$ (^slots [#super-class-name #super-class-params]))
(-> Super-Class-Decl JVM-Code)
- (format "(" (sanitize super-class-name) " " (spaced (list/map generic-type$ super-class-params)) ")"))
+ (format "(" (sanitize super-class-name) " " (spaced (list;map generic-type$ super-class-params)) ")"))
(def: (method-decl$ [[name pm anns] method-decl])
(-> [Member-Declaration MethodDecl] JVM-Code)
(let [(^slots [#method-tvars #method-inputs #method-output #method-exs]) method-decl]
(with-parens
(spaced (list name
- (with-brackets (spaced (list/map annotation$ anns)))
- (with-brackets (spaced (list/map type-param$ method-tvars)))
- (with-brackets (spaced (list/map generic-type$ method-exs)))
- (with-brackets (spaced (list/map generic-type$ method-inputs)))
+ (with-brackets (spaced (list;map annotation$ anns)))
+ (with-brackets (spaced (list;map type-param$ method-tvars)))
+ (with-brackets (spaced (list;map generic-type$ method-exs)))
+ (with-brackets (spaced (list;map generic-type$ method-inputs)))
(generic-type$ method-output))
))))
@@ -1149,7 +1149,7 @@
(#ConstantField class value)
(with-parens
(spaced (list "constant" name
- (with-brackets (spaced (list/map annotation$ anns)))
+ (with-brackets (spaced (list;map annotation$ anns)))
(generic-type$ class)
(code.to-text value))
))
@@ -1159,7 +1159,7 @@
(spaced (list "variable" name
(privacy-modifier$ pm)
(state-modifier$ sm)
- (with-brackets (spaced (list/map annotation$ anns)))
+ (with-brackets (spaced (list;map annotation$ anns)))
(generic-type$ class))
))
))
@@ -1181,12 +1181,12 @@
(with-parens
(spaced (list "init"
(privacy-modifier$ pm)
- (bit/encode strict-fp?)
- (with-brackets (spaced (list/map annotation$ anns)))
- (with-brackets (spaced (list/map type-param$ type-vars)))
- (with-brackets (spaced (list/map generic-type$ exs)))
- (with-brackets (spaced (list/map arg-decl$ arg-decls)))
- (with-brackets (spaced (list/map constructor-arg$ constructor-args)))
+ (bit;encode strict-fp?)
+ (with-brackets (spaced (list;map annotation$ anns)))
+ (with-brackets (spaced (list;map type-param$ type-vars)))
+ (with-brackets (spaced (list;map generic-type$ exs)))
+ (with-brackets (spaced (list;map arg-decl$ arg-decls)))
+ (with-brackets (spaced (list;map constructor-arg$ constructor-args)))
(code.to-text (pre-walk-replace replacer body))
)))
@@ -1195,12 +1195,12 @@
(spaced (list "virtual"
name
(privacy-modifier$ pm)
- (bit/encode final?)
- (bit/encode strict-fp?)
- (with-brackets (spaced (list/map annotation$ anns)))
- (with-brackets (spaced (list/map type-param$ type-vars)))
- (with-brackets (spaced (list/map generic-type$ exs)))
- (with-brackets (spaced (list/map arg-decl$ arg-decls)))
+ (bit;encode final?)
+ (bit;encode strict-fp?)
+ (with-brackets (spaced (list;map annotation$ anns)))
+ (with-brackets (spaced (list;map type-param$ type-vars)))
+ (with-brackets (spaced (list;map generic-type$ exs)))
+ (with-brackets (spaced (list;map arg-decl$ arg-decls)))
(generic-type$ return-type)
(code.to-text (pre-walk-replace replacer body)))))
@@ -1208,7 +1208,7 @@
(let [super-replacer (parser->replacer (s.form (do p.monad
[_ (s.this (' ::super!))
args (s.tuple (p.exactly (list.size arg-decls) s.any))
- #let [arg-decls' (: (List Text) (list/map (|>> product.right (simple-class$ (list)))
+ #let [arg-decls' (: (List Text) (list;map (|>> product.right (simple-class$ (list)))
arg-decls))]]
(wrap (`' ((~ (code.text (format "jvm invokespecial"
":" (get@ #super-class-name super-class)
@@ -1219,11 +1219,11 @@
(spaced (list "override"
(class-decl$ class-decl)
name
- (bit/encode strict-fp?)
- (with-brackets (spaced (list/map annotation$ anns)))
- (with-brackets (spaced (list/map type-param$ type-vars)))
- (with-brackets (spaced (list/map generic-type$ exs)))
- (with-brackets (spaced (list/map arg-decl$ arg-decls)))
+ (bit;encode strict-fp?)
+ (with-brackets (spaced (list;map annotation$ anns)))
+ (with-brackets (spaced (list;map type-param$ type-vars)))
+ (with-brackets (spaced (list;map generic-type$ exs)))
+ (with-brackets (spaced (list;map arg-decl$ arg-decls)))
(generic-type$ return-type)
(|> body
(pre-walk-replace replacer)
@@ -1236,11 +1236,11 @@
(spaced (list "static"
name
(privacy-modifier$ pm)
- (bit/encode strict-fp?)
- (with-brackets (spaced (list/map annotation$ anns)))
- (with-brackets (spaced (list/map type-param$ type-vars)))
- (with-brackets (spaced (list/map generic-type$ exs)))
- (with-brackets (spaced (list/map arg-decl$ arg-decls)))
+ (bit;encode strict-fp?)
+ (with-brackets (spaced (list;map annotation$ anns)))
+ (with-brackets (spaced (list;map type-param$ type-vars)))
+ (with-brackets (spaced (list;map generic-type$ exs)))
+ (with-brackets (spaced (list;map arg-decl$ arg-decls)))
(generic-type$ return-type)
(code.to-text (pre-walk-replace replacer body)))))
@@ -1249,10 +1249,10 @@
(spaced (list "abstract"
name
(privacy-modifier$ pm)
- (with-brackets (spaced (list/map annotation$ anns)))
- (with-brackets (spaced (list/map type-param$ type-vars)))
- (with-brackets (spaced (list/map generic-type$ exs)))
- (with-brackets (spaced (list/map arg-decl$ arg-decls)))
+ (with-brackets (spaced (list;map annotation$ anns)))
+ (with-brackets (spaced (list;map type-param$ type-vars)))
+ (with-brackets (spaced (list;map generic-type$ exs)))
+ (with-brackets (spaced (list;map arg-decl$ arg-decls)))
(generic-type$ return-type))))
(#NativeMethod type-vars arg-decls return-type exs)
@@ -1260,10 +1260,10 @@
(spaced (list "native"
name
(privacy-modifier$ pm)
- (with-brackets (spaced (list/map annotation$ anns)))
- (with-brackets (spaced (list/map type-param$ type-vars)))
- (with-brackets (spaced (list/map generic-type$ exs)))
- (with-brackets (spaced (list/map arg-decl$ arg-decls)))
+ (with-brackets (spaced (list;map annotation$ anns)))
+ (with-brackets (spaced (list;map type-param$ type-vars)))
+ (with-brackets (spaced (list;map generic-type$ exs)))
+ (with-brackets (spaced (list;map arg-decl$ arg-decls)))
(generic-type$ return-type))))
))
@@ -1325,19 +1325,19 @@
(do macro.monad
[current-module macro.current-module-name
#let [fully-qualified-class-name (format (sanitize current-module) "." full-class-name)
- field-parsers (list/map (field->parser fully-qualified-class-name) fields)
- method-parsers (list/map (method->parser (product.right class-decl) fully-qualified-class-name) methods)
- replacer (parser->replacer (list/fold p.either
+ field-parsers (list;map (field->parser fully-qualified-class-name) fields)
+ method-parsers (list;map (method->parser (product.right class-decl) fully-qualified-class-name) methods)
+ replacer (parser->replacer (list;fold p.either
(p.fail "")
- (list/compose field-parsers method-parsers)))
+ (list;compose field-parsers method-parsers)))
def-code (format "jvm class:"
(spaced (list (class-decl$ class-decl)
(super-class-decl$ super)
- (with-brackets (spaced (list/map super-class-decl$ interfaces)))
+ (with-brackets (spaced (list;map super-class-decl$ interfaces)))
(inheritance-modifier$ im)
- (with-brackets (spaced (list/map annotation$ annotations)))
- (with-brackets (spaced (list/map field-decl$ fields)))
- (with-brackets (spaced (list/map (method-def$ replacer super) methods))))))]]
+ (with-brackets (spaced (list;map annotation$ annotations)))
+ (with-brackets (spaced (list;map field-decl$ fields)))
+ (with-brackets (spaced (list;map (method-def$ replacer super) methods))))))]]
(wrap (list (` ((~ (code.text def-code))))))))
(syntax: #export (interface:
@@ -1356,9 +1356,9 @@
([] foo [boolean String] void #throws [Exception])))}
(let [def-code (format "jvm interface:"
(spaced (list (class-decl$ class-decl)
- (with-brackets (spaced (list/map super-class-decl$ supers)))
- (with-brackets (spaced (list/map annotation$ annotations)))
- (spaced (list/map method-decl$ members)))))]
+ (with-brackets (spaced (list;map super-class-decl$ supers)))
+ (with-brackets (spaced (list;map annotation$ annotations)))
+ (spaced (list;map method-decl$ members)))))]
(wrap (list (` ((~ (code.text def-code))))))
))
@@ -1384,9 +1384,9 @@
)}
(let [def-code (format "jvm anon-class:"
(spaced (list (super-class-decl$ super)
- (with-brackets (spaced (list/map super-class-decl$ interfaces)))
- (with-brackets (spaced (list/map constructor-arg$ constructor-args)))
- (with-brackets (spaced (list/map (method-def$ function.identity super) methods))))))]
+ (with-brackets (spaced (list;map super-class-decl$ interfaces)))
+ (with-brackets (spaced (list;map constructor-arg$ constructor-args)))
+ (with-brackets (spaced (list;map (method-def$ function.identity super) methods))))))]
(wrap (list (` ((~ (code.text def-code))))))))
(syntax: #export (null)
@@ -1484,7 +1484,7 @@
(ClassName::method2 arg3 arg4 arg5)))}
(with-gensyms [g!obj]
(wrap (list (` (let [(~ g!obj) (~ obj)]
- (exec (~+ (list/map (complete-call$ g!obj) methods))
+ (exec (~+ (list;map (complete-call$ g!obj) methods))
(~ g!obj))))))))
(def: (class-import$ long-name? [full-name params])
@@ -1492,7 +1492,7 @@
(let [def-name (if long-name?
full-name
(short-class-name full-name))
- params' (list/map (|>> product.left code.local-identifier) params)]
+ params' (list;map (|>> product.left code.local-identifier) params)]
(` (def: (~ (code.identifier ["" def-name]))
{#.type? #1
#..jvm-class (~ (code.text full-name))}
@@ -1505,7 +1505,7 @@
(-> (List Type-Paramameter) Import-Member-Declaration (List Type-Paramameter))
(case member
(#ConstructorDecl [commons _])
- (list/compose class-tvars (get@ #import-member-tvars commons))
+ (list;compose class-tvars (get@ #import-member-tvars commons))
(#MethodDecl [commons _])
(case (get@ #import-member-kind commons)
@@ -1513,7 +1513,7 @@
(get@ #import-member-tvars commons)
_
- (list/compose class-tvars (get@ #import-member-tvars commons)))
+ (list;compose class-tvars (get@ #import-member-tvars commons)))
_
class-tvars))
@@ -1531,9 +1531,9 @@
(wrap [maybe? arg-name]))))
import-member-args)
#let [arg-classes (: (List Text)
- (list/map (|>> product.right (simple-class$ (list/compose type-params import-member-tvars)))
+ (list;map (|>> product.right (simple-class$ (list;compose type-params import-member-tvars)))
import-member-args))
- arg-types (list/map (: (-> [Bit GenericType] Code)
+ arg-types (list;map (: (-> [Bit GenericType] Code)
(function (_ [maybe? arg])
(let [arg-type (class->type (get@ #import-member-mode commons) type-params arg)]
(if maybe?
@@ -1613,12 +1613,12 @@
(def: (jvm-extension-inputs mode classes inputs)
(-> Primitive-Mode (List Text) (List [Bit Code]) (List Code))
(|> inputs
- (list/map (function (_ [maybe? input])
+ (list;map (function (_ [maybe? input])
(if maybe?
(` ((~! !!!) (~ (un-quote input))))
(un-quote input))))
(list.zip2 classes)
- (list/map (auto-convert-input mode))))
+ (list;map (auto-convert-input mode))))
(def: (member-def-interop type-params kind class [arg-function-inputs arg-classes arg-types] member method-prefix)
(-> (List Type-Paramameter) Class-Kind Class-Declaration [(List [Bit Code]) (List Text) (List Code)] Import-Member-Declaration Text (Meta (List Code)))
@@ -1626,7 +1626,7 @@
full-name (sanitize full-name)
all-params (|> (member-type-vars class-tvars member)
(list.filter free-type-param?)
- (list/map type-param->type-arg))]
+ (list;map type-param->type-arg))]
(case member
(#EnumDecl enum-members)
(do macro.monad
@@ -1638,7 +1638,7 @@
_
(let [=class-tvars (|> class-tvars
(list.filter free-type-param?)
- (list/map type-param->type-arg))]
+ (list;map type-param->type-arg))]
(` (All [(~+ =class-tvars)] (primitive (~ (code.text full-name)) [(~+ =class-tvars)]))))))
getter-interop (: (-> Text Code)
(function (_ name)
@@ -1646,7 +1646,7 @@
(` (def: (~ getter-name)
(~ enum-type)
((~ (code.text (format "jvm getstatic" ":" full-name ":" name)))))))))]]
- (wrap (list/map getter-interop enum-members)))
+ (wrap (list;map getter-interop enum-members)))
(#ConstructorDecl [commons _])
(do macro.monad
@@ -1657,7 +1657,7 @@
(decorate-return-maybe member)
(decorate-return-try member)
(decorate-return-io member))]]
- (wrap (list (` ((~! syntax:) ((~ def-name) (~+ (list/map product.right arg-function-inputs)))
+ (wrap (list (` ((~! syntax:) ((~ def-name) (~+ (list;map product.right arg-function-inputs)))
((~' wrap) (.list (.` (~ jvm-interop)))))))))
(#MethodDecl [commons method])
@@ -1687,13 +1687,13 @@
)))
jvm-extension (code.text (format "jvm " jvm-op ":" full-name ":" import-method-name ":" (text.join-with "," arg-classes)))
jvm-interop (|> [(simple-class$ (list) (get@ #import-method-return method))
- (` ((~ jvm-extension) (~+ (list/map un-quote object-ast))
+ (` ((~ jvm-extension) (~+ (list;map un-quote object-ast))
(~+ (jvm-extension-inputs (get@ #import-member-mode commons) arg-classes arg-function-inputs))))]
(auto-convert-output (get@ #import-member-mode commons))
(decorate-return-maybe member)
(decorate-return-try member)
(decorate-return-io member))]]
- (wrap (list (` ((~! syntax:) ((~ def-name) (~+ (list/map product.right arg-function-inputs)) (~+ object-ast))
+ (wrap (list (` ((~! syntax:) ((~ def-name) (~+ (list;map product.right arg-function-inputs)) (~+ object-ast))
((~' wrap) (.list (.` (~ jvm-interop))))))))))
(#FieldAccessDecl fad)
@@ -1707,7 +1707,7 @@
tvar-asts (: (List Code)
(|> class-tvars
(list.filter free-type-param?)
- (list/map type-param->type-arg)))
+ (list;map type-param->type-arg)))
getter-name (code.identifier ["" (format method-prefix member-separator import-field-name)])
setter-name (code.identifier ["" (format method-prefix member-separator import-field-name "!")])]
getter-interop (with-gensyms [g!obj]
@@ -1839,7 +1839,7 @@
(do macro.monad
[kind (class-kind class-decl)
=members (monad.map @ (member-import$ (product.right class-decl) long-name? kind class-decl) members)]
- (wrap (list& (class-import$ long-name? class-decl) (list/join =members)))))
+ (wrap (list& (class-import$ long-name? class-decl) (list;join =members)))))
(syntax: #export (array {#let [imports (class-imports *compiler*)]}
{type (generic-type^ imports (list))}
@@ -1869,7 +1869,7 @@
(def: (type->class-name type)
(-> Type (Meta Text))
- (if (type/= Any type)
+ (if (type;= Any type)
(:: macro.monad wrap "java.lang.Object")
(case type
(#.Primitive name params)
@@ -1963,10 +1963,10 @@
bar (do-something-else my-res2)]
(do-one-last-thing foo bar))))}
(with-gensyms [g!output g!_]
- (let [inits (list/join (list/map (function (_ [res-name res-ctor])
+ (let [inits (list;join (list;map (function (_ [res-name res-ctor])
(list (code.identifier ["" res-name]) res-ctor))
bindings))
- closes (list/map (function (_ res)
+ closes (list;map (function (_ res)
(` (try ("jvm invokevirtual:java.io.Closeable:close:" (~ (code.identifier ["" (product.left res)]))))))
bindings)]
(wrap (list (` (do (~! io.monad)
diff --git a/stdlib/source/lux/host/js.lux b/stdlib/source/lux/host/js.lux
index 05778db9f..bb52784a1 100644
--- a/stdlib/source/lux/host/js.lux
+++ b/stdlib/source/lux/host/js.lux
@@ -6,7 +6,7 @@
["." text
format]
[collection
- ["." list ("#/." functor fold)]]]
+ ["." list ("#;." functor fold)]]]
[macro
["." template]]
[type
@@ -93,7 +93,7 @@
(def: #export array
(-> (List Expression) Computation)
- (|>> (list/map ..code)
+ (|>> (list;map ..code)
(text.join-with ..argument-separator)
..element
:abstraction))
@@ -115,7 +115,7 @@
(def: #export (apply/* function inputs)
(-> Expression (List Expression) Computation)
(|> inputs
- (list/map ..code)
+ (list;map ..code)
(text.join-with ..argument-separator)
..argument
(format (:representation function))
@@ -148,7 +148,7 @@
(def: #export object
(-> (List [Text Expression]) Computation)
- (|>> (list/map (.function (_ [key val])
+ (|>> (list;map (.function (_ [key val])
(format (:representation (..string key)) ..field-separator (:representation val))))
(text.join-with ..argument-separator)
(text.enclose ["{" "}"])
@@ -186,7 +186,7 @@
..block
(format "function " (:representation name)
(|> inputs
- (list/map ..code)
+ (list;map ..code)
(text.join-with ..argument-separator)
..argument)
" ")
@@ -199,7 +199,7 @@
..block
(format "function"
(|> inputs
- (list/map ..code)
+ (list;map ..code)
(text.join-with ..argument-separator)
..argument)
" ")
@@ -270,7 +270,7 @@
(-> Expression (List Expression) Computation)
(|> (format "new " (:representation constructor)
(|> inputs
- (list/map ..code)
+ (list;map ..code)
(text.join-with ..argument-separator)
..argument))
..argument
@@ -363,7 +363,7 @@
(def: #export (cond clauses else!)
(-> (List [Expression Statement]) Statement Statement)
- (list/fold (.function (_ [test then!] next!)
+ (list;fold (.function (_ [test then!] next!)
(..if test then! next!))
else!
(list.reverse clauses)))
diff --git a/stdlib/source/lux/host/jvm/constant.lux b/stdlib/source/lux/host/jvm/constant.lux
index cf8d2e1fc..0d6bbcbfe 100644
--- a/stdlib/source/lux/host/jvm/constant.lux
+++ b/stdlib/source/lux/host/jvm/constant.lux
@@ -10,13 +10,13 @@
["." frac]]
["." text]
[format
- ["." binary (#+ Format) ("#/." monoid)]]
+ ["." binary (#+ Format) ("#;." monoid)]]
[collection
["." row (#+ Row)]]]
[type
abstract]]
["." / #_
- ["#." tag ("#/." equivalence)]
+ ["#." tag ("#;." equivalence)]
["." // #_
[encoding (#+ U4)]
[descriptor (#+ Descriptor)]
@@ -174,7 +174,7 @@
{#binary.reader (do parser.monad
[tag (get@ #binary.reader /tag.format)]
(`` (cond (~~ (do-template [<case> <tag> <format>]
- [(/tag/= <tag> tag)
+ [(/tag;= <tag> tag)
(:: @ map (|>> <case>) (get@ #binary.reader <format>))]
<constants>))
@@ -185,7 +185,7 @@
(case value
(^template [<case> <tag> <format>]
(<case> value)
- (binary/compose ((get@ #binary.writer /tag.format) <tag>)
+ (binary;compose ((get@ #binary.writer /tag.format) <tag>)
((get@ #binary.writer <format>) value)))
(<constants>)
))}))
diff --git a/stdlib/source/lux/host/jvm/constant/pool.lux b/stdlib/source/lux/host/jvm/constant/pool.lux
index c72edbac7..846c0fa18 100644
--- a/stdlib/source/lux/host/jvm/constant/pool.lux
+++ b/stdlib/source/lux/host/jvm/constant/pool.lux
@@ -5,15 +5,15 @@
[monad (#+ do)]
["." state (#+ State)]]
[data
- ["." text ("#/." equivalence)]
+ ["." text ("#;." equivalence)]
[format
["." binary (#+ Format)]]
[collection
- ["." list ("#/." fold)]
+ ["." list ("#;." fold)]
["." row (#+ Row)]]]
[type
abstract]]
- ["." // (#+ UTF8 Class Constant) ("#/." class-equivalence)
+ ["." // (#+ UTF8 Class Constant) ("#;." class-equivalence)
[//
["." encoding]
["." index (#+ Index)]
@@ -50,11 +50,11 @@
(def: #export (utf8 value)
(-> UTF8 (State Pool (Index UTF8)))
- (!add value #//.UTF8 text/=))
+ (!add value #//.UTF8 text;=))
(def: (class' value)
(-> Class (State Pool (Index Class)))
- (!add value #//.Class ///=))
+ (!add value #//.Class //;=))
(def: #export (class name)
(-> UTF8 (State Pool (Index Class)))
@@ -67,7 +67,7 @@
(-> (Descriptor kind)
(State Pool (Index (Descriptor kind)))))
(let [value (descriptor.descriptor value)]
- (!add value #//.UTF8 text/=)))
+ (!add value #//.UTF8 text;=)))
(def: #export format
(Format Pool)
diff --git a/stdlib/source/lux/host/jvm/descriptor.lux b/stdlib/source/lux/host/jvm/descriptor.lux
index 82a1c8ff8..1647e32ea 100644
--- a/stdlib/source/lux/host/jvm/descriptor.lux
+++ b/stdlib/source/lux/host/jvm/descriptor.lux
@@ -4,7 +4,7 @@
["." text
format]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
[type
abstract]]
["." // #_
@@ -73,7 +73,7 @@
(Descriptor Method))
(:abstraction
(format (|> inputs
- (list/map (|>> :representation))
+ (list;map (|>> :representation))
(text.join-with "")
(text.enclose ["(" ")"]))
(:representation output))))
diff --git a/stdlib/source/lux/host/jvm/encoding.lux b/stdlib/source/lux/host/jvm/encoding.lux
index 203c06560..08213e268 100644
--- a/stdlib/source/lux/host/jvm/encoding.lux
+++ b/stdlib/source/lux/host/jvm/encoding.lux
@@ -2,7 +2,7 @@
[lux #*
[control
[equivalence (#+ Equivalence)]
- ["." parser ("#/." functor)]]
+ ["." parser ("#;." functor)]]
[data
[number
["." i64]]
diff --git a/stdlib/source/lux/host/jvm/loader.jvm.lux b/stdlib/source/lux/host/jvm/loader.jvm.lux
index d04a7e82f..03edd60cf 100644
--- a/stdlib/source/lux/host/jvm/loader.jvm.lux
+++ b/stdlib/source/lux/host/jvm/loader.jvm.lux
@@ -11,7 +11,7 @@
format]
[collection
["." array]
- ["." list ("#/." functor)]
+ ["." list ("#;." functor)]
["." dictionary (#+ Dictionary)]]]
["." io (#+ IO)]
[world
@@ -27,7 +27,7 @@
(exception: #export (unknown {class Text} {known-classes (List Text)})
(ex.report ["Class" class]
["Known classes" (|> known-classes
- (list/map (|>> (format text.new-line text.tab)))
+ (list;map (|>> (format text.new-line text.tab)))
(text.join-with ""))]))
(exception: #export (cannot-define {class Text} {error Text})
diff --git a/stdlib/source/lux/host/jvm/modifier.lux b/stdlib/source/lux/host/jvm/modifier.lux
index e41e5c5e1..cb535a96b 100644
--- a/stdlib/source/lux/host/jvm/modifier.lux
+++ b/stdlib/source/lux/host/jvm/modifier.lux
@@ -10,7 +10,7 @@
[format
["." binary]]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
[type
["." abstract]]
[macro (#+ with-gensyms)
@@ -59,7 +59,7 @@
(.|> ((~! number.hex) (~ g!<code>)) //encoding.to-u2 abstract.:abstraction))]
["0000" (~ g!empty)]
- (~+ (list/map ..code options))
+ (~+ (list;map ..code options))
)
(.structure: (~' #export) (~' modifier-equivalence) (equivalence.Equivalence (~ g!name))
@@ -70,12 +70,12 @@
(.def: (~' #export) (~ g!format)
(binary.Format (~ g!name))
- (.let [(.^open "_/.") //encoding.u2-format]
- {#binary.reader (|> (~' _/reader)
+ (.let [(.^open "_;.") //encoding.u2-format]
+ {#binary.reader (|> (~' _;reader)
(:: parser.functor (~' map)
(|>> abstract.:abstraction)))
#binary.writer (|>> abstract.:representation
- (~' _/writer))}))))
+ (~' _;writer))}))))
monoidC (` (.structure: (~' #export) (~' modifier-monoid) (monoid.Monoid (~ g!name))
(.def: (~' identity) (~ g!empty))
(.def: (~' compose) (~ g!combine))))]
diff --git a/stdlib/source/lux/host/scheme.lux b/stdlib/source/lux/host/scheme.lux
index 7194935e6..5a8741c78 100644
--- a/stdlib/source/lux/host/scheme.lux
+++ b/stdlib/source/lux/host/scheme.lux
@@ -9,7 +9,7 @@
["." text
format]
[collection
- ["." list ("#/." functor fold)]]]
+ ["." list ("#;." functor fold)]]]
[macro
["." template]]
[type
@@ -55,14 +55,14 @@
_
(|> (format " . " (:representation rest))
(format (|> vars
- (list/map ..code)
+ (list;map ..code)
(text.join-with " ")))
(text.enclose ["(" ")"])
:abstraction))
#.None
(|> vars
- (list/map ..code)
+ (list;map ..code)
(text.join-with " ")
(text.enclose ["(" ")"])
:abstraction)))
@@ -130,7 +130,7 @@
(def: form
(-> (List (Code Any)) Text)
- (|>> (list/map ..code)
+ (|>> (list;map ..code)
(text.join-with " ")
(text.enclose ["(" ")"])))
@@ -250,7 +250,7 @@
(:abstraction
(..form (list (..global <scheme-name>)
(|> bindings
- (list/map (.function (_ [binding/name binding/value])
+ (list;map (.function (_ [binding/name binding/value])
(:abstraction
(..form (list (<pre> binding/name)
binding/value)))))
@@ -278,7 +278,7 @@
(def: #export (cond clauses else)
(-> (List [Expression Expression]) Expression Computation)
- (|> (list/fold (.function (_ [test then] next)
+ (|> (list;fold (.function (_ [test then] next)
(if test then next))
else
(list.reverse clauses))
diff --git a/stdlib/source/lux/macro.lux b/stdlib/source/lux/macro.lux
index 870b905f4..2a9c55488 100644
--- a/stdlib/source/lux/macro.lux
+++ b/stdlib/source/lux/macro.lux
@@ -6,14 +6,14 @@
["." monad (#+ Monad do)]]
[data
["." product]
- ["." name ("#/." codec equivalence)]
+ ["." name ("#;." codec equivalence)]
["." maybe]
["." error (#+ Error)]
[number
- ["." nat ("#/." decimal)]]
- ["." text ("#/." monoid equivalence)]
+ ["." nat ("#;." decimal)]]
+ ["." text ("#;." monoid equivalence)]
[collection
- ["." list ("#/." monoid monad)]]]]
+ ["." list ("#;." monoid monad)]]]]
[/
["." code]])
@@ -71,7 +71,7 @@
#.None
(#.Cons [k' v] plist')
- (if (text/= k k')
+ (if (text;= k k')
(#.Some v)
(get k plist'))))
@@ -122,7 +122,7 @@
(#error.Success [compiler module])
_
- (#error.Failure ($_ text/compose "Unknown module: " name)))))
+ (#error.Failure ($_ text;compose "Unknown module: " name)))))
(def: #export current-module-name
(Meta Text)
@@ -151,7 +151,7 @@
(#.Cons [key value] anns')
(case key
[_ (#.Tag tag')]
- (if (name/= tag tag')
+ (if (name;= tag tag')
(#.Some value)
(recur anns'))
@@ -197,7 +197,7 @@
(do-template [<name> <tag> <desc>]
[(def: #export <name>
- {#.doc (code.text ($_ text/compose "Checks whether a definition is " <desc> "."))}
+ {#.doc (code.text ($_ text;compose "Checks whether a definition is " <desc> "."))}
(-> Code Bit)
(flag-set? (name-of <tag>)))]
@@ -255,7 +255,7 @@
[def-type def-anns def-value] (: (Maybe Definition) (|> (: Module $module) (get@ #.definitions) (get name)))]
(if (and (macro? def-anns)
(or (export? def-anns)
- (text/= module this-module)))
+ (text;= module this-module)))
(#.Some (:coerce Macro def-value))
(case (get-identifier-ann (name-of #.alias) def-anns)
(#.Some [r-module r-name])
@@ -317,7 +317,7 @@
(do ..monad
[expansion (macro args)
expansion' (monad.map ..monad expand expansion)]
- (wrap (list/join expansion')))
+ (wrap (list;join expansion')))
#.None
(:: ..monad wrap (list syntax))))
@@ -337,23 +337,23 @@
(do ..monad
[expansion (macro args)
expansion' (monad.map ..monad expand-all expansion)]
- (wrap (list/join expansion')))
+ (wrap (list;join expansion')))
#.None
(do ..monad
[parts' (monad.map ..monad expand-all (list& (code.identifier name) args))]
- (wrap (list (code.form (list/join parts')))))))
+ (wrap (list (code.form (list;join parts')))))))
[_ (#.Form (#.Cons [harg targs]))]
(do ..monad
[harg+ (expand-all harg)
targs+ (monad.map ..monad expand-all targs)]
- (wrap (list (code.form (list/compose harg+ (list/join (: (List (List Code)) targs+)))))))
+ (wrap (list (code.form (list;compose harg+ (list;join (: (List (List Code)) targs+)))))))
[_ (#.Tuple members)]
(do ..monad
[members' (monad.map ..monad expand-all members)]
- (wrap (list (code.tuple (list/join members')))))
+ (wrap (list (code.tuple (list;join members')))))
_
(:: ..monad wrap (list syntax))))
@@ -373,7 +373,7 @@
(|> compiler
(get@ #.seed)
(:: nat.decimal encode)
- ($_ text/compose "__gensym__" prefix)
+ ($_ text;compose "__gensym__" prefix)
[""] code.identifier)])))
(def: (get-local-identifier ast)
@@ -383,12 +383,12 @@
(:: ..monad wrap name)
_
- (fail (text/compose "Code is not a local identifier: " (code.to-text ast)))))
+ (fail (text;compose "Code is not a local identifier: " (code.to-text ast)))))
(def: #export wrong-syntax-error
(-> Name Text)
- (|>> name/encode
- (text/compose "Wrong syntax for ")))
+ (|>> name;encode
+ (text;compose "Wrong syntax for ")))
(macro: #export (with-gensyms tokens)
{#.doc (doc "Creates new identifiers and offers them to the body expression."
@@ -404,7 +404,7 @@
(^ (list [_ (#.Tuple identifiers)] body))
(do ..monad
[identifier-names (monad.map @ get-local-identifier identifiers)
- #let [identifier-defs (list/join (list/map (: (-> Text (List Code))
+ #let [identifier-defs (list;join (list;map (: (-> Text (List Code))
(function (_ name) (list (code.identifier ["" name]) (` (gensym (~ (code.text name)))))))
identifier-names))]]
(wrap (list (` ((~! do) (~! ..monad)
@@ -476,7 +476,7 @@
(-> Text (Meta Type))
(function (_ compiler)
(let [test (: (-> [Text [Type Any]] Bit)
- (|>> product.left (text/= name)))]
+ (|>> product.left (text;= name)))]
(case (do maybe.monad
[scope (list.find (function (_ env)
(or (list.any? test (: (List [Text [Type Any]])
@@ -494,7 +494,7 @@
((clean-type var-type) compiler)
#.None
- (#error.Failure ($_ text/compose "Unknown variable: " name))))))
+ (#error.Failure ($_ text;compose "Unknown variable: " name))))))
(def: #export (find-def name)
{#.doc "Looks-up a definition's whole data in the available modules (including the current one)."}
@@ -512,18 +512,18 @@
_
(let [current-module (|> compiler (get@ #.current-module) (maybe.default "???"))]
- (#error.Failure ($_ text/compose
- "Unknown definition: " (name/encode name) text.new-line
+ (#error.Failure ($_ text;compose
+ "Unknown definition: " (name;encode name) text.new-line
" Current module: " current-module text.new-line
(case (get current-module (get@ #.modules compiler))
(#.Some this-module)
- ($_ text/compose
+ ($_ text;compose
" Imports: " (|> this-module (get@ #.imports) (text.join-with ", ")) text.new-line
- " Aliases: " (|> this-module (get@ #.module-aliases) (list/map (function (_ [alias real]) ($_ text/compose alias " => " real))) (text.join-with ", ")) text.new-line)
+ " Aliases: " (|> this-module (get@ #.module-aliases) (list;map (function (_ [alias real]) ($_ text;compose alias " => " real))) (text.join-with ", ")) text.new-line)
_
"")
- " All Known modules: " (|> compiler (get@ #.modules) (list/map product.left) (text.join-with ", ")) text.new-line)))))))
+ " All Known modules: " (|> compiler (get@ #.modules) (list;map product.left) (text.join-with ", ")) text.new-line)))))))
(def: #export (find-def-type name)
{#.doc "Looks-up a definition's type in the available modules (including the current one)."}
@@ -557,7 +557,7 @@
(-> Text (Meta (List [Text Definition])))
(function (_ compiler)
(case (get module-name (get@ #.modules compiler))
- #.None (#error.Failure ($_ text/compose "Unknown module: " module-name))
+ #.None (#error.Failure ($_ text;compose "Unknown module: " module-name))
(#.Some module) (#error.Success [compiler (get@ #.definitions module)])
)))
@@ -620,14 +620,14 @@
(-> Text Text (Meta Bit))
(do ..monad
[(^slots [#.imports]) (find-module module)]
- (wrap (list.any? (text/= import) imports))))
+ (wrap (list.any? (text;= import) imports))))
(def: #export (imported? import)
(-> Text (Meta Bit))
(let [(^open ".") ..monad]
(|> current-module-name
(map find-module) join
- (map (|>> (get@ #.imports) (list.any? (text/= import)))))))
+ (map (|>> (get@ #.imports) (list.any? (text;= import)))))))
(def: #export (resolve-tag tag)
{#.doc "Given a tag, finds out what is its index, its related tag-list and it's associated type."}
@@ -639,13 +639,13 @@
imported! (..imported? module)]
(case (get name (get@ #.tags =module))
(#.Some [idx tag-list exported? type])
- (if (or (text/= this-module-name module)
+ (if (or (text;= this-module-name module)
(and imported! exported?))
(wrap [idx tag-list type])
- (fail ($_ text/compose "Cannot access tag: " (name/encode tag) " from module " this-module-name)))
+ (fail ($_ text;compose "Cannot access tag: " (name;encode tag) " from module " this-module-name)))
_
- (fail ($_ text/compose "Unknown tag: " (name/encode tag))))))
+ (fail ($_ text;compose "Unknown tag: " (name;encode tag))))))
(def: #export (tag-lists module)
{#.doc "All the tag-lists defined in a module, with their associated types."}
@@ -656,8 +656,8 @@
(wrap (|> (get@ #.types =module)
(list.filter (function (_ [type-name [tag-list exported? type]])
(or exported?
- (text/= this-module-name module))))
- (list/map (function (_ [type-name [tag-list exported? type]])
+ (text;= this-module-name module))))
+ (list;map (function (_ [type-name [tag-list exported? type]])
[tag-list type]))))))
(def: #export locals
@@ -670,8 +670,8 @@
(#.Some scopes)
(#error.Success [compiler
- (list/map (|>> (get@ [#.locals #.mappings])
- (list/map (function (_ [name [type _]])
+ (list;map (|>> (get@ [#.locals #.mappings])
+ (list;map (function (_ [name [type _]])
[name type])))
scopes)]))))
@@ -722,8 +722,8 @@
(do ..monad
[cursor ..cursor
output (<func> token)
- #let [_ (log! ($_ text/compose (name/encode (name-of <macro>)) " @ " (.cursor-description cursor)))
- _ (list/map (|>> code.to-text log!)
+ #let [_ (log! ($_ text;compose (name;encode (name-of <macro>)) " @ " (.cursor-description cursor)))
+ _ (list;map (|>> code.to-text log!)
output)
_ (log! "")]]
(wrap (if omit?
diff --git a/stdlib/source/lux/macro/code.lux b/stdlib/source/lux/macro/code.lux
index 34bd2b534..b986c02f4 100644
--- a/stdlib/source/lux/macro/code.lux
+++ b/stdlib/source/lux/macro/code.lux
@@ -10,9 +10,9 @@
["." int]
["." rev]
["." frac]]
- ["." text ("#/." monoid)]
+ ["." text ("#;." monoid)]
[collection
- ["." list ("#/." functor fold)]]]])
+ ["." list ("#;." functor fold)]]]])
## (type: (Code' w)
## (#.Bit Bit)
@@ -103,14 +103,14 @@
(text.encode value)
[_ (#.Tag name)]
- (text/compose "#" (:: name.codec encode name))
+ (text;compose "#" (:: name.codec encode name))
(^template [<tag> <open> <close>]
[_ (<tag> members)]
- ($_ text/compose
+ ($_ text;compose
<open>
(|> members
- (list/map to-text)
+ (list;map to-text)
(list.interpose " ")
(text.join-with ""))
<close>))
@@ -118,11 +118,11 @@
[#.Tuple "[" "]"])
[_ (#.Record pairs)]
- ($_ text/compose
+ ($_ text;compose
"{"
(|> pairs
- (list/map (function (_ [left right])
- ($_ text/compose (to-text left) " " (to-text right))))
+ (list;map (function (_ [left right])
+ ($_ text;compose (to-text left) " " (to-text right))))
(list.interpose " ")
(text.join-with ""))
"}")
@@ -136,12 +136,12 @@
(case ast
(^template [<tag>]
[cursor (<tag> parts)]
- [cursor (<tag> (list/map (replace original substitute) parts))])
+ [cursor (<tag> (list;map (replace original substitute) parts))])
([#.Form]
[#.Tuple])
[cursor (#.Record parts)]
- [cursor (#.Record (list/map (function (_ [left right])
+ [cursor (#.Record (list;map (function (_ [left right])
[(replace original substitute left)
(replace original substitute right)])
parts))]
diff --git a/stdlib/source/lux/macro/poly.lux b/stdlib/source/lux/macro/poly.lux
index a683fe50a..aefdea082 100644
--- a/stdlib/source/lux/macro/poly.lux
+++ b/stdlib/source/lux/macro/poly.lux
@@ -10,14 +10,14 @@
["." product]
["." bit]
["." maybe]
- ["." name ("#/." codec)]
+ ["." name ("#;." codec)]
["." error (#+ Error)]
["." number (#+ hex)
- ["." nat ("#/." decimal)]]
- ["." text ("#/." monoid)
+ ["." nat ("#;." decimal)]]
+ ["." text ("#;." monoid)
format]
[collection
- ["." list ("#/." fold monad monoid)]
+ ["." list ("#;." fold monad monoid)]
["dict" dictionary (#+ Dictionary)]]]
["." macro (#+ with-gensyms)
["." code]
@@ -26,7 +26,7 @@
["cs" common
["csr" reader]
["csw" writer]]]]
- ["." type ("#/." equivalence)
+ ["." type ("#;." equivalence)
["." check]]])
(do-template [<name>]
@@ -56,7 +56,7 @@
(exception: #export (unconsumed {remaining (List Type)})
(ex.report ["Types" (|> remaining
- (list/map (|>> %type (format text.new-line "* ")))
+ (list;map (|>> %type (format text.new-line "* ")))
(text.join-with ""))]))
(type: #export Env (Dictionary Nat [Type Code]))
@@ -131,7 +131,7 @@
(def: (label idx)
(-> Nat Code)
- (code.local-identifier ($_ text/compose "label" text.tab (nat/encode idx))))
+ (code.local-identifier ($_ text;compose "label" text.tab (nat;encode idx))))
(def: #export (with-extension type poly)
(All [a] (-> Type (Poly a) (Poly [Code a])))
@@ -193,7 +193,7 @@
partial-varI (inc partialI)
partial-varL (label partial-varI)
partialC (` ((~ funcL) (~+ (|> (list.indices num-args)
- (list/map (|>> (n/* 2) inc (n/+ funcI) label))
+ (list;map (|>> (n/* 2) inc (n/+ funcI) label))
list.reverse))))]
(recur (inc current-arg)
(|> env'
@@ -235,7 +235,7 @@
(wrap [])
(p.fail (ex.construct types-do-not-match [expected actual])))))]
- [exactly type/=]
+ [exactly type;=]
[sub check.checks?]
[super (function.flip check.checks?)]
)
@@ -346,8 +346,8 @@
(All [a] (Poly a))
(do p.monad
[current any
- #let [_ (log! ($_ text/compose
- "{" (name/encode (name-of ..log)) "} "
+ #let [_ (log! ($_ text;compose
+ "{" (name;encode (name-of ..log)) "} "
(%type current)))]]
(p.fail "LOGGING")))
@@ -378,7 +378,7 @@
(def: (derivation-name poly args)
(-> Text (List Text) (Maybe Text))
(if (common-poly-name? poly)
- (#.Some (list/fold (text.replace-once "?") poly args))
+ (#.Some (list;fold (text.replace-once "?") poly args))
#.None))
(syntax: #export (derived: {export csr.export}
@@ -392,7 +392,7 @@
(wrap name)
(^multi #.None
- [(derivation-name (product.right poly-func) (list/map product.right poly-args))
+ [(derivation-name (product.right poly-func) (list;map product.right poly-args))
(#.Some derived-name)])
(wrap derived-name)
@@ -403,7 +403,7 @@
custom-impl
#.None
- (` ((~ (code.identifier poly-func)) (~+ (list/map code.identifier poly-args)))))]]
+ (` ((~ (code.identifier poly-func)) (~+ (list;map code.identifier poly-args)))))]]
(wrap (.list (` (def: (~+ (csw.export export))
(~ (code.identifier ["" name]))
{#.struct? #1}
@@ -414,7 +414,7 @@
(case type
(#.Primitive name params)
(` (#.Primitive (~ (code.text name))
- (list (~+ (list/map (to-code env) params)))))
+ (list (~+ (list;map (to-code env) params)))))
(^template [<tag>]
(<tag> idx)
@@ -441,7 +441,7 @@
(^template [<tag> <macro> <flattener>]
(<tag> left right)
- (` (<macro> (~+ (list/map (to-code env) (<flattener> type))))))
+ (` (<macro> (~+ (list;map (to-code env) (<flattener> type))))))
([#.Sum | type.flatten-variant]
[#.Product & type.flatten-tuple])
@@ -450,7 +450,7 @@
(^template [<tag>]
(<tag> scope body)
- (` (<tag> (list (~+ (list/map (to-code env) scope)))
+ (` (<tag> (list (~+ (list;map (to-code env) scope)))
(~ (to-code env body)))))
([#.UnivQ] [#.ExQ])
))
diff --git a/stdlib/source/lux/macro/poly/equivalence.lux b/stdlib/source/lux/macro/poly/equivalence.lux
index ae8374443..cd826661c 100644
--- a/stdlib/source/lux/macro/poly/equivalence.lux
+++ b/stdlib/source/lux/macro/poly/equivalence.lux
@@ -9,14 +9,14 @@
["." bit]
["." maybe]
[number
- ["." nat ("#/." codec)]
+ ["." nat ("#;." codec)]
["." int]
["." rev]
["." frac]]
- ["." text ("#/." monoid)
+ ["." text ("#;." monoid)
format]
[collection
- ["." list ("#/." monad)]
+ ["." list ("#;." monad)]
["." row]
["." array]
["." queue]
@@ -109,7 +109,7 @@
(wrap (` (: (~ (@Equivalence inputT))
(function ((~ g!_) (~ g!left) (~ g!right))
(case [(~ g!left) (~ g!right)]
- (~+ (list/join (list/map (function (_ [tag g!eq])
+ (~+ (list;join (list;map (function (_ [tag g!eq])
(list (` [((~ (code.nat tag)) (~ g!left))
((~ (code.nat tag)) (~ g!right))])
(` ((~ g!eq) (~ g!left) (~ g!right)))))
@@ -121,12 +121,12 @@
[g!eqs (poly.tuple (p.many Equivalence<?>))
#let [g!_ (code.local-identifier "_____________")
indices (list.indices (list.size g!eqs))
- g!lefts (list/map (|>> nat/encode (text/compose "left") code.local-identifier) indices)
- g!rights (list/map (|>> nat/encode (text/compose "right") code.local-identifier) indices)]]
+ g!lefts (list;map (|>> nat;encode (text;compose "left") code.local-identifier) indices)
+ g!rights (list;map (|>> nat;encode (text;compose "right") code.local-identifier) indices)]]
(wrap (` (: (~ (@Equivalence inputT))
(function ((~ g!_) [(~+ g!lefts)] [(~+ g!rights)])
(and (~+ (|> (list.zip3 g!eqs g!lefts g!rights)
- (list/map (function (_ [g!eq g!left g!right])
+ (list;map (function (_ [g!eq g!left g!right])
(` ((~ g!eq) (~ g!left) (~ g!right)))))))))))))
## Type recursion
(do @
@@ -146,7 +146,7 @@
(do @
[[funcC varsC bodyC] (poly.polymorphic Equivalence<?>)]
(wrap (` (: (All [(~+ varsC)]
- (-> (~+ (list/map (|>> (~) ((~! eq.Equivalence)) (`)) varsC))
+ (-> (~+ (list;map (|>> (~) ((~! eq.Equivalence)) (`)) varsC))
((~! eq.Equivalence) ((~ (poly.to-code *env* inputT)) (~+ varsC)))))
(function ((~ funcC) (~+ varsC))
(~ bodyC))))))
diff --git a/stdlib/source/lux/macro/poly/functor.lux b/stdlib/source/lux/macro/poly/functor.lux
index a1d4e040d..837c36fde 100644
--- a/stdlib/source/lux/macro/poly/functor.lux
+++ b/stdlib/source/lux/macro/poly/functor.lux
@@ -9,7 +9,7 @@
["." text
format]
[collection
- ["." list ("#/." monad monoid)]]]
+ ["." list ("#;." monad monoid)]]]
["." macro
["." code]
[syntax (#+ syntax: Syntax)
@@ -31,7 +31,7 @@
(function (_ unwrappedT)
(if (n/= 1 num-vars)
(` ((~! functor.Functor) (~ (poly.to-code *env* unwrappedT))))
- (let [paramsC (|> num-vars dec list.indices (list/map (|>> %n code.local-identifier)))]
+ (let [paramsC (|> num-vars dec list.indices (list;map (|>> %n code.local-identifier)))]
(` (All [(~+ paramsC)]
((~! functor.Functor) ((~ (poly.to-code *env* unwrappedT)) (~+ paramsC)))))))))
Arg<?> (: (-> Code (poly.Poly Code))
@@ -47,7 +47,7 @@
[_ (wrap [])
membersC (poly.variant (p.many (Arg<?> valueC)))]
(wrap (` (case (~ valueC)
- (~+ (list/join (list/map (function (_ [tag memberC])
+ (~+ (list;join (list;map (function (_ [tag memberC])
(list (` ((~ (code.nat tag)) (~ valueC)))
(` ((~ (code.nat tag)) (~ memberC)))))
(list.enumerate membersC))))))))
@@ -62,11 +62,11 @@
[_ (wrap [])
memberC (Arg<?> slotC)]
(recur (inc idx)
- (list/compose pairsCC (list [slotC memberC])))))
+ (list;compose pairsCC (list [slotC memberC])))))
(wrap pairsCC)))))]
(wrap (` (case (~ valueC)
- [(~+ (list/map product.left pairsCC))]
- [(~+ (list/map product.right pairsCC))]))))
+ [(~+ (list;map product.left pairsCC))]
+ [(~+ (list;map product.right pairsCC))]))))
## Functions
(do @
[_ (wrap [])
@@ -76,7 +76,7 @@
(Arg<?> outL))
#let [inC+ (|> (list.size inT+)
list.indices
- (list/map (|>> %n (format "____________inC") code.local-identifier)))]]
+ (list;map (|>> %n (format "____________inC") code.local-identifier)))]]
(wrap (` (function ((~ g!) (~+ inC+))
(let [(~ outL) ((~ valueC) (~+ inC+))]
(~ outC))))))
diff --git a/stdlib/source/lux/macro/poly/json.lux b/stdlib/source/lux/macro/poly/json.lux
index ce590b880..9fd7b5aae 100644
--- a/stdlib/source/lux/macro/poly/json.lux
+++ b/stdlib/source/lux/macro/poly/json.lux
@@ -13,16 +13,16 @@
["." product]
[number
["." i64]
- ["." nat ("#/." codec)]
- ["." frac ("#/." codec)]]
- ["." text ("#/." equivalence)
+ ["." nat ("#;." codec)]
+ ["." frac ("#;." codec)]]
+ ["." text ("#;." equivalence)
["l" lexer]
format]
[format
["/" json (#+ JSON)]]
[collection
- ["." list ("#/." fold monad)]
- ["." row (#+ Row row) ("#/." monad)]
+ ["." list ("#;." fold monad)]
+ ["." row (#+ Row row) ("#;." monad)]
["d" dictionary]]]
[time
## ["i" instant]
@@ -135,7 +135,7 @@
codec//encode))]
(wrap (` (: (~ (@JSON//encode inputT))
(|>> d.entries
- ((~! list/map) (function ((~ g!_) [(~ g!key) (~ g!val)])
+ ((~! list;map) (function ((~ g!_) [(~ g!key) (~ g!val)])
[(~ g!key) ((~ =val=) (~ g!val))]))
(d.from-list text.hash)
#/.Object)))))
@@ -150,7 +150,7 @@
(poly.exactly .List)
codec//encode))]
(wrap (` (: (~ (@JSON//encode inputT))
- (|>> ((~! list/map) (~ =sub=)) row.from-list #/.Array)))))
+ (|>> ((~! list;map) (~ =sub=)) row.from-list #/.Array)))))
(do @
[#let [g!_ (code.local-identifier "_______")
g!input (code.local-identifier "_______input")]
@@ -158,7 +158,7 @@
(wrap (` (: (~ (@JSON//encode inputT))
(function ((~ g!_) (~ g!input))
(case (~ g!input)
- (~+ (list/join (list/map (function (_ [tag g!encode])
+ (~+ (list;join (list;map (function (_ [tag g!encode])
(list (` ((~ (code.nat tag)) (~ g!input)))
(` (/.json [(~ (code.frac (..tag tag)))
((~ g!encode) (~ g!input))]))))
@@ -168,10 +168,10 @@
#let [g!_ (code.local-identifier "_______")
g!members (|> (list.size g!encoders)
list.indices
- (list/map (|>> nat/encode code.local-identifier)))]]
+ (list;map (|>> nat;encode code.local-identifier)))]]
(wrap (` (: (~ (@JSON//encode inputT))
(function ((~ g!_) [(~+ g!members)])
- (/.json [(~+ (list/map (function (_ [g!member g!encode])
+ (/.json [(~+ (list;map (function (_ [g!member g!encode])
(` ((~ g!encode) (~ g!member))))
(list.zip2 g!members g!encoders)))]))))))
## Type recursion
@@ -190,7 +190,7 @@
(do @
[[funcC varsC bodyC] (poly.polymorphic codec//encode)]
(wrap (` (: (All [(~+ varsC)]
- (-> (~+ (list/map (function (_ varC) (` (-> (~ varC) /.JSON)))
+ (-> (~+ (list;map (function (_ varC) (` (-> (~ varC) /.JSON)))
varsC))
(-> ((~ (poly.to-code *env* inputT)) (~+ varsC))
/.JSON)))
@@ -262,7 +262,7 @@
[members (poly.variant (p.many codec//decode))]
(wrap (` (: (~ (@JSON//decode inputT))
($_ p.or
- (~+ (list/map (function (_ [tag memberC])
+ (~+ (list;map (function (_ [tag memberC])
(` (|> (~ memberC)
(p.after (/.number! (~ (code.frac (..tag tag)))))
/.array)))
@@ -287,7 +287,7 @@
(do @
[[funcC varsC bodyC] (poly.polymorphic codec//decode)]
(wrap (` (: (All [(~+ varsC)]
- (-> (~+ (list/map (|>> (~) /.Reader (`)) varsC))
+ (-> (~+ (list;map (|>> (~) /.Reader (`)) varsC))
(/.Reader ((~ (poly.to-code *env* inputT)) (~+ varsC)))))
(function ((~ funcC) (~+ varsC))
(~ bodyC))))))
diff --git a/stdlib/source/lux/macro/syntax.lux b/stdlib/source/lux/macro/syntax.lux
index 449194d54..7afc3a8a6 100644
--- a/stdlib/source/lux/macro/syntax.lux
+++ b/stdlib/source/lux/macro/syntax.lux
@@ -14,11 +14,11 @@
["." int]
["." rev]
["." frac]]
- ["." text ("#/." monoid)]
+ ["." text ("#;." monoid)]
[collection
- ["." list ("#/." functor)]]]]
+ ["." list ("#;." functor)]]]]
["." // (#+ with-gensyms)
- ["." code ("#/." equivalence)]])
+ ["." code ("#;." equivalence)]])
(def: (join-pairs pairs)
(All [a] (-> (List [a a]) (List a)))
@@ -32,8 +32,8 @@
(def: (remaining-inputs asts)
(-> (List Code) Text)
- ($_ text/compose text.new-line "Remaining input: "
- (|> asts (list/map code.to-text) (list.interpose " ") (text.join-with ""))))
+ ($_ text;compose text.new-line "Remaining input: "
+ (|> asts (list;map code.to-text) (list.interpose " ") (text.join-with ""))))
(def: #export any
{#.doc "Just returns the next input without applying any logic."}
@@ -45,7 +45,7 @@
(do-template [<get-name> <type> <tag> <eq> <desc>]
[(def: #export <get-name>
- {#.doc (code.text ($_ text/compose "Parses the next " <desc> " input Code."))}
+ {#.doc (code.text ($_ text;compose "Parses the next " <desc> " input Code."))}
(Syntax <type>)
(function (_ tokens)
(case tokens
@@ -53,7 +53,7 @@
(#error.Success [tokens' x])
_
- (#error.Failure ($_ text/compose "Cannot parse " <desc> (remaining-inputs tokens))))))]
+ (#error.Failure ($_ text;compose "Cannot parse " <desc> (remaining-inputs tokens))))))]
[ bit Bit #.Bit bit.equivalence "bit"]
[ nat Nat #.Nat nat.equivalence "nat"]
@@ -71,7 +71,7 @@
(function (_ tokens)
(case tokens
(#.Cons [token tokens'])
- (let [is-it? (code/= ast token)
+ (let [is-it? (code;= ast token)
remaining (if is-it?
tokens'
tokens)]
@@ -86,9 +86,9 @@
(function (_ tokens)
(case tokens
(#.Cons [token tokens'])
- (if (code/= ast token)
+ (if (code;= ast token)
(#error.Success [tokens' []])
- (#error.Failure ($_ text/compose "Expected a " (code.to-text ast) " but instead got " (code.to-text token)
+ (#error.Failure ($_ text;compose "Expected a " (code.to-text ast) " but instead got " (code.to-text token)
(remaining-inputs tokens))))
_
@@ -96,7 +96,7 @@
(do-template [<name> <tag> <desc>]
[(def: #export <name>
- {#.doc (code.text ($_ text/compose "Parse a local " <desc> " (a " <desc> " that has no module prefix)."))}
+ {#.doc (code.text ($_ text;compose "Parse a local " <desc> " (a " <desc> " that has no module prefix)."))}
(Syntax Text)
(function (_ tokens)
(case tokens
@@ -104,7 +104,7 @@
(#error.Success [tokens' x])
_
- (#error.Failure ($_ text/compose "Cannot parse local " <desc> (remaining-inputs tokens))))))]
+ (#error.Failure ($_ text;compose "Cannot parse local " <desc> (remaining-inputs tokens))))))]
[local-identifier #.Identifier "identifier"]
[ local-tag #.Tag "tag"]
@@ -112,7 +112,7 @@
(do-template [<name> <tag> <desc>]
[(def: #export (<name> p)
- {#.doc (code.text ($_ text/compose "Parse inside the contents of a " <desc> " as if they were the input Codes."))}
+ {#.doc (code.text ($_ text;compose "Parse inside the contents of a " <desc> " as if they were the input Codes."))}
(All [a]
(-> (Syntax a) (Syntax a)))
(function (_ tokens)
@@ -120,17 +120,17 @@
(#.Cons [[_ (<tag> members)] tokens'])
(case (p members)
(#error.Success [#.Nil x]) (#error.Success [tokens' x])
- _ (#error.Failure ($_ text/compose "Syntax was expected to fully consume " <desc> (remaining-inputs tokens))))
+ _ (#error.Failure ($_ text;compose "Syntax was expected to fully consume " <desc> (remaining-inputs tokens))))
_
- (#error.Failure ($_ text/compose "Cannot parse " <desc> (remaining-inputs tokens))))))]
+ (#error.Failure ($_ text;compose "Cannot parse " <desc> (remaining-inputs tokens))))))]
[ form #.Form "form"]
[tuple #.Tuple "tuple"]
)
(def: #export (record p)
- {#.doc (code.text ($_ text/compose "Parse inside the contents of a record as if they were the input Codes."))}
+ {#.doc (code.text ($_ text;compose "Parse inside the contents of a record as if they were the input Codes."))}
(All [a]
(-> (Syntax a) (Syntax a)))
(function (_ tokens)
@@ -138,10 +138,10 @@
(#.Cons [[_ (#.Record pairs)] tokens'])
(case (p (join-pairs pairs))
(#error.Success [#.Nil x]) (#error.Success [tokens' x])
- _ (#error.Failure ($_ text/compose "Syntax was expected to fully consume record" (remaining-inputs tokens))))
+ _ (#error.Failure ($_ text;compose "Syntax was expected to fully consume record" (remaining-inputs tokens))))
_
- (#error.Failure ($_ text/compose "Cannot parse record" (remaining-inputs tokens))))))
+ (#error.Failure ($_ text;compose "Cannot parse record" (remaining-inputs tokens))))))
(def: #export end!
{#.doc "Ensures there are no more inputs."}
@@ -149,7 +149,7 @@
(function (_ tokens)
(case tokens
#.Nil (#error.Success [tokens []])
- _ (#error.Failure ($_ text/compose "Expected list of tokens to be empty!" (remaining-inputs tokens))))))
+ _ (#error.Failure ($_ text;compose "Expected list of tokens to be empty!" (remaining-inputs tokens))))))
(def: #export end?
{#.doc "Checks whether there are no more inputs."}
@@ -182,8 +182,8 @@
(#error.Success value)
_
- (#error.Failure (text/compose "Unconsumed inputs: "
- (|> (list/map code.to-text unconsumed)
+ (#error.Failure (text;compose "Unconsumed inputs: "
+ (|> (list;map code.to-text unconsumed)
(text.join-with ", ")))))))
(def: #export (local inputs syntax)
@@ -205,11 +205,11 @@
{interfaces (tuple (some (super-class-decl^ imports class-vars)))}
{constructor-args (constructor-args^ imports class-vars)}
{methods (some (overriden-method-def^ imports))})
- (let [def-code ($_ text/compose "anon-class:"
+ (let [def-code ($_ text;compose "anon-class:"
(spaced (list (super-class-decl$ (maybe.default object-super-class super))
- (with-brackets (spaced (list/map super-class-decl$ interfaces)))
- (with-brackets (spaced (list/map constructor-arg$ constructor-args)))
- (with-brackets (spaced (list/map (method-def$ id) methods))))))]
+ (with-brackets (spaced (list;map super-class-decl$ interfaces)))
+ (with-brackets (spaced (list;map constructor-arg$ constructor-args)))
+ (with-brackets (spaced (list;map (method-def$ id) methods))))))]
(wrap (list (` ((~ (code.text def-code)))))))))}
(let [[exported? tokens] (: [Bit (List Code)]
(case tokens
diff --git a/stdlib/source/lux/macro/syntax/common/reader.lux b/stdlib/source/lux/macro/syntax/common/reader.lux
index 44bb9dae9..fc4de3940 100644
--- a/stdlib/source/lux/macro/syntax/common/reader.lux
+++ b/stdlib/source/lux/macro/syntax/common/reader.lux
@@ -2,9 +2,9 @@
[lux #*
[control
monad
- ["p" parser ("#/." monad)]]
+ ["p" parser ("#;." monad)]]
[data
- ["." name ("#/." equivalence)]
+ ["." name ("#;." equivalence)]
["." product]
["." maybe]
[collection
@@ -16,8 +16,8 @@
## Exports
(def: #export export
(Syntax Bit)
- (p.either (p.after (s.this (' #export)) (p/wrap #1))
- (p/wrap #0)))
+ (p.either (p.after (s.this (' #export)) (p;wrap #1))
+ (p;wrap #0)))
## Declarations
(def: #export declaration
@@ -27,7 +27,7 @@
(foo bar baz))}
(Syntax //.Declaration)
(p.either (p.and s.local-identifier
- (p/wrap (list)))
+ (p;wrap (list)))
(s.form (p.and s.local-identifier
(p.some s.local-identifier)))))
@@ -45,7 +45,7 @@
type s.any
value s.any]
(wrap [(#.Some type) value])))
- (p.and (p/wrap #.None)
+ (p.and (p;wrap #.None)
s.any)))
(def: _definition-anns-tag^
@@ -91,7 +91,7 @@
(-> (List [Name Code]) (List Text))
(<| (maybe.default (list))
(: (Maybe (List Text)))
- (case (list.find (|>> product.left (name/= ["lux" "func-args"])) meta-data)
+ (case (list.find (|>> product.left (name;= ["lux" "func-args"])) meta-data)
(^multi (#.Some [_ value])
[(p.run (list value) tuple-meta^)
(#.Right [_ args])]
diff --git a/stdlib/source/lux/macro/syntax/common/writer.lux b/stdlib/source/lux/macro/syntax/common/writer.lux
index 0cae624f2..2110aa26e 100644
--- a/stdlib/source/lux/macro/syntax/common/writer.lux
+++ b/stdlib/source/lux/macro/syntax/common/writer.lux
@@ -3,7 +3,7 @@
[lux #*
[data
[collection
- ["." list ("#/." functor)]]
+ ["." list ("#;." functor)]]
["." product]]
["." function]
[macro
@@ -19,14 +19,14 @@
(def: #export (declaration declaration)
(-> //.Declaration Code)
(` ((~ (code.local-identifier (get@ #//.declaration-name declaration)))
- (~+ (list/map code.local-identifier
+ (~+ (list;map code.local-identifier
(get@ #//.declaration-args declaration))))))
(def: #export annotations
(-> //.Annotations Code)
- (|>> (list/map (product.both code.tag function.identity))
+ (|>> (list;map (product.both code.tag function.identity))
code.record))
(def: #export type-variables
(-> (List Text) (List Code))
- (list/map code.local-identifier))
+ (list;map code.local-identifier))
diff --git a/stdlib/source/lux/macro/template.lux b/stdlib/source/lux/macro/template.lux
index 7f5fe4ba6..1f098ff4a 100644
--- a/stdlib/source/lux/macro/template.lux
+++ b/stdlib/source/lux/macro/template.lux
@@ -6,7 +6,7 @@
[data
["." text]
[collection
- ["." list ("#/." monad)]]]]
+ ["." list ("#;." monad)]]]]
["." //
["." code]
["s" syntax (#+ Syntax syntax:)]])
@@ -21,9 +21,9 @@
(list.repeat (list.size locals))
(monad.seq @))]
(wrap (list (` (.with-expansions [(~+ (|> (list.zip2 locals g!locals)
- (list/map (function (_ [name identifier])
+ (list;map (function (_ [name identifier])
(list (code.local-identifier name) (as-is identifier))))
- list/join))]
+ list;join))]
(~ body)))))))
(def: snippet
diff --git a/stdlib/source/lux/math/infix.lux b/stdlib/source/lux/math/infix.lux
index 3b4b89da2..e2cfc455c 100644
--- a/stdlib/source/lux/math/infix.lux
+++ b/stdlib/source/lux/math/infix.lux
@@ -2,11 +2,11 @@
[lux #*
[control
monad
- ["p" parser ("#/." functor)]]
+ ["p" parser ("#;." functor)]]
[data
["." product]
[collection
- ["." list ("#/." fold)]]]
+ ["." list ("#;." fold)]]]
[macro
["s" syntax (#+ syntax: Syntax)]
["." code]]])
@@ -22,14 +22,14 @@
(<| p.rec (function (_ infix^))
($_ p.or
($_ p.either
- (p/map code.bit s.bit)
- (p/map code.nat s.nat)
- (p/map code.int s.int)
- (p/map code.rev s.rev)
- (p/map code.frac s.frac)
- (p/map code.text s.text)
- (p/map code.identifier s.identifier)
- (p/map code.tag s.tag))
+ (p;map code.bit s.bit)
+ (p;map code.nat s.nat)
+ (p;map code.int s.int)
+ (p;map code.rev s.rev)
+ (p;map code.frac s.frac)
+ (p;map code.text s.text)
+ (p;map code.identifier s.identifier)
+ (p;map code.tag s.tag))
(s.form (p.many s.any))
(s.tuple (p.and s.any infix^))
(s.tuple ($_ p.either
@@ -39,7 +39,7 @@
init-op s.any
init-param infix^
steps (p.some (p.and s.any infix^))]
- (wrap (product.right (list/fold (function (_ [op param] [subject [_subject _op _param]])
+ (wrap (product.right (list;fold (function (_ [op param] [subject [_subject _op _param]])
[param [(#Binary _subject _op _param)
(` and)
(#Binary subject op param)]])
@@ -50,7 +50,7 @@
init-op s.any
init-param infix^
steps (p.some (p.and s.any infix^))]
- (wrap (list/fold (function (_ [op param] [_subject _op _param])
+ (wrap (list;fold (function (_ [op param] [_subject _op _param])
[(#Binary _subject _op _param) op param])
[init-subject init-op init-param]
steps)))
diff --git a/stdlib/source/lux/math/logic/continuous.lux b/stdlib/source/lux/math/logic/continuous.lux
index 3e6ea581b..33b93f9ae 100644
--- a/stdlib/source/lux/math/logic/continuous.lux
+++ b/stdlib/source/lux/math/logic/continuous.lux
@@ -2,10 +2,10 @@
[lux (#- false true or and not)
[data
[number
- ["." rev ("#/." interval)]]]])
+ ["." rev ("#;." interval)]]]])
-(def: #export true Rev rev/top)
-(def: #export false Rev rev/bottom)
+(def: #export true Rev rev;top)
+(def: #export false Rev rev;bottom)
(do-template [<name> <chooser>]
[(def: #export <name>
diff --git a/stdlib/source/lux/math/modular.lux b/stdlib/source/lux/math/modular.lux
index 2d33e0c9d..313255d82 100644
--- a/stdlib/source/lux/math/modular.lux
+++ b/stdlib/source/lux/math/modular.lux
@@ -8,8 +8,8 @@
[data
["." error (#+ Error)]
[number
- ["." int ("#/." decimal)]]
- ["." text ("#/." monoid)
+ ["." int ("#;." decimal)]]
+ ["." text ("#;." monoid)
["l" lexer (#+ Lexer)]]]
[type
abstract]
@@ -38,13 +38,13 @@
(exception: #export [m] (incorrect-modulus {modulus (Modulus m)}
{parsed Int})
- (ex.report ["Expected" (int/encode (to-int modulus))]
- ["Actual" (int/encode parsed)]))
+ (ex.report ["Expected" (int;encode (to-int modulus))]
+ ["Actual" (int;encode parsed)]))
(exception: #export [rm sm] (cannot-equalize-moduli {reference (Modulus rm)}
{sample (Modulus sm)})
- (ex.report ["Reference" (int/encode (to-int reference))]
- ["Sample" (int/encode (to-int sample))]))
+ (ex.report ["Reference" (int;encode (to-int reference))]
+ ["Sample" (int;encode (to-int sample))]))
(def: #export (congruent? modulus reference sample)
(All [m] (-> (Modulus m) Int Int Bit))
@@ -90,10 +90,10 @@
(def: (encode modular)
(let [[remainder modulus] (:representation modular)]
- ($_ text/compose
- (int/encode remainder)
+ ($_ text;compose
+ (int;encode remainder)
separator
- (int/encode (to-int modulus)))))
+ (int;encode (to-int modulus)))))
(def: (decode text)
(<| (l.run text)
diff --git a/stdlib/source/lux/math/random.lux b/stdlib/source/lux/math/random.lux
index 1d0d03b8e..24fa17dbe 100644
--- a/stdlib/source/lux/math/random.lux
+++ b/stdlib/source/lux/math/random.lux
@@ -13,10 +13,10 @@
["r" ratio]
["c" complex]
["." frac]]
- ["." text (#+ Char) ("#/." monoid)
+ ["." text (#+ Char) ("#;." monoid)
["." unicode (#+ Segment)]]
[collection
- ["." list ("#/." fold)]
+ ["." list ("#;." fold)]
["." array (#+ Array)]
["." dictionary (#+ Dictionary)]
["." queue (#+ Queue)]
@@ -134,7 +134,7 @@
(do ..monad
[x char-gen
xs (text char-gen (dec size))]
- (wrap (text/compose (text.from-code x) xs)))))
+ (wrap (text;compose (text.from-code x) xs)))))
(do-template [<name> <set>]
[(def: #export <name>
@@ -230,7 +230,7 @@
[array Array array.from-list]
[queue Queue queue.from-list]
- [stack Stack (list/fold stack.push stack.empty)]
+ [stack Stack (list;fold stack.push stack.empty)]
)
(def: #export (set Hash<a> size value-gen)
diff --git a/stdlib/source/lux/test.lux b/stdlib/source/lux/test.lux
index a360bf424..14d783c9b 100644
--- a/stdlib/source/lux/test.lux
+++ b/stdlib/source/lux/test.lux
@@ -4,18 +4,18 @@
["." monad (#+ Monad do)]
["ex" exception (#+ exception:)]
[concurrency
- ["." promise (#+ Promise) ("#/." monad)]]]
+ ["." promise (#+ Promise) ("#;." monad)]]]
[data
["." product]
["." text
format]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
[time
["." instant]
["." duration]]
[math
- ["r" random ("#/." monad)]]
+ ["r" random ("#;." monad)]]
["." io]])
(type: #export Counters
@@ -60,10 +60,10 @@
(def: #export (context description)
(-> Text Test Test)
- (r/map (promise/map (function (_ [counters documentation])
+ (r;map (promise;map (function (_ [counters documentation])
[counters (|> documentation
(text.split-all-with ..separator)
- (list/map (|>> (format context-prefix)))
+ (list;map (|>> (format context-prefix)))
(text.join-with ..separator)
(format description ..separator))]))))
@@ -74,13 +74,13 @@
(-> Text Test)
(|>> (format ..failure-prefix)
[failure]
- promise/wrap
- r/wrap))
+ promise;wrap
+ r;wrap))
(def: #export (assert message condition)
{#.doc "Check that a condition is #1, and fail with the given message otherwise."}
(-> Text Bit (Promise [Counters Text]))
- (<| promise/wrap
+ (<| promise;wrap
(if condition
[success (format ..success-prefix message)]
[failure (format ..failure-prefix message)])))
diff --git a/stdlib/source/lux/time/date.lux b/stdlib/source/lux/time/date.lux
index 99a8f6f39..0eb5c7e88 100644
--- a/stdlib/source/lux/time/date.lux
+++ b/stdlib/source/lux/time/date.lux
@@ -5,15 +5,15 @@
[order (#+ Order)]
[enum (#+ Enum)]
codec
- ["p" parser ("#/." functor)]
+ ["p" parser ("#;." functor)]
[monad (#+ do)]]
[data
["." error (#+ Error)]
["." maybe]
[number
- ["." nat ("#/." decimal)]
- ["." int ("#/." decimal)]]
- ["." text ("#/." monoid)
+ ["." nat ("#;." decimal)]
+ ["." int ("#;." decimal)]]
+ ["." text ("#;." monoid)
["l" lexer]]
[collection
["." row (#+ Row row)]]]]
@@ -62,17 +62,17 @@
## Based on this: https://stackoverflow.com/a/42936293/6823464
(def: (pad value)
(-> Int Text)
- (let [digits (nat/encode (.nat value))]
+ (let [digits (nat;encode (.nat value))]
(if (i/< +10 value)
- (text/compose "0" digits)
+ (text;compose "0" digits)
digits)))
(def: (encode [year month day])
(-> Date Text)
- ($_ text/compose
+ ($_ text;compose
(if (i/< +0 year)
- (int/encode year)
- (nat/encode (.nat year)))
+ (int;encode year)
+ (nat;encode (.nat year)))
"-"
(pad (|> month //month.number inc .int)) "-"
(pad (|> day .int))))
@@ -92,7 +92,7 @@
(def: lex-section
(l.Lexer Int)
- (p/map .int (p.codec nat.decimal (l.exactly 2 l.decimal))))
+ (p;map .int (p.codec nat.decimal (l.exactly 2 l.decimal))))
(def: (leap-years year)
(-> Int Int)
diff --git a/stdlib/source/lux/time/duration.lux b/stdlib/source/lux/time/duration.lux
index 8054e9074..a24dc1844 100644
--- a/stdlib/source/lux/time/duration.lux
+++ b/stdlib/source/lux/time/duration.lux
@@ -9,9 +9,9 @@
[monad (#+ do)]]
[data
[number
- ["." nat ("#/." decimal)]
- ["." int ("#/." decimal number)]]
- ["." text ("#/." monoid)
+ ["." nat ("#;." decimal)]
+ ["." int ("#;." decimal number)]]
+ ["." text ("#;." monoid)
["l" lexer]]
["e" error]]
[type
@@ -75,7 +75,7 @@
[>= i/>=]
))))
- (open: "duration/." ..order)
+ (open: "duration;." ..order)
(do-template [<name> <op>]
[(def: #export (<name> left right)
@@ -84,8 +84,8 @@
right
left))]
- [max duration/>]
- [min duration/<]
+ [max duration;>]
+ [min duration;<]
)
(do-template [<name> <op>]
@@ -126,7 +126,7 @@
(let [signed? (negative? duration)
[days time-left] [(query day duration) (frame day duration)]
days (if signed?
- (int/abs days)
+ (int;abs days)
days)
time-left (if signed?
(..inverse time-left)
@@ -135,11 +135,11 @@
[minutes time-left] [(query minute time-left) (frame minute time-left)]
[seconds time-left] [(query second time-left) (frame second time-left)]
millis (to-millis time-left)]
- ($_ text/compose
+ ($_ text;compose
(if signed? "-" "+")
- (if (i/= +0 days) "" (text/compose (nat/encode (.nat days)) "D"))
- (if (i/= +0 hours) "" (text/compose (nat/encode (.nat hours)) "h"))
- (if (i/= +0 minutes) "" (text/compose (nat/encode (.nat minutes)) "m"))
- (if (i/= +0 seconds) "" (text/compose (nat/encode (.nat seconds)) "s"))
- (if (i/= +0 millis) "" (text/compose (nat/encode (.nat millis)) "ms"))
+ (if (i/= +0 days) "" (text;compose (nat;encode (.nat days)) "D"))
+ (if (i/= +0 hours) "" (text;compose (nat;encode (.nat hours)) "h"))
+ (if (i/= +0 minutes) "" (text;compose (nat;encode (.nat minutes)) "m"))
+ (if (i/= +0 seconds) "" (text;compose (nat;encode (.nat seconds)) "s"))
+ (if (i/= +0 millis) "" (text;compose (nat;encode (.nat millis)) "ms"))
))))
diff --git a/stdlib/source/lux/time/instant.lux b/stdlib/source/lux/time/instant.lux
index 7d9906733..64c8d674e 100644
--- a/stdlib/source/lux/time/instant.lux
+++ b/stdlib/source/lux/time/instant.lux
@@ -12,16 +12,16 @@
["." error (#+ Error)]
["." maybe]
[number
- ["." int ("#/." decimal)]]
- ["." text ("#/." monoid)
+ ["." int ("#;." decimal)]]
+ ["." text ("#;." monoid)
["l" lexer]]
[collection
- ["." list ("#/." fold)]
- ["." row (#+ Row row) ("#/." functor fold)]]]
+ ["." list ("#;." fold)]
+ ["." row (#+ Row row) ("#;." functor fold)]]]
[type
abstract]]
[//
- ["." duration ("#/." order)]
+ ["." duration ("#;." order)]
["." date (#+ Date)]
["." month (#+ Month)]
["." day (#+ Day)]])
@@ -104,7 +104,7 @@
duration.normal-year)]
(if (i/= +0 (duration.query year time-left))
[reference time-left]
- (if (duration/>= duration.empty time-left)
+ (if (duration;>= duration.empty time-left)
(recur (inc reference) (duration.merge (duration.inverse year) time-left))
(recur (dec reference) (duration.merge year time-left)))
))))
@@ -122,15 +122,15 @@
(def: (find-month months time)
(-> (Row Nat) duration.Duration [Nat duration.Duration])
- (if (duration/>= duration.empty time)
- (row/fold (function (_ month-days [current-month time-left])
+ (if (duration;>= duration.empty time)
+ (row;fold (function (_ month-days [current-month time-left])
(let [month-duration (duration.scale-up month-days duration.day)]
(if (i/= +0 (duration.query month-duration time-left))
[current-month time-left]
[(inc current-month) (duration.merge (duration.inverse month-duration) time-left)])))
[0 time]
months)
- (row/fold (function (_ month-days [current-month time-left])
+ (row;fold (function (_ month-days [current-month time-left])
(let [month-duration (duration.scale-up month-days duration.day)]
(if (i/= +0 (duration.query month-duration time-left))
[current-month time-left]
@@ -141,8 +141,8 @@
(def: (pad value)
(-> Int Text)
(if (i/< +10 value)
- (text/compose "0" (int/encode value))
- (int/encode value)))
+ (text;compose "0" (int;encode value))
+ (int;encode value)))
(def: (adjust-negative space duration)
(-> duration.Duration duration.Duration duration.Duration)
@@ -153,10 +153,10 @@
(def: (encode-millis millis)
(-> Int Text)
(cond (i/= +0 millis) ""
- (i/< +10 millis) ($_ text/compose ".00" (int/encode millis))
- (i/< +100 millis) ($_ text/compose ".0" (int/encode millis))
+ (i/< +10 millis) ($_ text;compose ".00" (int;encode millis))
+ (i/< +100 millis) ($_ text;compose ".0" (int;encode millis))
## (i/< +1,000 millis)
- ($_ text/compose "." (int/encode millis))))
+ ($_ text;compose "." (int;encode millis))))
(def: seconds-per-day Int (duration.query duration.second duration.day))
(def: days-up-to-epoch Int +719468)
@@ -182,7 +182,7 @@
(i/+ (i// +4 years-of-era))
(i/- (i// +100 years-of-era)))))
day-time (duration.frame duration.day offset)
- days-of-year (if (duration/>= duration.empty day-time)
+ days-of-year (if (duration;>= duration.empty day-time)
days-of-year
(dec days-of-year))
mp (|> days-of-year (i/* +5) (i/+ +2) (i// +153))
@@ -203,13 +203,13 @@
(def: #export (to-text instant)
(-> Instant Text)
(let [[[year month day] day-time] (extract-date instant)
- day-time (if (duration/>= duration.empty day-time)
+ day-time (if (duration;>= duration.empty day-time)
day-time
(duration.merge duration.day day-time))
[hours day-time] [(duration.query duration.hour day-time) (duration.frame duration.hour day-time)]
[minutes day-time] [(duration.query duration.minute day-time) (duration.frame duration.minute day-time)]
[seconds millis] [(duration.query duration.second day-time) (duration.frame duration.second day-time)]]
- ($_ text/compose (int/encode year) "-" (pad month) "-" (pad day) "T"
+ ($_ text;compose (int;encode year) "-" (pad month) "-" (pad day) "T"
(pad hours) ":" (pad minutes) ":" (pad seconds)
(|> millis
(adjust-negative duration.second)
@@ -291,7 +291,7 @@
## month-days-so-far (|> months
## row.to-list
## (list.take (.nat (dec utc-month)))
-## (list/fold n/+ 0))
+## (list;fold n/+ 0))
## total-days (|> year-days-so-far
## (i/+ (.int month-days-so-far))
## (i/+ (dec utc-day)))]]
diff --git a/stdlib/source/lux/tool/compiler/analysis.lux b/stdlib/source/lux/tool/compiler/analysis.lux
index b13b5aefc..a8ad548d9 100644
--- a/stdlib/source/lux/tool/compiler/analysis.lux
+++ b/stdlib/source/lux/tool/compiler/analysis.lux
@@ -6,10 +6,10 @@
["." product]
["." error]
["." maybe]
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format]
[collection
- ["." list ("#/." functor fold)]]]
+ ["." list ("#;." functor fold)]]]
["." function]]
[//
["." reference (#+ Register Variable Reference)]
@@ -105,7 +105,7 @@
(def: #export (apply [abstraction inputs])
(-> (Application Analysis) Analysis)
- (list/fold (function (_ input abstraction')
+ (list;fold (function (_ input abstraction')
(#Apply input abstraction'))
abstraction
inputs))
@@ -194,7 +194,7 @@
(#Tuple members)
(|> members
- (list/map %analysis)
+ (list;map %analysis)
(text.join-with " ")
(text.enclose ["[" "]"])))
@@ -213,7 +213,7 @@
(|> (%analysis body)
(format " ")
(format (|> environment
- (list/map reference.%variable)
+ (list;map reference.%variable)
(text.join-with " ")
(text.enclose ["[" "]"])))
(text.enclose ["(" ")"]))
@@ -222,13 +222,13 @@
(|> analysis
..application
#.Cons
- (list/map %analysis)
+ (list;map %analysis)
(text.join-with " ")
(text.enclose ["(" ")"]))
(#Extension name parameters)
(|> parameters
- (list/map %analysis)
+ (list;map %analysis)
(text.join-with " ")
(format (%t name) " ")
(text.enclose ["(" ")"]))))
@@ -292,7 +292,7 @@
(def: #export (with-cursor cursor action)
(All [a] (-> Cursor (Operation a) (Operation a)))
- (if (text/= "" (product.left cursor))
+ (if (text;= "" (product.left cursor))
action
(function (_ [bundle state])
(let [old-cursor (get@ #.cursor state)]
diff --git a/stdlib/source/lux/tool/compiler/default/init.lux b/stdlib/source/lux/tool/compiler/default/init.lux
index a00d4b5cd..a4359f73d 100644
--- a/stdlib/source/lux/tool/compiler/default/init.lux
+++ b/stdlib/source/lux/tool/compiler/default/init.lux
@@ -6,7 +6,7 @@
[data
["." product]
["." error (#+ Error)]
- ["." text ("#/." hash)]
+ ["." text ("#;." hash)]
[collection
["." dictionary]
["." set]]]
@@ -165,7 +165,7 @@
(def: (default-dependencies prelude input)
(-> Module ///.Input (List Module))
- (if (text/= prelude (get@ #///.module input))
+ (if (text;= prelude (get@ #///.module input))
(list)
(list prelude)))
)
@@ -175,7 +175,7 @@
(All [anchor expression statement]
(Instancer (///statement.State+ anchor expression statement) .Module)))
(function (_ key parameters input)
- (let [hash (text/hash (get@ #///.code input))
+ (let [hash (text;hash (get@ #///.code input))
dependencies (default-dependencies prelude input)]
{#///.dependencies dependencies
#///.process (function (_ state archive)
diff --git a/stdlib/source/lux/tool/compiler/meta/cache.lux b/stdlib/source/lux/tool/compiler/meta/cache.lux
index a0d5302f3..45b33f4f7 100644
--- a/stdlib/source/lux/tool/compiler/meta/cache.lux
+++ b/stdlib/source/lux/tool/compiler/meta/cache.lux
@@ -5,7 +5,7 @@
["ex" exception (#+ exception:)]
pipe]
[data
- ["." bit ("#/." equivalence)]
+ ["." bit ("#;." equivalence)]
["." maybe]
["." error]
["." product]
@@ -14,7 +14,7 @@
["." text
[format (#- Format)]]
[collection
- ["." list ("#/." functor fold)]
+ ["." list ("#;." functor fold)]
["dict" dictionary (#+ Dictionary)]
["." set (#+ Set)]]]
[world
@@ -92,7 +92,7 @@
(do @
[_ (..delete System<m> file)]
(wrap #1))))))]
- [(list.every? (bit/= #1))
+ [(list.every? (bit;= #1))
(if> [(..delete System<m> document)]
[(wrap [])])]))))
@@ -150,7 +150,7 @@
(do> @
[(..cached System<m>)]
[(monad.map @ (load-document System<m> contexts root key binary))
- (:: @ map (list/fold (function (_ full-document archive)
+ (:: @ map (list;fold (function (_ full-document archive)
(case full-document
(#.Some [[module references] document])
(dict.put module [references document] archive)
@@ -160,17 +160,17 @@
(: (Dictionary Text [(List Module) (Ex [d] (Document d))])
(dict.new text.hash))))]))
#let [candidate-entries (dict.entries candidate)
- candidate-dependencies (list/map (product.both id product.left)
+ candidate-dependencies (list;map (product.both id product.left)
candidate-entries)
candidate-archive (|> candidate-entries
- (list/map (product.both id product.right))
+ (list;map (product.both id product.right))
(dict.from-list text.hash))
graph (|> candidate
dict.entries
- (list/map (product.both id product.left))
+ (list;map (product.both id product.left))
/dependency.graph
(/dependency.prune candidate-archive))
- archive (list/fold (function (_ module archive)
+ archive (list;fold (function (_ module archive)
(if (dict.contains? module graph)
archive
(dict.remove module archive)))
diff --git a/stdlib/source/lux/tool/compiler/meta/cache/dependency.lux b/stdlib/source/lux/tool/compiler/meta/cache/dependency.lux
index 4664ade1d..ec01baf45 100644
--- a/stdlib/source/lux/tool/compiler/meta/cache/dependency.lux
+++ b/stdlib/source/lux/tool/compiler/meta/cache/dependency.lux
@@ -3,7 +3,7 @@
[data
["." text]
[collection
- ["." list ("#/." functor fold)]
+ ["." list ("#;." functor fold)]
["dict" dictionary (#+ Dictionary)]]]]
[///io (#+ Module)]
[///archive (#+ Archive)])
@@ -25,7 +25,7 @@
(-> Module Graph Graph)
(case (dependents module dependency)
(#.Some dependents)
- (list/fold remove (dict.remove module dependency) dependents)
+ (list;fold remove (dict.remove module dependency) dependents)
#.None
dependency))
@@ -36,16 +36,16 @@
(def: #export (dependency [module imports])
(-> Dependency Graph)
- (list/fold (..add module) ..empty imports))
+ (list;fold (..add module) ..empty imports))
(def: #export graph
(-> (List Dependency) Graph)
- (|>> (list/map ..dependency)
- (list/fold dict.merge empty)))
+ (|>> (list;map ..dependency)
+ (list;fold dict.merge empty)))
(def: #export (prune archive graph)
(-> Archive Graph Graph)
- (list/fold (function (_ module graph)
+ (list;fold (function (_ module graph)
(if (dict.contains? module archive)
graph
(..remove module graph)))
diff --git a/stdlib/source/lux/tool/compiler/meta/io/context.lux b/stdlib/source/lux/tool/compiler/meta/io/context.lux
index b009fbdc6..40dd5bd7d 100644
--- a/stdlib/source/lux/tool/compiler/meta/io/context.lux
+++ b/stdlib/source/lux/tool/compiler/meta/io/context.lux
@@ -7,7 +7,7 @@
["!" capability]]]
[data
["." error (#+ Error)]
- ["." text ("#/." hash)
+ ["." text ("#;." hash)
format
["." encoding]]]
[world
@@ -110,7 +110,7 @@
(#error.Success code)
(wrap {#////.module module
#////.file path
- #////.hash (text/hash code)
+ #////.hash (text;hash code)
#////.code code})
(#error.Failure _)
diff --git a/stdlib/source/lux/tool/compiler/name.lux b/stdlib/source/lux/tool/compiler/name.lux
index 394bdb2db..f65113d38 100644
--- a/stdlib/source/lux/tool/compiler/name.lux
+++ b/stdlib/source/lux/tool/compiler/name.lux
@@ -24,6 +24,7 @@
["!"] "_BG"
["?"] "_QM"
[":"] "_CO"
+ [";"] "_SC"
["."] "_PD"
[","] "_CM"
["<"] "_LT"
diff --git a/stdlib/source/lux/tool/compiler/phase.lux b/stdlib/source/lux/tool/compiler/phase.lux
index 8c4bbd615..3ae66af16 100644
--- a/stdlib/source/lux/tool/compiler/phase.lux
+++ b/stdlib/source/lux/tool/compiler/phase.lux
@@ -6,7 +6,7 @@
[monad (#+ do)]]
[data
["." product]
- ["." error (#+ Error) ("#/." functor)]
+ ["." error (#+ Error) ("#;." functor)]
["." text
format]]
[time
@@ -71,7 +71,7 @@
(def: #export (lift error)
(All [s a] (-> (Error a) (Operation s a)))
(function (_ state)
- (error/map (|>> [state]) error)))
+ (error;map (|>> [state]) error)))
(syntax: #export (assert exception message test)
(wrap (list (` (if (~ test)
diff --git a/stdlib/source/lux/tool/compiler/phase/analysis/case.lux b/stdlib/source/lux/tool/compiler/phase/analysis/case.lux
index 2970364a0..a2864e784 100644
--- a/stdlib/source/lux/tool/compiler/phase/analysis/case.lux
+++ b/stdlib/source/lux/tool/compiler/phase/analysis/case.lux
@@ -10,7 +10,7 @@
[text
format]
[collection
- ["." list ("#/." fold monoid functor)]]]
+ ["." list ("#;." fold monoid functor)]]]
["." type
["." check]]
["." macro
@@ -119,7 +119,7 @@
(#.Product _)
(|> caseT
type.flatten-tuple
- (list/map (re-quantify envs))
+ (list;map (re-quantify envs))
type.tuple
(:: ///.monad wrap))
@@ -188,16 +188,16 @@
num-sub-patterns (list.size sub-patterns)
matches (cond (n/< num-subs num-sub-patterns)
(let [[prefix suffix] (list.split (dec num-sub-patterns) subs)]
- (list.zip2 (list/compose prefix (list (type.tuple suffix))) sub-patterns))
+ (list.zip2 (list;compose prefix (list (type.tuple suffix))) sub-patterns))
(n/> num-subs num-sub-patterns)
(let [[prefix suffix] (list.split (dec num-subs) sub-patterns)]
- (list.zip2 subs (list/compose prefix (list (code.tuple suffix)))))
+ (list.zip2 subs (list;compose prefix (list (code.tuple suffix)))))
## (n/= num-subs num-sub-patterns)
(list.zip2 subs sub-patterns))]
(do @
- [[memberP+ thenA] (list/fold (: (All [a]
+ [[memberP+ thenA] (list;fold (: (All [a]
(-> [Type Code] (Operation [(List Pattern) a])
(Operation [(List Pattern) a])))
(function (_ [memberT memberC] then)
diff --git a/stdlib/source/lux/tool/compiler/phase/analysis/case/coverage.lux b/stdlib/source/lux/tool/compiler/phase/analysis/case/coverage.lux
index 24dd3051a..cb7cc07ef 100644
--- a/stdlib/source/lux/tool/compiler/phase/analysis/case/coverage.lux
+++ b/stdlib/source/lux/tool/compiler/phase/analysis/case/coverage.lux
@@ -5,17 +5,17 @@
["ex" exception (#+ exception:)]
equivalence]
[data
- ["." bit ("#/." equivalence)]
- ["." error (#+ Error) ("#/." monad)]
+ ["." bit ("#;." equivalence)]
+ ["." error (#+ Error) ("#;." monad)]
["." maybe]
[number
["." nat]]
["." text
format]
[collection
- ["." list ("#/." functor fold)]
+ ["." list ("#;." functor fold)]
["." dictionary (#+ Dictionary)]]]]
- ["." //// ("#/." monad)
+ ["." //// ("#;." monad)
[//
["/" analysis (#+ Pattern Variant Operation)]]])
@@ -73,7 +73,7 @@
(#Variant ?max-cases cases)
(|> cases
dictionary.entries
- (list/map (function (_ [idx coverage])
+ (list;map (function (_ [idx coverage])
(format (%n idx) " " (%coverage coverage))))
(text.join-with " ")
(text.enclose ["{" "}"])
@@ -94,13 +94,13 @@
(case pattern
(^or (#/.Simple #/.Unit)
(#/.Bind _))
- (/////wrap #Exhaustive)
+ (////;wrap #Exhaustive)
## Primitive patterns always have partial coverage because there
## are too many possibilities as far as values go.
(^template [<tag>]
(#/.Simple (<tag> _))
- (/////wrap #Partial))
+ (////;wrap #Partial))
([#/.Nat]
[#/.Int]
[#/.Rev]
@@ -111,7 +111,7 @@
## "#0", which means it is possible for bit
## pattern-matching to become exhaustive if complementary parts meet.
(#/.Simple (#/.Bit value))
- (/////wrap (#Bit value))
+ (////;wrap (#Bit value))
## Tuple patterns can be exhaustive if there is exhaustiveness for all of
## their sub-patterns.
@@ -180,7 +180,7 @@
#1
[(#Bit sideR) (#Bit sideS)]
- (bit/= sideR sideS)
+ (bit;= sideR sideS)
[(#Variant allR casesR) (#Variant allS casesS)]
(and (n/= (cases allR)
@@ -216,12 +216,12 @@
(-> Coverage Coverage (Error Coverage))
(case [addition so-far]
[#Partial #Partial]
- (error/wrap #Partial)
+ (error;wrap #Partial)
## 2 bit coverages are exhaustive if they complement one another.
(^multi [(#Bit sideA) (#Bit sideSF)]
(xor sideA sideSF))
- (error/wrap #Exhaustive)
+ (error;wrap #Exhaustive)
[(#Variant allA casesA) (#Variant allSF casesSF)]
(let [addition-cases (cases allSF)
@@ -282,7 +282,7 @@
## The 2 sequences cannot possibly be merged.
[#0 #0]
- (error/wrap (#Alt so-far addition))
+ (error;wrap (#Alt so-far addition))
## There is nothing the addition adds to the coverage.
[#1 #1]
@@ -294,7 +294,7 @@
## The addition completes the coverage.
[#Exhaustive _]
- (error/wrap #Exhaustive)
+ (error;wrap #Exhaustive)
## The left part will always match, so the addition is redundant.
(^multi [(#Seq left right) single]
@@ -304,7 +304,7 @@
## The right part is not necessary, since it can always match the left.
(^multi [single (#Seq left right)]
(coverage/= left single))
- (error/wrap single)
+ (error;wrap single)
## When merging a new coverage against one based on Alt, it may be
## that one of the many coverages in the Alt is complementary to
@@ -353,7 +353,7 @@
#.None
(case (list.reverse possibilitiesSF)
(#.Cons last prevs)
- (wrap (list/fold (function (_ left right) (#Alt left right))
+ (wrap (list;fold (function (_ left right) (#Alt left right))
last
prevs))
@@ -365,4 +365,4 @@
## The addition cannot possibly improve the coverage.
(ex.throw redundant-pattern [so-far addition])
## There are now 2 alternative paths.
- (error/wrap (#Alt so-far addition)))))
+ (error;wrap (#Alt so-far addition)))))
diff --git a/stdlib/source/lux/tool/compiler/phase/analysis/function.lux b/stdlib/source/lux/tool/compiler/phase/analysis/function.lux
index 0438ee4c8..690ee2658 100644
--- a/stdlib/source/lux/tool/compiler/phase/analysis/function.lux
+++ b/stdlib/source/lux/tool/compiler/phase/analysis/function.lux
@@ -8,7 +8,7 @@
["." text
format]
[collection
- ["." list ("#/." fold monoid monad)]]]
+ ["." list ("#;." fold monoid monad)]]]
["." type
["." check]]
["." macro]]
@@ -31,7 +31,7 @@
(ex.report ["Function" (%type function)]
["Arguments" (|> arguments
list.enumerate
- (list/map (.function (_ [idx argC])
+ (list;map (.function (_ [idx argC])
(format text.new-line " " (%n idx) " " (%code argC))))
(text.join-with ""))]))
diff --git a/stdlib/source/lux/tool/compiler/phase/analysis/inference.lux b/stdlib/source/lux/tool/compiler/phase/analysis/inference.lux
index 3b40b09d2..d677d4222 100644
--- a/stdlib/source/lux/tool/compiler/phase/analysis/inference.lux
+++ b/stdlib/source/lux/tool/compiler/phase/analysis/inference.lux
@@ -8,13 +8,13 @@
["." text
format]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
["." type
["." check]]
["." macro]]
["." // #_
["#." type]
- ["#/" // ("#/." monad)
+ ["#/" // ("#;." monad)
["#." extension]
[//
["/" analysis (#+ Tag Analysis Operation Phase)]]]])
@@ -28,7 +28,7 @@
(ex.report ["Type" (%type type)]
["Arguments" (|> args
list.enumerate
- (list/map (function (_ [idx argC])
+ (list;map (function (_ [idx argC])
(format text.new-line " " (%n idx) " " (%code argC))))
(text.join-with ""))]))
@@ -53,7 +53,7 @@
(-> Nat Type Type Type)
(case type
(#.Primitive name params)
- (#.Primitive name (list/map (replace parameter-idx replacement) params))
+ (#.Primitive name (list;map (replace parameter-idx replacement) params))
(^template [<tag>]
(<tag> left right)
@@ -71,7 +71,7 @@
(^template [<tag>]
(<tag> env quantified)
- (<tag> (list/map (replace parameter-idx replacement) env)
+ (<tag> (list;map (replace parameter-idx replacement) env)
(replace (n/+ 2 parameter-idx) replacement quantified)))
([#.UnivQ]
[#.ExQ])
@@ -193,7 +193,7 @@
(///.throw invalid-type-application inferT))
(#.Product _)
- (////wrap (type.function (type.flatten-tuple inferT) inferT))
+ (///;wrap (type.function (type.flatten-tuple inferT) inferT))
_
(///.throw not-a-record-type inferT)))
@@ -226,7 +226,7 @@
(n/< boundary tag)))
(case (list.nth tag cases)
(#.Some caseT)
- (////wrap (if (n/= 0 depth)
+ (///;wrap (if (n/= 0 depth)
(type.function (list caseT) currentT)
(let [replace' (replace (|> depth dec (n/* 2)) inferT)]
(type.function (list (replace' caseT))
@@ -240,7 +240,7 @@
(n/= boundary tag)
(let [caseT (type.variant (list.drop boundary cases))]
- (////wrap (if (n/= 0 depth)
+ (///;wrap (if (n/= 0 depth)
(type.function (list caseT) currentT)
(let [replace' (replace (|> depth dec (n/* 2)) inferT)]
(type.function (list (replace' caseT))
diff --git a/stdlib/source/lux/tool/compiler/phase/analysis/module.lux b/stdlib/source/lux/tool/compiler/phase/analysis/module.lux
index b2af57b50..cc7c857a0 100644
--- a/stdlib/source/lux/tool/compiler/phase/analysis/module.lux
+++ b/stdlib/source/lux/tool/compiler/phase/analysis/module.lux
@@ -5,11 +5,11 @@
["ex" exception (#+ exception:)]
pipe]
[data
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format]
["." error]
[collection
- ["." list ("#/." fold functor)]
+ ["." list ("#;." fold functor)]
[dictionary
["." plist]]]]
["." macro]]
@@ -236,16 +236,16 @@
(///.throw cannot-declare-tags-for-unnamed-type [tags type]))
_ (ensure-undeclared-tags self-name tags)
_ (///.assert cannot-declare-tags-for-foreign-type [tags type]
- (text/= self-name type-module))]
+ (text;= self-name type-module))]
(///extension.lift
(function (_ state)
(case (|> state (get@ #.modules) (plist.get self-name))
(#.Some module)
- (let [namespaced-tags (list/map (|>> [self-name]) tags)]
+ (let [namespaced-tags (list;map (|>> [self-name]) tags)]
(#error.Success [(update@ #.modules
(plist.update self-name
(|>> (update@ #.tags (function (_ tag-bindings)
- (list/fold (function (_ [idx tag] table)
+ (list;fold (function (_ [idx tag] table)
(plist.put tag [idx namespaced-tags exported? type] table))
tag-bindings
(list.enumerate tags))))
diff --git a/stdlib/source/lux/tool/compiler/phase/analysis/reference.lux b/stdlib/source/lux/tool/compiler/phase/analysis/reference.lux
index dad708219..dd5fd08e6 100644
--- a/stdlib/source/lux/tool/compiler/phase/analysis/reference.lux
+++ b/stdlib/source/lux/tool/compiler/phase/analysis/reference.lux
@@ -5,7 +5,7 @@
["ex" exception (#+ exception:)]]
["." macro]
[data
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format]]]
["." // #_
["#." scope]
@@ -37,7 +37,7 @@
[_ (//type.infer actualT)
(^@ def-name [::module ::name]) (///extension.lift (macro.normalize def-name))
current (///extension.lift macro.current-module-name)]
- (if (text/= current ::module)
+ (if (text;= current ::module)
<return>
(if (macro.export? def-anns)
(do @
diff --git a/stdlib/source/lux/tool/compiler/phase/analysis/scope.lux b/stdlib/source/lux/tool/compiler/phase/analysis/scope.lux
index 9ad60ebf9..9033344b3 100644
--- a/stdlib/source/lux/tool/compiler/phase/analysis/scope.lux
+++ b/stdlib/source/lux/tool/compiler/phase/analysis/scope.lux
@@ -4,13 +4,13 @@
monad
["ex" exception (#+ exception:)]]
[data
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format]
- ["." maybe ("#/." monad)]
+ ["." maybe ("#;." monad)]
["." product]
["e" error]
[collection
- ["." list ("#/." functor fold monoid)]
+ ["." list ("#;." functor fold monoid)]
[dictionary
["." plist]]]]]
["." ///
@@ -33,7 +33,7 @@
(|> scope
(get@ [#.locals #.mappings])
(plist.get name)
- (maybe/map (function (_ [type value])
+ (maybe;map (function (_ [type value])
[type (#////reference.Local value)]))))
(def: (captured? name scope)
@@ -48,7 +48,7 @@
mappings (get@ [#.captured #.mappings] scope)]
(case mappings
(#.Cons [_name [_source-type _source-ref]] mappings')
- (if (text/= name _name)
+ (if (text;= name _name)
(#.Some [_source-type (#////reference.Foreign idx)])
(recur (inc idx) mappings'))
@@ -83,7 +83,7 @@
(#.Cons top-outer _)
(let [[ref-type init-ref] (maybe.default (undefined)
(..reference name top-outer))
- [ref inner'] (list/fold (: (-> Scope [Variable (List Scope)] [Variable (List Scope)])
+ [ref inner'] (list;fold (: (-> Scope [Variable (List Scope)] [Variable (List Scope)])
(function (_ scope ref+inner)
[(#////reference.Foreign (get@ [#.captured #.counter] scope))
(#.Cons (update@ #.captured
@@ -94,7 +94,7 @@
(product.right ref+inner))]))
[init-ref #.Nil]
(list.reverse inner))
- scopes (list/compose inner' outer)]
+ scopes (list;compose inner' outer)]
(#.Right [(set@ #.scopes scopes state)
(#.Some [ref-type ref])]))
)))))
@@ -203,4 +203,4 @@
(-> Scope (List Variable))
(|> scope
(get@ [#.captured #.mappings])
- (list/map (function (_ [_ [_ ref]]) (ref-to-variable ref)))))
+ (list;map (function (_ [_ [_ ref]]) (ref-to-variable ref)))))
diff --git a/stdlib/source/lux/tool/compiler/phase/analysis/structure.lux b/stdlib/source/lux/tool/compiler/phase/analysis/structure.lux
index 0a6017cdc..9d78121d5 100644
--- a/stdlib/source/lux/tool/compiler/phase/analysis/structure.lux
+++ b/stdlib/source/lux/tool/compiler/phase/analysis/structure.lux
@@ -14,7 +14,7 @@
[text
format]
[collection
- ["." list ("#/." functor)]
+ ["." list ("#;." functor)]
["." dictionary (#+ Dictionary)]]]
["." type
["." check]]
@@ -63,7 +63,7 @@
(do-template [<name>]
[(exception: #export (<name> {key Name} {record (List [Name Code])})
(ex.report ["Tag" (%code (code.tag key))]
- ["Record" (%code (code.record (list/map (function (_ [keyI valC])
+ ["Record" (%code (code.record (list;map (function (_ [keyI valC])
[(code.tag keyI) valC])
record)))]))]
@@ -79,7 +79,7 @@
["Actual" (|> actual .int %i)]
["Type" (%type type)]
["Expression" (%code (|> record
- (list/map (function (_ [keyI valueC])
+ (list;map (function (_ [keyI valueC])
[(code.tag keyI) valueC]))
code.record))]))
@@ -217,8 +217,8 @@
membersC)
_ (//type.with-env
(check.check expectedT
- (type.tuple (list/map product.left membersTA))))]
- (wrap (/.tuple (list/map product.right membersTA))))))
+ (type.tuple (list;map product.left membersTA))))]
+ (wrap (/.tuple (list;map product.right membersTA))))))
(^template [<tag> <instancer>]
(<tag> _)
@@ -330,7 +330,7 @@
(: (Dictionary Nat Code)
(dictionary.new nat.hash))
record)
- #let [ordered-tuple (list/map (function (_ idx) (maybe.assume (dictionary.get idx idx->val)))
+ #let [ordered-tuple (list;map (function (_ idx) (maybe.assume (dictionary.get idx idx->val)))
tuple-range)]]
(wrap [ordered-tuple recordT]))
))
diff --git a/stdlib/source/lux/tool/compiler/phase/extension.lux b/stdlib/source/lux/tool/compiler/phase/extension.lux
index 86b2e6b38..653d3e011 100644
--- a/stdlib/source/lux/tool/compiler/phase/extension.lux
+++ b/stdlib/source/lux/tool/compiler/phase/extension.lux
@@ -5,10 +5,10 @@
["ex" exception (#+ exception:)]]
[data
["." error (#+ Error)]
- ["." text ("#/." order)
+ ["." text ("#;." order)
format]
[collection
- ["." list ("#/." functor)]
+ ["." list ("#;." functor)]
["." dictionary (#+ Dictionary)]]]
["." function]]
["." //])
@@ -49,8 +49,8 @@
(ex.report ["Extension" (%t name)]
["Available" (|> bundle
dictionary.keys
- (list.sort text/<)
- (list/map (|>> %t (format text.new-line text.tab)))
+ (list.sort text;<)
+ (list;map (|>> %t (format text.new-line text.tab)))
(text.join-with ""))]))
(exception: #export (incorrect-arity {name Name} {arity Nat} {args Nat})
diff --git a/stdlib/source/lux/tool/compiler/phase/extension/analysis/common.lux b/stdlib/source/lux/tool/compiler/phase/extension/analysis/common.lux
index dbe0b10ca..bff1d8527 100644
--- a/stdlib/source/lux/tool/compiler/phase/extension/analysis/common.lux
+++ b/stdlib/source/lux/tool/compiler/phase/extension/analysis/common.lux
@@ -6,7 +6,7 @@
["." text
format]
[collection
- ["." list ("#/." functor)]
+ ["." list ("#;." functor)]
["." dictionary (#+ Dictionary)]]]
[type
["." check]]
diff --git a/stdlib/source/lux/tool/compiler/phase/extension/analysis/host.jvm.lux b/stdlib/source/lux/tool/compiler/phase/extension/analysis/host.jvm.lux
index 6b1e6ed5b..428bffd66 100644
--- a/stdlib/source/lux/tool/compiler/phase/extension/analysis/host.jvm.lux
+++ b/stdlib/source/lux/tool/compiler/phase/extension/analysis/host.jvm.lux
@@ -9,10 +9,10 @@
["." error (#+ Error)]
["." maybe]
["." product]
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format]
[collection
- ["." list ("#/." fold functor monoid)]
+ ["." list ("#;." fold functor monoid)]
["." array (#+ Array)]
["." dictionary (#+ Dictionary)]]]
["." type
@@ -24,7 +24,7 @@
["#." common]
["#/" //
["#." bundle]
- ["#/" // ("#/." monad)
+ ["#/" // ("#;." monad)
[analysis
[".A" type]
[".A" inference]]
@@ -96,7 +96,7 @@
(ex.report ["Class" class]
["Method" method]
["Hints" (|> hints
- (list/map (|>> product.left %type (format text.new-line text.tab)))
+ (list;map (|>> product.left %type (format text.new-line text.tab)))
(text.join-with ""))]))]
[no-candidates]
@@ -277,13 +277,13 @@
(-> Type (Operation Text))
(case objectT
(#.Primitive name _)
- (/////wrap name)
+ (////;wrap name)
(#.Named name unnamed)
(check-jvm unnamed)
(#.Var id)
- (/////wrap "java.lang.Object")
+ (////;wrap "java.lang.Object")
(^template [<tag>]
(<tag> env unquantified)
@@ -308,7 +308,7 @@
[name (check-jvm objectT)]
(if (dictionary.contains? name boxes)
(////.throw primitives-are-not-objects name)
- (/////wrap name))))
+ (////;wrap name))))
(def: (box-array-element-type elemT)
(-> Type (Operation [Type Text]))
@@ -316,13 +316,13 @@
(#.Primitive name #.Nil)
(let [boxed-name (|> (dictionary.get name boxes)
(maybe.default name))]
- (/////wrap [(#.Primitive boxed-name #.Nil)
+ (////;wrap [(#.Primitive boxed-name #.Nil)
boxed-name]))
(#.Primitive name _)
(if (dictionary.contains? name boxes)
(////.throw primitives-cannot-have-type-parameters name)
- (/////wrap [elemT name]))
+ (////;wrap [elemT name]))
_
(////.throw invalid-type-for-array-element (%type elemT))))
@@ -564,7 +564,7 @@
(-> java/lang/reflect/Type (Operation Text))
(<| (case (host.check Class jvm-type)
(#.Some jvm-type)
- (/////wrap (Class::getName jvm-type))
+ (////;wrap (Class::getName jvm-type))
_)
(case (host.check ParameterizedType jvm-type)
@@ -587,7 +587,7 @@
(let [var-name (TypeVariable::getName java-type)]
(case (dictionary.get var-name mappings)
(#.Some var-type)
- (/////wrap var-type)
+ (////;wrap var-type)
#.None
(////.throw unknown-type-var var-name)))
@@ -601,21 +601,21 @@
(java-type-to-lux-type mappings bound)
_
- (/////wrap Any))
+ (////;wrap Any))
_)
(case (host.check Class java-type)
(#.Some java-type)
(let [java-type (:coerce (Class Object) java-type)
class-name (Class::getName java-type)]
- (/////wrap (case (array.size (Class::getTypeParameters java-type))
+ (////;wrap (case (array.size (Class::getTypeParameters java-type))
0
(#.Primitive class-name (list))
arity
(|> (list.indices arity)
list.reverse
- (list/map (|>> (n/* 2) inc #.Parameter))
+ (list;map (|>> (n/* 2) inc #.Parameter))
(#.Primitive class-name)
(type.univ-q arity)))))
@@ -630,7 +630,7 @@
ParameterizedType::getActualTypeArguments
array.to-list
(monad.map @ (java-type-to-lux-type mappings)))]
- (/////wrap (#.Primitive (Class::getName (:coerce (Class Object) raw))
+ (////;wrap (#.Primitive (Class::getName (:coerce (Class Object) raw))
paramsT)))
_
@@ -657,7 +657,7 @@
class-params (array.to-list (Class::getTypeParameters class))
num-class-params (list.size class-params)
num-type-params (list.size params)]
- (cond (not (text/= class-name name))
+ (cond (not (text;= class-name name))
(////.throw cannot-correspond-type-with-a-class
(format "Class = " class-name text.new-line
"Type = " (%type type)))
@@ -670,8 +670,8 @@
" Type: " (%type type)))
## else
- (/////wrap (|> params
- (list.zip2 (list/map (|>> TypeVariable::getName) class-params))
+ (////;wrap (|> params
+ (list.zip2 (list;map (|>> TypeVariable::getName) class-params))
(dictionary.from-list text.hash)))
))
@@ -714,7 +714,7 @@
(not (dictionary.contains? to-name boxes)))
to-class (load-class to-name)]
(loop [[current-name currentT] [from-name valueT]]
- (if (text/= to-name current-name)
+ (if (text;= to-name current-name)
(do @
[_ (typeA.infer toT)]
(wrap #1))
@@ -734,7 +734,7 @@
(array.to-list (Class::getGenericInterfaces current-class))))]
(case (|> candiate-parents
(list.filter product.right)
- (list/map product.left))
+ (list;map product.left))
(#.Cons [next-name nextJT] _)
(do @
[mapping (correspond-type-params current-class currentT)
@@ -810,7 +810,7 @@
var-names (|> class
Class::getTypeParameters
array.to-list
- (list/map (|>> TypeVariable::getName)))]
+ (list;map (|>> TypeVariable::getName)))]
mappings (: (Operation Mappings)
(case objectT
(#.Primitive _class-name _class-params)
@@ -918,7 +918,7 @@
(-> java/lang/reflect/Type (Operation Text))
(<| (case (host.check Class type)
(#.Some type)
- (/////wrap (Class::getName type))
+ (////;wrap (Class::getName type))
_)
(case (host.check ParameterizedType type)
@@ -928,12 +928,12 @@
_)
(case (host.check TypeVariable type)
(#.Some type)
- (/////wrap "java.lang.Object")
+ (////;wrap "java.lang.Object")
_)
(case (host.check WildcardType type)
(#.Some type)
- (/////wrap "java.lang.Object")
+ (////;wrap "java.lang.Object")
_)
(case (host.check GenericArrayType type)
@@ -962,7 +962,7 @@
(monad.map @ java-type-to-parameter))
#let [modifiers (Method::getModifiers method)]]
(wrap (and (Object::equals class (Method::getDeclaringClass method))
- (text/= method-name (Method::getName method))
+ (text;= method-name (Method::getName method))
(case #Static
#Special
(Modifier::isStatic modifiers)
@@ -977,9 +977,9 @@
_
#1)
(n/= (list.size arg-classes) (list.size parameters))
- (list/fold (function (_ [expectedJC actualJC] prev)
+ (list;fold (function (_ [expectedJC actualJC] prev)
(and prev
- (text/= expectedJC actualJC)))
+ (text;= expectedJC actualJC)))
#1
(list.zip2 arg-classes parameters))))))
@@ -991,9 +991,9 @@
(monad.map @ java-type-to-parameter))]
(wrap (and (Object::equals class (Constructor::getDeclaringClass constructor))
(n/= (list.size arg-classes) (list.size parameters))
- (list/fold (function (_ [expectedJC actualJC] prev)
+ (list;fold (function (_ [expectedJC actualJC] prev)
(and prev
- (text/= expectedJC actualJC)))
+ (text;= expectedJC actualJC)))
#1
(list.zip2 arg-classes parameters))))))
@@ -1006,7 +1006,7 @@
(if (n/= 0 amount)
(list)
(|> (list.indices amount)
- (list/map (|>> (n/+ offset) idx-to-parameter)))))
+ (list;map (|>> (n/+ offset) idx-to-parameter)))))
(def: (method-signature method-style method)
(-> Method-Style Method (Operation Method-Signature))
@@ -1019,20 +1019,20 @@
_
(|> (Class::getTypeParameters owner)
array.to-list
- (list/map (|>> TypeVariable::getName))))
+ (list;map (|>> TypeVariable::getName))))
method-tvars (|> (Method::getTypeParameters method)
array.to-list
- (list/map (|>> TypeVariable::getName)))
+ (list;map (|>> TypeVariable::getName)))
num-owner-tvars (list.size owner-tvars)
num-method-tvars (list.size method-tvars)
- all-tvars (list/compose owner-tvars method-tvars)
+ all-tvars (list;compose owner-tvars method-tvars)
num-all-tvars (list.size all-tvars)
owner-tvarsT (type-vars num-owner-tvars 0)
method-tvarsT (type-vars num-method-tvars num-owner-tvars)
mappings (: Mappings
(if (list.empty? all-tvars)
fresh-mappings
- (|> (list/compose owner-tvarsT method-tvarsT)
+ (|> (list;compose owner-tvarsT method-tvarsT)
list.reverse
(list.zip2 all-tvars)
(dictionary.from-list text.hash))))]
@@ -1087,7 +1087,7 @@
(cond passes?
(:: @ map (|>> #Pass) (method-signature method-style method))
- (text/= method-name (Method::getName method))
+ (text;= method-name (Method::getName method))
(:: @ map (|>> #Hint) (method-signature method-style method))
## else
@@ -1108,19 +1108,19 @@
owner-name (Class::getName owner)
owner-tvars (|> (Class::getTypeParameters owner)
array.to-list
- (list/map (|>> TypeVariable::getName)))
+ (list;map (|>> TypeVariable::getName)))
constructor-tvars (|> (Constructor::getTypeParameters constructor)
array.to-list
- (list/map (|>> TypeVariable::getName)))
+ (list;map (|>> TypeVariable::getName)))
num-owner-tvars (list.size owner-tvars)
- all-tvars (list/compose owner-tvars constructor-tvars)
+ all-tvars (list;compose owner-tvars constructor-tvars)
num-all-tvars (list.size all-tvars)
owner-tvarsT (type-vars num-owner-tvars 0)
constructor-tvarsT (type-vars num-all-tvars num-owner-tvars)
mappings (: Mappings
(if (list.empty? all-tvars)
fresh-mappings
- (|> (list/compose owner-tvarsT constructor-tvarsT)
+ (|> (list;compose owner-tvarsT constructor-tvarsT)
list.reverse
(list.zip2 all-tvars)
(dictionary.from-list text.hash))))]
@@ -1165,8 +1165,8 @@
(def: (decorate-inputs typesT inputsA)
(-> (List Text) (List Analysis) (List Analysis))
(|> inputsA
- (list.zip2 (list/map /////analysis.text typesT))
- (list/map (function (_ [type value])
+ (list.zip2 (list;map /////analysis.text typesT))
+ (list;map (function (_ [type value])
(/////analysis.tuple (list type value))))))
(def: invoke::static
@@ -1176,9 +1176,9 @@
(s.run args ($_ p.and s.text s.text (p.some (s.tuple (p.and s.text s.any))))))
(#error.Success [class method argsTC])
(do ////.monad
- [#let [argsT (list/map product.left argsTC)]
+ [#let [argsT (list;map product.left argsTC)]
[methodT exceptionsT] (method-candidate class method #Static argsT)
- [outputT argsA] (inferenceA.general analyse methodT (list/map product.right argsTC))
+ [outputT argsA] (inferenceA.general analyse methodT (list;map product.right argsTC))
outputJC (check-jvm outputT)]
(wrap (#/////analysis.Extension extension-name (list& (/////analysis.text class) (/////analysis.text method)
(/////analysis.text outputJC) (decorate-inputs argsT argsA)))))
@@ -1193,9 +1193,9 @@
(s.run args ($_ p.and s.text s.text s.any (p.some (s.tuple (p.and s.text s.any))))))
(#error.Success [class method objectC argsTC])
(do ////.monad
- [#let [argsT (list/map product.left argsTC)]
+ [#let [argsT (list;map product.left argsTC)]
[methodT exceptionsT] (method-candidate class method #Virtual argsT)
- [outputT allA] (inferenceA.general analyse methodT (list& objectC (list/map product.right argsTC)))
+ [outputT allA] (inferenceA.general analyse methodT (list& objectC (list;map product.right argsTC)))
#let [[objectA argsA] (case allA
(#.Cons objectA argsA)
[objectA argsA]
@@ -1216,9 +1216,9 @@
(p.run args ($_ p.and s.text s.text s.any (p.some (s.tuple (p.and s.text s.any))) s.end!)))
(#error.Success [_ [class method objectC argsTC _]])
(do ////.monad
- [#let [argsT (list/map product.left argsTC)]
+ [#let [argsT (list;map product.left argsTC)]
[methodT exceptionsT] (method-candidate class method #Special argsT)
- [outputT argsA] (inferenceA.general analyse methodT (list& objectC (list/map product.right argsTC)))
+ [outputT argsA] (inferenceA.general analyse methodT (list& objectC (list;map product.right argsTC)))
outputJC (check-jvm outputT)]
(wrap (#/////analysis.Extension extension-name (list& (/////analysis.text class) (/////analysis.text method)
(/////analysis.text outputJC) (decorate-inputs argsT argsA)))))
@@ -1233,12 +1233,12 @@
(s.run args ($_ p.and s.text s.text s.any (p.some (s.tuple (p.and s.text s.any))))))
(#error.Success [class-name method objectC argsTC])
(do ////.monad
- [#let [argsT (list/map product.left argsTC)]
+ [#let [argsT (list;map product.left argsTC)]
class (load-class class-name)
_ (////.assert non-interface class-name
(Modifier::isInterface (Class::getModifiers class)))
[methodT exceptionsT] (method-candidate class-name method #Interface argsT)
- [outputT argsA] (inferenceA.general analyse methodT (list& objectC (list/map product.right argsTC)))
+ [outputT argsA] (inferenceA.general analyse methodT (list& objectC (list;map product.right argsTC)))
outputJC (check-jvm outputT)]
(wrap (#/////analysis.Extension extension-name
(list& (/////analysis.text class-name) (/////analysis.text method) (/////analysis.text outputJC)
@@ -1254,9 +1254,9 @@
(s.run args ($_ p.and s.text (p.some (s.tuple (p.and s.text s.any))))))
(#error.Success [class argsTC])
(do ////.monad
- [#let [argsT (list/map product.left argsTC)]
+ [#let [argsT (list;map product.left argsTC)]
[methodT exceptionsT] (constructor-candidate class argsT)
- [outputT argsA] (inferenceA.general analyse methodT (list/map product.right argsTC))]
+ [outputT argsA] (inferenceA.general analyse methodT (list;map product.right argsTC))]
(wrap (#/////analysis.Extension extension-name (list& (/////analysis.text class) (decorate-inputs argsT argsA)))))
_
diff --git a/stdlib/source/lux/tool/compiler/phase/extension/bundle.lux b/stdlib/source/lux/tool/compiler/phase/extension/bundle.lux
index 643e3b38c..ad99db848 100644
--- a/stdlib/source/lux/tool/compiler/phase/extension/bundle.lux
+++ b/stdlib/source/lux/tool/compiler/phase/extension/bundle.lux
@@ -6,7 +6,7 @@
["." text
format]
[collection
- ["." list ("#/." functor)]
+ ["." list ("#;." functor)]
["." dictionary (#+ Dictionary)]]]]
[// (#+ Handler Bundle)])
@@ -24,5 +24,5 @@
(All [s i o]
(-> Text (-> (Bundle s i o) (Bundle s i o))))
(|>> dictionary.entries
- (list/map (function (_ [key val]) [(format prefix " " key) val]))
+ (list;map (function (_ [key val]) [(format prefix " " key) val]))
(dictionary.from-list text.hash)))
diff --git a/stdlib/source/lux/tool/compiler/phase/extension/statement.lux b/stdlib/source/lux/tool/compiler/phase/extension/statement.lux
index 5c957aab1..172517dd0 100644
--- a/stdlib/source/lux/tool/compiler/phase/extension/statement.lux
+++ b/stdlib/source/lux/tool/compiler/phase/extension/statement.lux
@@ -7,7 +7,7 @@
[text
format]
[collection
- ["." list ("#/." functor)]
+ ["." list ("#;." functor)]
["." dictionary]]]
["." macro]
[type (#+ :share :by-example)
diff --git a/stdlib/source/lux/tool/compiler/phase/generation.lux b/stdlib/source/lux/tool/compiler/phase/generation.lux
index 99a4c5517..3fe3f867b 100644
--- a/stdlib/source/lux/tool/compiler/phase/generation.lux
+++ b/stdlib/source/lux/tool/compiler/phase/generation.lux
@@ -6,7 +6,7 @@
[data
["." product]
["." error (#+ Error)]
- ["." name ("#/." equivalence)]
+ ["." name ("#;." equivalence)]
["." text
format]
[collection
@@ -212,7 +212,7 @@
?buffer (extension.read (get@ #buffer))]
(case ?buffer
(#.Some buffer)
- (if (row.any? (|>> product.left (name/= name)) buffer)
+ (if (row.any? (|>> product.left (name;= name)) buffer)
(//.throw cannot-overwrite-output name)
(extension.update (set@ #buffer (#.Some (row.add [name code] buffer)))))
diff --git a/stdlib/source/lux/tool/compiler/phase/generation/js.lux b/stdlib/source/lux/tool/compiler/phase/generation/js.lux
index df0db4c79..5da2a016e 100644
--- a/stdlib/source/lux/tool/compiler/phase/generation/js.lux
+++ b/stdlib/source/lux/tool/compiler/phase/generation/js.lux
@@ -6,7 +6,7 @@
[runtime (#+ Phase)]
["." primitive]
["." structure]
- ["." reference ("#/." system)]
+ ["." reference ("#;." system)]
["." function]
["." case]
["." loop]
@@ -33,7 +33,7 @@
(structure.tuple generate members)
(#synthesis.Reference value)
- (reference/reference value)
+ (reference;reference value)
(^ (synthesis.branch/case case))
(case.case generate case)
diff --git a/stdlib/source/lux/tool/compiler/phase/generation/js/case.lux b/stdlib/source/lux/tool/compiler/phase/generation/js/case.lux
index 8dba99feb..ed2c74a4b 100644
--- a/stdlib/source/lux/tool/compiler/phase/generation/js/case.lux
+++ b/stdlib/source/lux/tool/compiler/phase/generation/js/case.lux
@@ -8,7 +8,7 @@
["." text
format]
[collection
- ["." list ("#/." functor fold)]]]
+ ["." list ("#;." functor fold)]]]
[host
["_" js (#+ Expression Computation Var Statement)]]]
["." // #_
@@ -17,7 +17,7 @@
["#." primitive]
["#/" // #_
["#." reference]
- ["#/" // ("#/." monad)
+ ["#/" // ("#;." monad)
["#/" // #_
[reference (#+ Register)]
["#." synthesis (#+ Synthesis Path)]]]]])
@@ -43,7 +43,7 @@
(Operation Expression))
(do ////.monad
[valueO (generate valueS)]
- (wrap (list/fold (function (_ [idx tail?] source)
+ (wrap (list;fold (function (_ [idx tail?] source)
(.let [method (.if tail?
//runtime.product//right
//runtime.product//left)]
@@ -127,14 +127,14 @@
(wrap (_.return body!)))
#/////synthesis.Pop
- (/////wrap pop-cursor!)
+ (////;wrap pop-cursor!)
(#/////synthesis.Bind register)
- (/////wrap (_.define (..register register) ..peek-cursor))
+ (////;wrap (_.define (..register register) ..peek-cursor))
(^template [<tag> <format> <=>]
(^ (<tag> value))
- (/////wrap (_.when (|> value <format> (<=> ..peek-cursor) _.not)
+ (////;wrap (_.when (|> value <format> (<=> ..peek-cursor) _.not)
fail-pm!)))
([/////synthesis.path/bit //primitive.bit _.=]
[/////synthesis.path/i64 (<| //primitive.i64 .int) //runtime.i64//=]
@@ -143,7 +143,7 @@
(^template [<pm> <flag> <prep>]
(^ (<pm> idx))
- (/////wrap ($_ _.then
+ (////;wrap ($_ _.then
(_.set @temp (|> idx <prep> .int _.i32 (//runtime.sum//get ..peek-cursor <flag>)))
(_.if (_.= _.null @temp)
fail-pm!
@@ -153,7 +153,7 @@
(^template [<pm> <getter> <prep>]
(^ (<pm> idx))
- (/////wrap (|> idx <prep> .int _.i32 (<getter> ..peek-cursor) push-cursor!)))
+ (////;wrap (|> idx <prep> .int _.i32 (<getter> ..peek-cursor) push-cursor!)))
([/////synthesis.member/left //runtime.product//left (<|)]
[/////synthesis.member/right //runtime.product//right inc])
@@ -163,7 +163,7 @@
thenP))
(do ////.monad
[then! (pattern-matching' generate thenP)]
- (/////wrap ($_ _.then
+ (////;wrap ($_ _.then
(_.define (..register register) ..peek-and-pop-cursor)
then!)))
@@ -174,7 +174,7 @@
(.let [[extra-pops nextP'] (count-pops nextP)]
(do ////.monad
[next! (pattern-matching' generate nextP')]
- (/////wrap ($_ _.then
+ (////;wrap ($_ _.then
(multi-pop-cursor! (n/+ 2 extra-pops))
next!))))
diff --git a/stdlib/source/lux/tool/compiler/phase/generation/js/extension/common.lux b/stdlib/source/lux/tool/compiler/phase/generation/js/extension/common.lux
index cbac2ca3f..dfd0e4aee 100644
--- a/stdlib/source/lux/tool/compiler/phase/generation/js/extension/common.lux
+++ b/stdlib/source/lux/tool/compiler/phase/generation/js/extension/common.lux
@@ -8,7 +8,7 @@
["." product]
[number (#+ hex)]
[collection
- ["." list ("#/." functor)]
+ ["." list ("#;." functor)]
["." dictionary]]]
["." macro (#+ with-gensyms)
["." code]
@@ -45,7 +45,7 @@
(^ (list (~+ g!input+)))
(do /////.monad
[(~+ (|> g!input+
- (list/map (function (_ g!input)
+ (list;map (function (_ g!input)
(list g!input (` ((~ g!phase) (~ g!input))))))
list.concat))]
((~' wrap) ((~ g!extension) [(~+ g!input+)])))
diff --git a/stdlib/source/lux/tool/compiler/phase/generation/js/function.lux b/stdlib/source/lux/tool/compiler/phase/generation/js/function.lux
index 1d74112e2..a99546957 100644
--- a/stdlib/source/lux/tool/compiler/phase/generation/js/function.lux
+++ b/stdlib/source/lux/tool/compiler/phase/generation/js/function.lux
@@ -8,7 +8,7 @@
[text
format]
[collection
- ["." list ("#/." functor fold)]]]
+ ["." list ("#;." functor fold)]]]
[host
["_" js (#+ Expression Computation Var)]]]
["." // #_
@@ -17,7 +17,7 @@
["#." case]
["#/" //
["#." reference]
- ["#/" // ("#/." monad)
+ ["#/" // ("#;." monad)
["." // #_
[reference (#+ Register Variable)]
[analysis (#+ Variant Tuple Environment Arity Abstraction Application Analysis)]
@@ -35,14 +35,14 @@
(def: (with-closure inits function-definition)
(-> (List Expression) Computation (Operation Computation))
- (/////wrap
+ (////;wrap
(case inits
#.Nil
function-definition
_
(let [closure (_.closure (|> (list.enumerate inits)
- (list/map (|>> product.left ..capture)))
+ (list;map (|>> product.left ..capture)))
(_.return function-definition))]
(_.apply/* closure inits)))))
@@ -69,7 +69,7 @@
apply-poly (.function (_ args func)
(|> func (_.do "apply" (list _.null args))))
initialize-self! (_.define (//case.register 0) @self)
- initialize! (list/fold (.function (_ post pre!)
+ initialize! (list;fold (.function (_ post pre!)
($_ _.then
pre!
(_.define (..input post) (_.at (_.i32 (.int post)) @@arguments))))
diff --git a/stdlib/source/lux/tool/compiler/phase/generation/js/loop.lux b/stdlib/source/lux/tool/compiler/phase/generation/js/loop.lux
index ba12e4c03..e0ec074d3 100644
--- a/stdlib/source/lux/tool/compiler/phase/generation/js/loop.lux
+++ b/stdlib/source/lux/tool/compiler/phase/generation/js/loop.lux
@@ -7,7 +7,7 @@
["." text
format]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
[host
["_" js (#+ Computation Var)]]]
["." // #_
@@ -29,7 +29,7 @@
#let [closure (_.function @scope
(|> initsS+
list.enumerate
- (list/map (|>> product.left (n/+ start) //case.register)))
+ (list;map (|>> product.left (n/+ start) //case.register)))
(_.return bodyO))]]
(wrap (_.apply/* closure initsO+))))
diff --git a/stdlib/source/lux/tool/compiler/phase/generation/js/runtime.lux b/stdlib/source/lux/tool/compiler/phase/generation/js/runtime.lux
index fe400e403..b3ff414b2 100644
--- a/stdlib/source/lux/tool/compiler/phase/generation/js/runtime.lux
+++ b/stdlib/source/lux/tool/compiler/phase/generation/js/runtime.lux
@@ -10,7 +10,7 @@
["." text
format]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
["." macro
["." code]
["s" syntax (#+ syntax:)]]
@@ -102,7 +102,7 @@
(syntax: #export (with-vars {vars (s.tuple (p.some s.local-identifier))}
body)
(wrap (list (` (let [(~+ (|> vars
- (list/map (function (_ var)
+ (list;map (function (_ var)
(list (code.local-identifier var)
(` (_.var (~ (code.text (/////name.normalize var))))))))
list.concat))]
@@ -130,8 +130,8 @@
(let [nameC (code.local-identifier name)
code-nameC (code.local-identifier (format "@" name))
runtime-nameC (` (runtime-name (~ (code.text name))))
- inputsC (list/map code.local-identifier inputs)
- inputs-typesC (list/map (function.constant (` _.Expression)) inputs)]
+ inputsC (list;map code.local-identifier inputs)
+ inputs-typesC (list;map (function.constant (` _.Expression)) inputs)]
(wrap (list (` (def: #export ((~ nameC) (~+ inputsC))
(-> (~+ inputs-typesC) Computation)
(_.apply/* (~ runtime-nameC) (list (~+ inputsC)))))
diff --git a/stdlib/source/lux/tool/compiler/phase/generation/reference.lux b/stdlib/source/lux/tool/compiler/phase/generation/reference.lux
index f8c875ccc..4907ada5d 100644
--- a/stdlib/source/lux/tool/compiler/phase/generation/reference.lux
+++ b/stdlib/source/lux/tool/compiler/phase/generation/reference.lux
@@ -7,7 +7,7 @@
format]]
[type (#+ :share)]]
["." //
- ["#/" // ("#/." monad)
+ ["#/" // ("#;." monad)
["#/" // #_
[synthesis (#+ Synthesis)]
["#." reference (#+ Register Variable Reference)]]]])
@@ -61,13 +61,13 @@
(#////reference.Foreign register)
(foreign register))
- ////wrap)})
+ ///;wrap)})
constant (:share [expression]
{(-> Text expression)
constant}
{(All [anchor statement]
(-> Name (//.Operation anchor expression statement)))
- (|>> //.remember (////map constant))})]
+ (|>> //.remember (///;map constant))})]
(structure
(def: local local)
(def: foreign foreign)
diff --git a/stdlib/source/lux/tool/compiler/phase/generation/scheme.lux b/stdlib/source/lux/tool/compiler/phase/generation/scheme.lux
index df0db4c79..5da2a016e 100644
--- a/stdlib/source/lux/tool/compiler/phase/generation/scheme.lux
+++ b/stdlib/source/lux/tool/compiler/phase/generation/scheme.lux
@@ -6,7 +6,7 @@
[runtime (#+ Phase)]
["." primitive]
["." structure]
- ["." reference ("#/." system)]
+ ["." reference ("#;." system)]
["." function]
["." case]
["." loop]
@@ -33,7 +33,7 @@
(structure.tuple generate members)
(#synthesis.Reference value)
- (reference/reference value)
+ (reference;reference value)
(^ (synthesis.branch/case case))
(case.case generate case)
diff --git a/stdlib/source/lux/tool/compiler/phase/generation/scheme/case.jvm.lux b/stdlib/source/lux/tool/compiler/phase/generation/scheme/case.jvm.lux
index 142e4a165..49733e6f3 100644
--- a/stdlib/source/lux/tool/compiler/phase/generation/scheme/case.jvm.lux
+++ b/stdlib/source/lux/tool/compiler/phase/generation/scheme/case.jvm.lux
@@ -8,7 +8,7 @@
["." text
format]
[collection
- ["." list ("#/." functor fold)]]]
+ ["." list ("#;." functor fold)]]]
[host
["_" scheme (#+ Expression Computation Var)]]]
["." // #_
@@ -16,7 +16,7 @@
["#." primitive]
["#/" // #_
["#." reference]
- ["#/" // ("#/." monad)
+ ["#/" // ("#;." monad)
["#/" // #_
[reference (#+ Register)]
["#." synthesis (#+ Synthesis Path)]]]]])
@@ -38,7 +38,7 @@
(Operation Expression))
(do ////.monad
[valueO (generate valueS)]
- (wrap (list/fold (function (_ [idx tail?] source)
+ (wrap (list;fold (function (_ [idx tail?] source)
(.let [method (.if tail?
//runtime.product//right
//runtime.product//left)]
@@ -108,15 +108,15 @@
(generate bodyS)
#/////synthesis.Pop
- (/////wrap pop-cursor!)
+ (////;wrap pop-cursor!)
(#/////synthesis.Bind register)
- (/////wrap (_.define (..register register) [(list) #.None]
+ (////;wrap (_.define (..register register) [(list) #.None]
cursor-top))
(^template [<tag> <format> <=>]
(^ (<tag> value))
- (/////wrap (_.when (|> value <format> (<=> cursor-top) _.not/1)
+ (////;wrap (_.when (|> value <format> (<=> cursor-top) _.not/1)
fail-pm!)))
([/////synthesis.path/bit //primitive.bit _.eqv?/2]
[/////synthesis.path/i64 (<| //primitive.i64 .int) _.=/2]
@@ -125,7 +125,7 @@
(^template [<pm> <flag> <prep>]
(^ (<pm> idx))
- (/////wrap (_.let (list [@temp (|> idx <prep> .int _.int (//runtime.sum//get cursor-top <flag>))])
+ (////;wrap (_.let (list [@temp (|> idx <prep> .int _.int (//runtime.sum//get cursor-top <flag>))])
(_.if (_.null?/1 @temp)
fail-pm!
(push-cursor! @temp)))))
@@ -134,7 +134,7 @@
(^template [<pm> <getter> <prep>]
(^ (<pm> idx))
- (/////wrap (|> idx <prep> .int _.int (<getter> cursor-top) push-cursor!)))
+ (////;wrap (|> idx <prep> .int _.int (<getter> cursor-top) push-cursor!)))
([/////synthesis.member/left //runtime.product//left (<|)]
[/////synthesis.member/right //runtime.product//right inc])
diff --git a/stdlib/source/lux/tool/compiler/phase/generation/scheme/extension/common.jvm.lux b/stdlib/source/lux/tool/compiler/phase/generation/scheme/extension/common.jvm.lux
index bcb98f893..950a32e1d 100644
--- a/stdlib/source/lux/tool/compiler/phase/generation/scheme/extension/common.jvm.lux
+++ b/stdlib/source/lux/tool/compiler/phase/generation/scheme/extension/common.jvm.lux
@@ -10,7 +10,7 @@
format]
[number (#+ hex)]
[collection
- ["." list ("#/." functor)]
+ ["." list ("#;." functor)]
["dict" dictionary (#+ Dictionary)]]]
["." macro (#+ with-gensyms)
["." code]
@@ -46,7 +46,7 @@
(^ (list (~+ g!input+)))
(do /////.monad
[(~+ (|> g!input+
- (list/map (function (_ g!input)
+ (list;map (function (_ g!input)
(list g!input (` ((~ g!phase) (~ g!input))))))
list.concat))]
((~' wrap) ((~ g!extension) [(~+ g!input+)])))
diff --git a/stdlib/source/lux/tool/compiler/phase/generation/scheme/function.jvm.lux b/stdlib/source/lux/tool/compiler/phase/generation/scheme/function.jvm.lux
index dea1064e1..2cbb89825 100644
--- a/stdlib/source/lux/tool/compiler/phase/generation/scheme/function.jvm.lux
+++ b/stdlib/source/lux/tool/compiler/phase/generation/scheme/function.jvm.lux
@@ -8,7 +8,7 @@
[text
format]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
[host
["_" scheme (#+ Expression Computation Var)]]]
["." // #_
@@ -17,7 +17,7 @@
["#." case]
["#/" //
["#." reference]
- ["#/" // ("#/." monad)
+ ["#/" // ("#;." monad)
["#/" // #_
[reference (#+ Register Variable)]
[analysis (#+ Variant Tuple Environment Arity Abstraction Application Analysis)]
@@ -35,7 +35,7 @@
(def: (with-closure function-name inits function-definition)
(-> Text (List Expression) Computation (Operation Computation))
- (/////wrap
+ (////;wrap
(case inits
#.Nil
function-definition
@@ -44,7 +44,7 @@
(let [@closure (_.var (format function-name "___CLOSURE"))]
(_.letrec (list [@closure
(_.lambda [(|> (list.enumerate inits)
- (list/map (|>> product.left ..capture)))
+ (list;map (|>> product.left ..capture)))
#.None]
function-definition)])
(_.apply/* @closure inits))))))
@@ -76,7 +76,7 @@
(<| (_.if (|> @num-args (_.=/2 arityO))
(<| (_.let (list [(//case.register 0) @function]))
(_.let-values (list [[(|> (list.indices arity)
- (list/map ..input))
+ (list;map ..input))
#.None]
(_.apply/2 (_.global "apply") (_.global "values") @curried)]))
bodyO))
diff --git a/stdlib/source/lux/tool/compiler/phase/generation/scheme/loop.jvm.lux b/stdlib/source/lux/tool/compiler/phase/generation/scheme/loop.jvm.lux
index e5038dc58..7064c8301 100644
--- a/stdlib/source/lux/tool/compiler/phase/generation/scheme/loop.jvm.lux
+++ b/stdlib/source/lux/tool/compiler/phase/generation/scheme/loop.jvm.lux
@@ -7,7 +7,7 @@
["." text
format]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
[host
["_" scheme (#+ Computation Var)]]]
["." // #_
@@ -28,7 +28,7 @@
(generate bodyS))]
(wrap (_.letrec (list [@scope (_.lambda [(|> initsS+
list.enumerate
- (list/map (|>> product.left (n/+ start) //case.register)))
+ (list;map (|>> product.left (n/+ start) //case.register)))
#.None]
bodyO)])
(_.apply/* @scope initsO+)))))
diff --git a/stdlib/source/lux/tool/compiler/phase/generation/scheme/runtime.jvm.lux b/stdlib/source/lux/tool/compiler/phase/generation/scheme/runtime.jvm.lux
index a3490be46..62245a659 100644
--- a/stdlib/source/lux/tool/compiler/phase/generation/scheme/runtime.jvm.lux
+++ b/stdlib/source/lux/tool/compiler/phase/generation/scheme/runtime.jvm.lux
@@ -2,14 +2,14 @@
[lux #*
["." function]
[control
- ["p" parser ("#/." monad)]
+ ["p" parser ("#;." monad)]
[monad (#+ do)]]
[data
[number (#+ hex)]
[text
format]
[collection
- ["." list ("#/." monad)]]]
+ ["." list ("#;." monad)]]]
[macro
["." code]
["s" syntax (#+ syntax:)]]
@@ -73,7 +73,7 @@
(def: declaration
(s.Syntax [Text (List Text)])
- (p.either (p.and s.local-identifier (p/wrap (list)))
+ (p.either (p.and s.local-identifier (p;wrap (list)))
(s.form (p.and s.local-identifier (p.some s.local-identifier)))))
(syntax: (runtime: {[name args] declaration}
@@ -81,8 +81,8 @@
(let [implementation (code.local-identifier (format "@@" name))
runtime (format prefix "__" (/////name.normalize name))
@runtime (` (_.var (~ (code.text runtime))))
- argsC+ (list/map code.local-identifier args)
- argsLC+ (list/map (|>> /////name.normalize (format "LRV__") code.text (~) (_.var) (`))
+ argsC+ (list;map code.local-identifier args)
+ argsLC+ (list;map (|>> /////name.normalize (format "LRV__") code.text (~) (_.var) (`))
args)
declaration (` ((~ (code.local-identifier name))
(~+ argsC+)))
@@ -104,9 +104,9 @@
_
(` (let [(~+ (|> (list.zip2 argsC+ argsLC+)
- (list/map (function (_ [left right])
+ (list;map (function (_ [left right])
(list left right)))
- list/join))]
+ list;join))]
(_.define (~ @runtime) [(list (~+ argsLC+)) #.None]
(~ definition))))))))))))
@@ -127,10 +127,10 @@
(syntax: #export (with-vars {vars (s.tuple (p.many s.local-identifier))}
body)
(wrap (list (` (let [(~+ (|> vars
- (list/map (function (_ var)
+ (list;map (function (_ var)
(list (code.local-identifier var)
(` (_.var (~ (code.text (format "LRV__" (/////name.normalize var)))))))))
- list/join))]
+ list;join))]
(~ body))))))
(runtime: (lux//try op)
diff --git a/stdlib/source/lux/tool/compiler/phase/macro.lux b/stdlib/source/lux/tool/compiler/phase/macro.lux
index 0aca19898..a8428a1ac 100644
--- a/stdlib/source/lux/tool/compiler/phase/macro.lux
+++ b/stdlib/source/lux/tool/compiler/phase/macro.lux
@@ -9,7 +9,7 @@
format]
[collection
[array (#+ Array)]
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
["." macro]
["." host (#+ import:)]]
["." //])
@@ -18,7 +18,7 @@
(exception.report
["Macro" (%name macro)]
["Inputs" (|> inputs
- (list/map (|>> %code (format text.new-line text.tab)))
+ (list;map (|>> %code (format text.new-line text.tab)))
(text.join-with ""))]
["Error" error]))
@@ -26,7 +26,7 @@
(exception.report
["Macro" (%name macro)]
["Inputs" (|> inputs
- (list/map (|>> %code (format text.new-line text.tab)))
+ (list;map (|>> %code (format text.new-line text.tab)))
(text.join-with ""))]))
(import: #long java/lang/reflect/Method
diff --git a/stdlib/source/lux/tool/compiler/phase/synthesis.lux b/stdlib/source/lux/tool/compiler/phase/synthesis.lux
index c5152ff6a..3da088ccf 100644
--- a/stdlib/source/lux/tool/compiler/phase/synthesis.lux
+++ b/stdlib/source/lux/tool/compiler/phase/synthesis.lux
@@ -7,12 +7,12 @@
["." maybe]
["." error]
[collection
- ["." list ("#/." functor)]
+ ["." list ("#;." functor)]
["." dictionary (#+ Dictionary)]]]]
["." / #_
["#." function]
["#." case]
- ["#/" // ("#/." monad)
+ ["#/" // ("#;." monad)
["#." extension]
["#/" // #_
["#." analysis (#+ Analysis)]
@@ -42,7 +42,7 @@
Phase
(case analysis
(#///analysis.Primitive analysis')
- (///wrap (#/.Primitive (..primitive analysis')))
+ (//;wrap (#/.Primitive (..primitive analysis')))
(#///analysis.Structure structure)
(case structure
@@ -54,10 +54,10 @@
(#///analysis.Tuple tuple)
(|> tuple
(monad.map //.monad phase)
- (///map (|>> /.tuple))))
+ (//;map (|>> /.tuple))))
(#///analysis.Reference reference)
- (///wrap (#/.Reference reference))
+ (//;wrap (#/.Reference reference))
(#///analysis.Case inputA branchesAB+)
(/case.synthesize phase inputA branchesAB+)
@@ -85,5 +85,5 @@
(wrap (#/.Extension [name argsS+])))))))
_
- (///wrap (undefined))
+ (//;wrap (undefined))
))
diff --git a/stdlib/source/lux/tool/compiler/phase/synthesis/case.lux b/stdlib/source/lux/tool/compiler/phase/synthesis/case.lux
index 52d7b09a7..8dd7c342e 100644
--- a/stdlib/source/lux/tool/compiler/phase/synthesis/case.lux
+++ b/stdlib/source/lux/tool/compiler/phase/synthesis/case.lux
@@ -6,14 +6,14 @@
["." monad (#+ do)]]
[data
["." product]
- ["." bit ("#/." equivalence)]
- ["." text ("#/." equivalence)
+ ["." bit ("#;." equivalence)]
+ ["." text ("#;." equivalence)
format]
[number
- ["." frac ("#/." equivalence)]]
+ ["." frac ("#;." equivalence)]]
[collection
- ["." list ("#/." fold monoid)]]]]
- ["." /// ("#/." monad)
+ ["." list ("#;." fold monoid)]]]]
+ ["." /// ("#;." monad)
["#/" //
["#." reference]
["#." analysis (#+ Pattern Match Analysis)]
@@ -33,7 +33,7 @@
(^template [<from> <to>]
(<from> value)
- (////map (|>> (#/.Seq (#/.Test (|> value <to>))))
+ (///;map (|>> (#/.Seq (#/.Test (|> value <to>))))
thenC))
([#////analysis.Bit #/.Bit]
[#////analysis.Nat (<| #/.I64 .i64)]
@@ -48,23 +48,23 @@
thenC)
(#////analysis.Complex (#////analysis.Variant [lefts right? value-pattern]))
- (<| (////map (|>> (#/.Seq (#/.Access (#/.Side (if right?
+ (<| (///;map (|>> (#/.Seq (#/.Access (#/.Side (if right?
(#.Right lefts)
(#.Left lefts)))))))
(path' value-pattern end?)
- (when> [(new> (not end?) [])] [(////map ..clean-up)])
+ (when> [(new> (not end?) [])] [(///;map ..clean-up)])
thenC)
(#////analysis.Complex (#////analysis.Tuple tuple))
(let [tuple::last (dec (list.size tuple))]
- (list/fold (function (_ [tuple::lefts tuple::member] nextC)
+ (list;fold (function (_ [tuple::lefts tuple::member] nextC)
(let [right? (n/= tuple::last tuple::lefts)
end?' (and end? right?)]
- (<| (////map (|>> (#/.Seq (#/.Access (#/.Member (if right?
+ (<| (///;map (|>> (#/.Seq (#/.Access (#/.Member (if right?
(#.Right (dec tuple::lefts))
(#.Left tuple::lefts)))))))
(path' tuple::member end?')
- (when> [(new> (not end?') [])] [(////map ..clean-up)])
+ (when> [(new> (not end?') [])] [(///;map ..clean-up)])
nextC)))
thenC
(list.reverse (list.enumerate tuple))))
@@ -72,7 +72,7 @@
(def: #export (path synthesize pattern bodyA)
(-> Phase Pattern Analysis (Operation Path))
- (path' pattern true (////map (|>> #/.Then) (synthesize bodyA))))
+ (path' pattern true (///;map (|>> #/.Then) (synthesize bodyA))))
(def: #export (weave leftP rightP)
(-> Path Path Path)
@@ -96,10 +96,10 @@
(if (<eq> leftV rightV)
rightP
<default>))
- ([#/.Bit bit/=]
+ ([#/.Bit bit;=]
[#/.I64 "lux i64 ="]
- [#/.F64 frac/=]
- [#/.Text text/=])
+ [#/.F64 frac;=]
+ [#/.Text text;=])
(^template [<access> <side>]
[(#/.Access (<access> (<side> leftL)))
@@ -163,7 +163,7 @@
(do @
[lastSP (path synthesize^ lastP lastA)
prevsSP+ (monad.map @ (product.uncurry (path synthesize^)) prevsPA)]
- (wrap (/.branch/case [inputS (list/fold weave lastSP prevsSP+)])))))]
+ (wrap (/.branch/case [inputS (list;fold weave lastSP prevsSP+)])))))]
(case [headB tailB+]
<let>
<if>
diff --git a/stdlib/source/lux/tool/compiler/phase/synthesis/function.lux b/stdlib/source/lux/tool/compiler/phase/synthesis/function.lux
index 547e684c2..a1bc743c3 100644
--- a/stdlib/source/lux/tool/compiler/phase/synthesis/function.lux
+++ b/stdlib/source/lux/tool/compiler/phase/synthesis/function.lux
@@ -8,11 +8,11 @@
["." text
format]
[collection
- ["." list ("#/." functor monoid fold)]
+ ["." list ("#;." functor monoid fold)]
["dict" dictionary (#+ Dictionary)]]]]
["." // #_
["#." loop (#+ Transform)]
- ["#/" // ("#/." monad)
+ ["#/" // ("#;." monad)
["#/" // #_
["#." reference (#+ Register Variable)]
["#." analysis (#+ Environment Arity Analysis)]
@@ -21,14 +21,14 @@
(exception: #export (cannot-find-foreign-variable-in-environment {foreign Register} {environment Environment})
(ex.report ["Foreign" (%n foreign)]
["Environment" (|> environment
- (list/map ////reference.%variable)
+ (list;map ////reference.%variable)
(text.join-with " "))]))
(def: arity-arguments
(-> Arity (List Synthesis))
(|>> dec
(list.n/range 1)
- (list/map (|>> /.variable/local))))
+ (list;map (|>> /.variable/local))))
(template: #export (self-reference)
(/.variable/local 0))
@@ -54,7 +54,7 @@
## (maybe.default <apply>)))
(^ (/.function/apply [funcS' argsS']))
- (wrap (/.function/apply [funcS' (list/compose argsS' argsS)]))
+ (wrap (/.function/apply [funcS' (list;compose argsS' argsS)]))
_
(wrap <apply>)))))))
@@ -63,7 +63,7 @@
(-> Environment Register (Operation Variable))
(case (list.nth register environment)
(#.Some aliased)
- (////wrap aliased)
+ (///;wrap aliased)
#.None
(///.throw cannot-find-foreign-variable-in-environment [register environment])))
@@ -72,7 +72,7 @@
(-> (-> Synthesis (Operation Synthesis)) Path (Operation Path))
(case path
(#/.Bind register)
- (////wrap (#/.Bind (inc register)))
+ (///;wrap (#/.Bind (inc register)))
(^template [<tag>]
(<tag> left right)
@@ -85,10 +85,10 @@
(#/.Then thenS)
(|> thenS
grow
- (////map (|>> #/.Then)))
+ (///;map (|>> #/.Then)))
_
- (////wrap path)))
+ (///;wrap path)))
(def: (grow-sub-environment super sub)
(-> Environment Environment (Operation Environment))
@@ -96,7 +96,7 @@
(function (_ variable)
(case variable
(#////reference.Local register)
- (////wrap (#////reference.Local (inc register)))
+ (///;wrap (#////reference.Local (inc register)))
(#////reference.Foreign register)
(find-foreign super register)))
@@ -110,30 +110,30 @@
(#////analysis.Variant [lefts right? subS])
(|> subS
(grow environment)
- (////map (|>> [lefts right?] /.variant)))
+ (///;map (|>> [lefts right?] /.variant)))
(#////analysis.Tuple membersS+)
(|> membersS+
(monad.map ///.monad (grow environment))
- (////map (|>> /.tuple))))
+ (///;map (|>> /.tuple))))
(^ (..self-reference))
- (////wrap (/.function/apply [expression (list (/.variable/local 1))]))
+ (///;wrap (/.function/apply [expression (list (/.variable/local 1))]))
(#/.Reference reference)
(case reference
(#////reference.Variable variable)
(case variable
(#////reference.Local register)
- (////wrap (/.variable/local (inc register)))
+ (///;wrap (/.variable/local (inc register)))
(#////reference.Foreign register)
(|> register
(find-foreign environment)
- (////map (|>> /.variable))))
+ (///;map (|>> /.variable))))
(#////reference.Constant constant)
- (////wrap expression))
+ (///;wrap expression))
(#/.Control control)
(case control
@@ -169,7 +169,7 @@
(#/.Recur argumentsS+)
(|> argumentsS+
(monad.map ///.monad (grow environment))
- (////map (|>> /.loop/recur))))
+ (///;map (|>> /.loop/recur))))
(#/.Function function)
(case function
@@ -181,8 +181,8 @@
(#/.Apply funcS argsS+)
(case funcS
(^ (/.function/apply [(..self-reference) pre-argsS+]))
- (////wrap (/.function/apply [(..self-reference)
- (list/compose pre-argsS+ argsS+)]))
+ (///;wrap (/.function/apply [(..self-reference)
+ (list;compose pre-argsS+ argsS+)]))
_
(do ///.monad
@@ -193,10 +193,10 @@
(#/.Extension name argumentsS+)
(|> argumentsS+
(monad.map ///.monad (grow environment))
- (////map (|>> (#/.Extension name))))
+ (///;map (|>> (#/.Extension name))))
_
- (////wrap expression)))
+ (///;wrap expression)))
(def: #export (abstraction phase environment bodyA)
(-> Phase Environment Analysis (Operation Synthesis))
diff --git a/stdlib/source/lux/tool/compiler/phase/synthesis/loop.lux b/stdlib/source/lux/tool/compiler/phase/synthesis/loop.lux
index ce5b5e3be..54bec7b03 100644
--- a/stdlib/source/lux/tool/compiler/phase/synthesis/loop.lux
+++ b/stdlib/source/lux/tool/compiler/phase/synthesis/loop.lux
@@ -4,9 +4,9 @@
["." monad (#+ do)]
["p" parser]]
[data
- ["." maybe ("#/." monad)]
+ ["." maybe ("#;." monad)]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
[macro
["." code]
["." syntax]]]
@@ -114,10 +114,10 @@
#.None))
(#/.Seq leftS rightS)
- (maybe/map (|>> (#/.Seq leftS)) (recur rightS))
+ (maybe;map (|>> (#/.Seq leftS)) (recur rightS))
(#/.Then bodyS)
- (maybe/map (|>> #/.Then) (synthesis-recursion bodyS))
+ (maybe;map (|>> #/.Then) (synthesis-recursion bodyS))
_
#.None)))
@@ -133,10 +133,10 @@
(#/.Case inputS pathS)
(|> pathS
(path-recursion recur)
- (maybe/map (|>> (#/.Case inputS) #/.Branch #/.Control)))
+ (maybe;map (|>> (#/.Case inputS) #/.Branch #/.Control)))
(#/.Let inputS register bodyS)
- (maybe/map (|>> (#/.Let inputS register) #/.Branch #/.Control)
+ (maybe;map (|>> (#/.Let inputS register) #/.Branch #/.Control)
(recur bodyS))
(#/.If inputS thenS elseS)
@@ -187,7 +187,7 @@
([#/.Alt] [#/.Seq])
(#/.Then bodyS)
- (|> bodyS adjust-synthesis (maybe/map (|>> #/.Then)))
+ (|> bodyS adjust-synthesis (maybe;map (|>> #/.Then)))
_
(#.Some pathS))))
@@ -209,7 +209,7 @@
(#////analysis.Tuple membersS+)
(|> membersS+
(monad.map maybe.monad recur)
- (maybe/map (|>> #////analysis.Tuple #/.Structure))))
+ (maybe;map (|>> #////analysis.Tuple #/.Structure))))
(#/.Reference reference)
(case reference
@@ -222,7 +222,7 @@
(^ (////reference.foreign register))
(|> scope-environment
(list.nth register)
- (maybe/map (|>> #////reference.Variable #/.Reference))))
+ (maybe;map (|>> #////reference.Variable #/.Reference))))
(^ (/.branch/case [inputS pathS]))
(do maybe.monad
@@ -256,7 +256,7 @@
(^ (/.loop/recur argsS))
(|> argsS
(monad.map maybe.monad recur)
- (maybe/map (|>> /.loop/recur)))
+ (maybe;map (|>> /.loop/recur)))
(^ (/.function/abstraction [environment arity bodyS]))
@@ -275,7 +275,7 @@
(#/.Extension [name argsS])
(|> argsS
(monad.map maybe.monad recur)
- (maybe/map (|>> [name] #/.Extension)))
+ (maybe;map (|>> [name] #/.Extension)))
_
(#.Some exprS))))
@@ -288,5 +288,5 @@
(proper? bodyS))
(|> bodyS
(adjust environment num-locals)
- (maybe/map (|>> [(inc num-locals) inits] /.loop/scope)))
+ (maybe;map (|>> [(inc num-locals) inits] /.loop/scope)))
#.None)))
diff --git a/stdlib/source/lux/tool/compiler/synthesis.lux b/stdlib/source/lux/tool/compiler/synthesis.lux
index 1e56a90a3..71abfee04 100644
--- a/stdlib/source/lux/tool/compiler/synthesis.lux
+++ b/stdlib/source/lux/tool/compiler/synthesis.lux
@@ -5,11 +5,11 @@
[equivalence (#+ Equivalence)]
["ex" exception (#+ exception:)]]
[data
- ["." bit ("#/." equivalence)]
- ["." text ("#/." equivalence)
+ ["." bit ("#;." equivalence)]
+ ["." text ("#;." equivalence)
format]
[collection
- ["." list ("#/." functor)]
+ ["." list ("#;." functor)]
["." dictionary (#+ Dictionary)]]]]
["." // #_
["#." reference (#+ Register Variable Reference)]
@@ -331,7 +331,7 @@
(#//analysis.Tuple members)
(|> members
- (list/map %synthesis)
+ (list;map %synthesis)
(text.join-with " ")
(text.enclose ["[" "]"])))
@@ -348,14 +348,14 @@
(|> (%synthesis body)
(format (%n arity) " ")
(format (|> environment
- (list/map //reference.%variable)
+ (list;map //reference.%variable)
(text.join-with " ")
(text.enclose ["[" "]"]))
" ")
(text.enclose ["(" ")"]))
(#Apply func args)
- (|> (list/map %synthesis args)
+ (|> (list;map %synthesis args)
(text.join-with " ")
(format (%synthesis func) " ")
(text.enclose ["(" ")"])))
@@ -379,7 +379,7 @@
"???")
(#Extension [name args])
- (|> (list/map %synthesis args)
+ (|> (list;map %synthesis args)
(text.join-with " ")
(format (%t name))
(text.enclose ["(" ")"]))))
@@ -394,9 +394,9 @@
(^template [<tag> <eq> <format>]
[(<tag> reference') (<tag> sample')]
(<eq> reference' sample'))
- ([#Bit bit/= %b]
+ ([#Bit bit;= %b]
[#F64 f/= %f]
- [#Text text/= %t])
+ [#Text text;= %t])
[(#I64 reference') (#I64 sample')]
(i/= (.int reference') (.int sample'))
diff --git a/stdlib/source/lux/tool/interpreter.lux b/stdlib/source/lux/tool/interpreter.lux
index 4edc6067a..a92543546 100644
--- a/stdlib/source/lux/tool/interpreter.lux
+++ b/stdlib/source/lux/tool/interpreter.lux
@@ -5,7 +5,7 @@
["ex" exception (#+ exception:)]]
[data
["." error (#+ Error)]
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format]]
[type (#+ :share)
["." check]]
@@ -205,7 +205,7 @@
(:: Console<!> write "> "))
line (:: Console<!> read-line)]
(if (and (not multi-line?)
- (text/= ..exit-command line))
+ (text;= ..exit-command line))
(:: Console<!> write ..farewell-message)
(case (read-eval-print (update@ #source (add-line line) context))
(#error.Success [context' representation])
diff --git a/stdlib/source/lux/tool/mediator/parallelism.lux b/stdlib/source/lux/tool/mediator/parallelism.lux
index c694f0490..d26f93372 100644
--- a/stdlib/source/lux/tool/mediator/parallelism.lux
+++ b/stdlib/source/lux/tool/mediator/parallelism.lux
@@ -4,15 +4,15 @@
["." monad (#+ Monad do)]
["ex" exception (#+ exception:)]]
[concurrency
- ["." promise (#+ Promise) ("#/." functor)]
+ ["." promise (#+ Promise) ("#;." functor)]
["." task (#+ Task)]
["." stm (#+ Var STM)]]
[data
- ["." error (#+ Error) ("#/." monad)]
- ["." text ("#/." equivalence)
+ ["." error (#+ Error) ("#;." monad)]
+ ["." text ("#;." equivalence)
format]
[collection
- ["." list ("#/." functor)]
+ ["." list ("#;." functor)]
["." dictionary (#+ Dictionary)]]]
["." io]]
["." // (#+ Source Mediator)
@@ -40,7 +40,7 @@
(def: (self-dependence? module dependency)
(-> Module Module Bit)
- (text/= module dependency))
+ (text;= module dependency))
(def: (circular-dependence? active dependency)
(-> Active-Compilations Module Bit)
@@ -73,15 +73,15 @@
(def: (share-compilation archive pending)
(-> Active-Compilations Pending-Compilation (Task Archive))
- (promise/map (|>> (error/map (function (_ document)
+ (promise;map (|>> (error;map (function (_ document)
(archive.add module document archive)))
- error/join)
+ error;join)
pending))
(def: (import Monad<!> mediate archive dependencies)
(All [!] (-> (Monad !) (Mediator !) Active-Compilations (List Module) (! (List Archive))))
(|> dependencies
- (list/map (mediate archive))
+ (list;map (mediate archive))
(monad.seq Monad<!>)))
(def: (step-compilation archive imports [dependencies process])
@@ -145,7 +145,7 @@
[#let [[dependencies process] compilation]
_ (ensure-valid-dependencies! active dependencies (get@ #compiler.module input))
imports (import @ mediate archive dependencies)
- [archive' next] (promise/wrap (step-compilation archive imports compilation))]
+ [archive' next] (promise;wrap (step-compilation archive imports compilation))]
(case next
(#.Left continue)
(recur archive' continue)
diff --git a/stdlib/source/lux/type.lux b/stdlib/source/lux/type.lux
index f18544494..5cc89acb5 100644
--- a/stdlib/source/lux/type.lux
+++ b/stdlib/source/lux/type.lux
@@ -5,14 +5,14 @@
[monad (#+ Monad do)]
["p" parser]]
[data
- ["." text ("#/." monoid equivalence)]
- ["." name ("#/." equivalence codec)]
+ ["." text ("#;." monoid equivalence)]
+ ["." name ("#;." equivalence codec)]
[number
- ["." nat ("#/." decimal)]]
+ ["." nat ("#;." decimal)]]
["." maybe]
[collection
["." array]
- ["." list ("#/." functor monoid fold)]]]
+ ["." list ("#;." functor monoid fold)]]]
["." macro
["." code]
["s" syntax (#+ Syntax syntax:)]]])
@@ -21,7 +21,7 @@
(-> (List Type) Type Type)
(case type
(#.Primitive name params)
- (#.Primitive name (list/map (beta-reduce env) params))
+ (#.Primitive name (list;map (beta-reduce env) params))
(^template [<tag>]
(<tag> left right)
@@ -36,12 +36,12 @@
(<tag> env def)
_
- (<tag> (list/map (beta-reduce env) old-env) def)))
+ (<tag> (list;map (beta-reduce env) old-env) def)))
([#.UnivQ]
[#.ExQ])
(#.Parameter idx)
- (maybe.default (error! (text/compose "Unknown type var: " (nat/encode idx)))
+ (maybe.default (error! (text;compose "Unknown type var: " (nat;encode idx)))
(list.nth idx env))
_
@@ -52,9 +52,9 @@
(def: (= x y)
(case [x y]
[(#.Primitive xname xparams) (#.Primitive yname yparams)]
- (and (text/= xname yname)
+ (and (text;= xname yname)
(n/= (list.size yparams) (list.size xparams))
- (list/fold (.function (_ [x y] prev) (and prev (= x y)))
+ (list;fold (.function (_ [x y] prev) (and prev (= x y)))
#1
(list.zip2 xparams yparams)))
@@ -69,7 +69,7 @@
(= xright yright))
[(#.Named xname xtype) (#.Named yname ytype)]
- (and (name/= xname yname)
+ (and (name;= xname yname)
(= xtype ytype))
(^template [<tag>]
@@ -81,7 +81,7 @@
[(#.ExQ xenv xbody) (#.ExQ yenv ybody)])
(and (n/= (list.size yenv) (list.size xenv))
(= xbody ybody)
- (list/fold (.function (_ [x y] prev) (and prev (= x y)))
+ (list;fold (.function (_ [x y] prev) (and prev (= x y)))
#1
(list.zip2 xenv yenv)))
@@ -120,7 +120,7 @@
(case type
(#.Apply arg func')
(let [[func args] (flatten-application func')]
- [func (list/compose args (list arg))])
+ [func (list;compose args (list arg))])
_
[type (list)]))
@@ -168,7 +168,7 @@
(case type
(#.Primitive name params)
(` (#.Primitive (~ (code.text name))
- (.list (~+ (list/map to-code params)))))
+ (.list (~+ (list;map to-code params)))))
(^template [<tag>]
(<tag> idx)
@@ -186,7 +186,7 @@
(^template [<tag>]
(<tag> env body)
- (` (<tag> (.list (~+ (list/map to-code env)))
+ (` (<tag> (.list (~+ (list;map to-code env)))
(~ (to-code body)))))
([#.UnivQ] [#.ExQ])
))
@@ -197,54 +197,54 @@
(#.Primitive name params)
(case params
#.Nil
- ($_ text/compose "(primitive " name ")")
+ ($_ text;compose "(primitive " name ")")
_
- ($_ text/compose "(primitive " name " " (|> params (list/map to-text) list.reverse (list.interpose " ") (list/fold text/compose "")) ")"))
+ ($_ text;compose "(primitive " name " " (|> params (list;map to-text) list.reverse (list.interpose " ") (list;fold text;compose "")) ")"))
(^template [<tag> <open> <close> <flatten>]
(<tag> _)
- ($_ text/compose <open>
+ ($_ text;compose <open>
(|> (<flatten> type)
- (list/map to-text)
+ (list;map to-text)
list.reverse
(list.interpose " ")
- (list/fold text/compose ""))
+ (list;fold text;compose ""))
<close>))
([#.Sum "(| " ")" flatten-variant]
[#.Product "[" "]" flatten-tuple])
(#.Function input output)
(let [[ins out] (flatten-function type)]
- ($_ text/compose "(-> "
+ ($_ text;compose "(-> "
(|> ins
- (list/map to-text)
+ (list;map to-text)
list.reverse
(list.interpose " ")
- (list/fold text/compose ""))
+ (list;fold text;compose ""))
" " (to-text out) ")"))
(#.Parameter idx)
- (nat/encode idx)
+ (nat;encode idx)
(#.Var id)
- ($_ text/compose "⌈v:" (nat/encode id) "⌋")
+ ($_ text;compose "⌈v:" (nat;encode id) "⌋")
(#.Ex id)
- ($_ text/compose "⟨e:" (nat/encode id) "⟩")
+ ($_ text;compose "⟨e:" (nat;encode id) "⟩")
(#.Apply param fun)
(let [[type-func type-args] (flatten-application type)]
- ($_ text/compose "(" (to-text type-func) " " (|> type-args (list/map to-text) list.reverse (list.interpose " ") (list/fold text/compose "")) ")"))
+ ($_ text;compose "(" (to-text type-func) " " (|> type-args (list;map to-text) list.reverse (list.interpose " ") (list;fold text;compose "")) ")"))
(^template [<tag> <desc>]
(<tag> env body)
- ($_ text/compose "(" <desc> " {" (|> env (list/map to-text) (text.join-with " ")) "} " (to-text body) ")"))
+ ($_ text;compose "(" <desc> " {" (|> env (list;map to-text) (text.join-with " ")) "} " (to-text body) ")"))
([#.UnivQ "All"]
[#.ExQ "Ex"])
(#.Named [module name] type)
- ($_ text/compose module "." name)
+ ($_ text;compose module "." name)
))
(def: #export (un-alias type)
@@ -342,9 +342,9 @@
(do @
[cursor macro.cursor
valueT (macro.find-type valueN)
- #let [_ (log! ($_ text/compose
+ #let [_ (log! ($_ text;compose
":log!" " @ " (.cursor-description cursor) text.new-line
- (name/encode valueN) " : " (..to-text valueT) text.new-line))]]
+ (name;encode valueN) " : " (..to-text valueT) text.new-line))]]
(wrap (list (code.identifier valueN))))
(#.Right valueC)
@@ -360,7 +360,7 @@
input
output
{value (p.maybe s.any)})
- (let [casterC (` (: (All [(~+ (list/map code.local-identifier type-vars))]
+ (let [casterC (` (: (All [(~+ (list;map code.local-identifier type-vars))]
(-> (~ input) (~ output)))
(|>> :assume)))]
(case value
@@ -383,7 +383,7 @@
{exemplar typed}
{computation typed})
(macro.with-gensyms [g!_]
- (let [shareC (` (: (All [(~+ (list/map code.local-identifier type-vars))]
+ (let [shareC (` (: (All [(~+ (list;map code.local-identifier type-vars))]
(-> (~ (get@ #type exemplar))
(~ (get@ #type computation))))
(.function ((~ g!_) (~ g!_))
@@ -394,7 +394,7 @@
(syntax: #export (:by-example {type-vars type-parameters}
{exemplar typed}
{extraction s.any})
- (wrap (list (` (:of (:share [(~+ (list/map code.local-identifier type-vars))]
+ (wrap (list (` (:of (:share [(~+ (list;map code.local-identifier type-vars))]
{(~ (get@ #type exemplar))
(~ (get@ #expression exemplar))}
{(~ extraction)
diff --git a/stdlib/source/lux/type/abstract.lux b/stdlib/source/lux/type/abstract.lux
index e59596b4d..6190c6dab 100644
--- a/stdlib/source/lux/type/abstract.lux
+++ b/stdlib/source/lux/type/abstract.lux
@@ -2,15 +2,15 @@
[lux (#- Scope)
[control
[monad (#+ Monad do)]
- ["p" parser ("#/." monad)]
+ ["p" parser ("#;." monad)]
["ex" exception (#+ exception:)]]
[data
- ["." name ("#/." codec)]
- ["." text ("#/." equivalence monoid)]
+ ["." name ("#;." codec)]
+ ["." text ("#;." equivalence monoid)]
[collection
- ["." list ("#/." functor monoid)]
+ ["." list ("#;." functor monoid)]
["." stack (#+ Stack)]]]
- ["." macro ("#/." monad)
+ ["." macro ("#;." monad)
["." code]
["s" syntax (#+ Syntax syntax:)]
[syntax
@@ -33,7 +33,7 @@
(loop [entries <source>]
(case entries
(#.Cons [head-name head-content] tail)
- (if (text/= <reference> head-name)
+ (if (text;= <reference> head-name)
<then>
(recur tail))
@@ -62,7 +62,7 @@
(case (case scope
(#.Some scope)
(list.find (function (_ [actual _])
- (text/= scope actual))
+ (text;= scope actual))
current-scopes)
#.None
@@ -77,7 +77,7 @@
(loop [entries <source>]
(case entries
(#.Cons [head-name head-content] tail)
- (if (text/= <reference> head-name)
+ (if (text;= <reference> head-name)
(#.Cons [head-name <then>]
tail)
(#.Cons [head-name head-content]
@@ -136,7 +136,7 @@
(def: cast
(Syntax [(Maybe Text) Code])
(p.either (p.and (p.maybe s.local-identifier) s.any)
- (p.and (p/wrap #.None) s.any)))
+ (p.and (p;wrap #.None) s.any)))
(do-template [<name> <from> <to>]
[(syntax: #export (<name> {[scope value] cast})
@@ -151,15 +151,15 @@
(def: abstraction-type-name
(-> Name Text)
- (|>> name/encode
- ($_ text/compose
- (name/encode (name-of #..Abstraction))
+ (|>> name;encode
+ ($_ text;compose
+ (name;encode (name-of #..Abstraction))
" ")))
(def: representation-definition-name
(-> Text Text)
- (|>> ($_ text/compose
- (name/encode (name-of #Representation))
+ (|>> ($_ text;compose
+ (name;encode (name-of #Representation))
" ")))
(def: declaration
@@ -177,7 +177,7 @@
{primitives (p.some s.any)})
(do @
[current-module macro.current-module-name
- #let [type-varsC (list/map code.local-identifier type-vars)
+ #let [type-varsC (list;map code.local-identifier type-vars)
abstraction-declaration (` ((~ (code.local-identifier name)) (~+ type-varsC)))
representation-declaration (` ((~ (code.local-identifier (representation-definition-name name)))
(~+ type-varsC)))]
@@ -191,7 +191,7 @@
[(~+ type-varsC)])))
(` (type: (~+ (csw.export export)) (~ representation-declaration)
(~ representation-type)))
- ($_ list/compose
+ ($_ list;compose
primitives
(list (` ((~! ..pop!)))))))))
diff --git a/stdlib/source/lux/type/check.lux b/stdlib/source/lux/type/check.lux
index 42479451c..ce0545caa 100644
--- a/stdlib/source/lux/type/check.lux
+++ b/stdlib/source/lux/type/check.lux
@@ -10,31 +10,31 @@
["." product]
["." error (#+ Error)]
[number
- ["." nat ("#/." decimal)]]
- ["." text ("#/." monoid equivalence)]
+ ["." nat ("#;." decimal)]]
+ ["." text ("#;." monoid equivalence)]
[collection
["." list]
["." set (#+ Set)]]]]
- ["." // ("#/." equivalence)])
+ ["." // ("#;." equivalence)])
(template: (!n/= reference subject)
("lux i64 =" subject reference))
-(template: (!text/= reference subject)
+(template: (!text;= reference subject)
("lux text =" subject reference))
(exception: #export (unknown-type-var {id Nat})
- (ex.report ["ID" (nat/encode id)]))
+ (ex.report ["ID" (nat;encode id)]))
(exception: #export (unbound-type-var {id Nat})
- (ex.report ["ID" (nat/encode id)]))
+ (ex.report ["ID" (nat;encode id)]))
(exception: #export (invalid-type-application {funcT Type} {argT Type})
(ex.report ["Type function" (//.to-text funcT)]
["Type argument" (//.to-text argT)]))
(exception: #export (cannot-rebind-var {id Nat} {type Type} {bound Type})
- (ex.report ["Var" (nat/encode id)]
+ (ex.report ["Var" (nat;encode id)]
["Wanted Type" (//.to-text type)]
["Current Type" (//.to-text bound)]))
@@ -104,7 +104,7 @@
)))
)
-(open: "check/." ..monad)
+(open: "check;." ..monad)
(def: (var::get id plist)
(-> Var Type-Vars (Maybe (Maybe Type)))
@@ -253,7 +253,7 @@
_
(case (//.apply (list argT) funcT)
(#.Some output)
- (check/wrap output)
+ (check;wrap output)
_
(throw invalid-type-application [funcT argT]))))
@@ -327,8 +327,8 @@
(def: (assumed? [e a] assumptions)
(-> Assumption (List Assumption) Bit)
(list.any? (function (_ [e' a'])
- (and (///= e e')
- (///= a a')))
+ (and (//;= e e')
+ (//;= a a')))
assumptions))
(def: (assume! assumption assumptions)
@@ -374,7 +374,7 @@
Var Var
(Check (List Assumption)))
(if (!n/= idE idA)
- (check/wrap assumptions)
+ (check;wrap assumptions)
(do ..monad
[ebound (attempt (peek idE))
abound (attempt (peek idA))]
@@ -447,7 +447,7 @@
(on-error [])
_
- ($_ text/compose
+ ($_ text;compose
(on-error [])
text.new-line text.new-line
"-----------------------------------------"
@@ -514,7 +514,7 @@
{#.doc "Type-check to ensure that the 'expected' type subsumes the 'actual' type."}
(-> (List Assumption) Type Type (Check (List Assumption)))
(if (is? expected actual)
- (check/wrap assumptions)
+ (check;wrap assumptions)
(with-error-stack
(function (_ _) (ex.construct type-check-failed [expected actual]))
(case [expected actual]
@@ -523,13 +523,13 @@
[(#.Var id) _]
(if-bind id actual
- (check/wrap assumptions)
+ (check;wrap assumptions)
(function (_ bound)
(check' assumptions bound actual)))
[_ (#.Var id)]
(if-bind id expected
- (check/wrap assumptions)
+ (check;wrap assumptions)
(function (_ bound)
(check' assumptions expected bound)))
@@ -544,7 +544,7 @@
[(#.Apply A F) _]
(let [new-assumption [expected actual]]
(if (assumed? new-assumption assumptions)
- (check/wrap assumptions)
+ (check;wrap assumptions)
(do ..monad
[expected' (apply-type! F A)]
(check' (assume! new-assumption assumptions) expected' actual))))
@@ -575,13 +575,13 @@
[#.ExQ ..existential])
[(#.Primitive e-name e-params) (#.Primitive a-name a-params)]
- (if (!text/= e-name a-name)
+ (if (!text;= e-name a-name)
(loop [assumptions assumptions
e-params e-params
a-params a-params]
(case [e-params a-params]
[#.Nil #.Nil]
- (check/wrap assumptions)
+ (check;wrap assumptions)
[(#.Cons e-head e-tail) (#.Cons a-head a-tail)]
(do ..monad
@@ -607,7 +607,7 @@
[(#.Ex e!id) (#.Ex a!id)]
(if (!n/= e!id a!id)
- (check/wrap assumptions)
+ (check;wrap assumptions)
(fail ""))
[(#.Named _ ?etype) _]
@@ -645,17 +645,17 @@
(#.Primitive name paramsT+)
(|> paramsT+
(monad.map ..monad clean)
- (check/map (|>> (#.Primitive name))))
+ (check;map (|>> (#.Primitive name))))
(^or (#.Parameter _) (#.Ex _) (#.Named _))
- (check/wrap inputT)
+ (check;wrap inputT)
(^template [<tag>]
(<tag> leftT rightT)
(do ..monad
[leftT' (clean leftT)]
(|> (clean rightT)
- (check/map (|>> (<tag> leftT'))))))
+ (check;map (|>> (<tag> leftT'))))))
([#.Sum] [#.Product] [#.Function] [#.Apply])
(#.Var id)
diff --git a/stdlib/source/lux/type/implicit.lux b/stdlib/source/lux/type/implicit.lux
index 762352657..1161a45b3 100644
--- a/stdlib/source/lux/type/implicit.lux
+++ b/stdlib/source/lux/type/implicit.lux
@@ -8,10 +8,10 @@
["." product]
["." maybe]
["." number]
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format]
[collection
- ["." list ("#/." monad fold)]
+ ["." list ("#;." monad fold)]
["dict" dictionary (#+ Dictionary)]]]
["." macro
["." code]
@@ -86,8 +86,8 @@
[this-module-name macro.current-module-name
imp-mods (macro.imported-modules this-module-name)
tag-lists (monad.map @ macro.tag-lists imp-mods)
- #let [tag-lists (|> tag-lists list/join (list/map product.left) list/join)
- candidates (list.filter (|>> product.right (text/= simple-name))
+ #let [tag-lists (|> tag-lists list;join (list;map product.left) list;join)
+ candidates (list.filter (|>> product.right (text;= simple-name))
tag-lists)]]
(case candidates
#.Nil
@@ -114,21 +114,21 @@
(|> definitions
(list.filter (function (_ [name [def-type def-anns def-value]])
(macro.struct? def-anns)))
- (list/map (function (_ [name [def-type def-anns def-value]])
+ (list;map (function (_ [name [def-type def-anns def-value]])
[[this-module-name name] def-type]))))
(def: local-env
(Meta (List [Name Type]))
(do macro.monad
[local-batches macro.locals
- #let [total-locals (list/fold (function (_ [name type] table)
+ #let [total-locals (list;fold (function (_ [name type] table)
(dict.put~ name type table))
(: (Dictionary Text Type)
(dict.new text.hash))
- (list/join local-batches))]]
+ (list;join local-batches))]]
(wrap (|> total-locals
dict.entries
- (list/map (function (_ [name type]) [["" name] type]))))))
+ (list;map (function (_ [name type]) [["" name] type]))))))
(def: local-structs
(Meta (List [Name Type]))
@@ -147,7 +147,7 @@
[exports (macro.exports imp-mod)]
(wrap (prepare-definitions imp-mod exports))))
imp-mods)]
- (wrap (list/join export-batches))))
+ (wrap (list;join export-batches))))
(def: (apply-function-type func arg)
(-> Type Type (Check Type))
@@ -203,7 +203,7 @@
(do macro.monad
[compiler macro.get-compiler]
(case (|> alts
- (list/map (function (_ [alt-name alt-type])
+ (list;map (function (_ [alt-name alt-type])
(case (check.run context
(do check.monad
[[tvars alt-type] (concrete-type alt-type)
@@ -217,7 +217,7 @@
(#.Right =deps)
(list [alt-name =deps]))))
- list/join)
+ list;join)
#.Nil
(macro.fail (format "No candidates for provisioning: " (%type dep)))
@@ -252,7 +252,7 @@
[compiler macro.get-compiler
context macro.type-context]
(case (|> alts
- (list/map (function (_ [alt-name alt-type])
+ (list;map (function (_ [alt-name alt-type])
(case (check.run context
(do check.monad
[[tvars alt-type] (concrete-type alt-type)
@@ -268,7 +268,7 @@
(#.Right =deps)
(list [alt-name =deps]))))
- list/join)
+ list;join)
#.Nil
(macro.fail (format "No alternatives for " (%type (type.function input-types output-type))))
@@ -303,7 +303,7 @@
(code.identifier constructor)
_
- (` ((~ (code.identifier constructor)) (~+ (list/map instance$ dependencies))))))
+ (` ((~ (code.identifier constructor)) (~+ (list;map instance$ dependencies))))))
(syntax: #export (:::
{member s.identifier}
@@ -346,19 +346,19 @@
(#.Cons chosen #.Nil)
(wrap (list (` (:: (~ (instance$ chosen))
(~ (code.local-identifier (product.right member)))
- (~+ (list/map code.identifier args))))))
+ (~+ (list;map code.identifier args))))))
_
(macro.fail (format "Too many options available: "
(|> chosen-ones
- (list/map (|>> product.left %name))
+ (list;map (|>> product.left %name))
(text.join-with ", "))
" --- for type: " (%type sig-type)))))
(#.Right [args _])
(do @
[labels (|> (macro.gensym "") (list.repeat (list.size args)) (monad.seq @))]
- (wrap (list (` (let [(~+ (|> (list.zip2 labels args) (list/map join-pair) list/join))]
+ (wrap (list (` (let [(~+ (|> (list.zip2 labels args) (list;map join-pair) list;join))]
(..::: (~ (code.identifier member)) (~+ labels)))))))
))
@@ -376,14 +376,14 @@
(do @
[g!implicit+ (implicit-bindings (list.size structures))]
(wrap (list (` (let [(~+ (|> (list.zip2 g!implicit+ structures)
- (list/map (function (_ [g!implicit structure])
+ (list;map (function (_ [g!implicit structure])
(list g!implicit structure)))
- list/join))]
+ list;join))]
(~ body)))))))
(syntax: #export (implicit: {structures ..implicits})
(do @
[g!implicit+ (implicit-bindings (list.size structures))]
(wrap (|> (list.zip2 g!implicit+ structures)
- (list/map (function (_ [g!implicit structure])
+ (list;map (function (_ [g!implicit structure])
(` (def: (~ g!implicit) (~ structure)))))))))
diff --git a/stdlib/source/lux/type/refinement.lux b/stdlib/source/lux/type/refinement.lux
index 142f77b0e..d39677778 100644
--- a/stdlib/source/lux/type/refinement.lux
+++ b/stdlib/source/lux/type/refinement.lux
@@ -2,7 +2,7 @@
[lux (#- type)
[control
[predicate (#+ Predicate)]]
- [type (#+ :by-example) ("#/." equivalence)
+ [type (#+ :by-example) ("#;." equivalence)
abstract]])
(abstract: #export (Refined t r)
diff --git a/stdlib/source/lux/type/resource.lux b/stdlib/source/lux/type/resource.lux
index 80d16164e..1c8d0be1d 100644
--- a/stdlib/source/lux/type/resource.lux
+++ b/stdlib/source/lux/type/resource.lux
@@ -16,7 +16,7 @@
["dict" dictionary (#+ Dictionary)]
["." set]
["." row (#+ Row)]
- ["." list ("#/." functor fold)]]]
+ ["." list ("#;." functor fold)]]]
[concurrency
["." promise (#+ Promise)]]
["." macro
@@ -155,7 +155,7 @@
(#.Cons head tail)
(do macro.monad
- [#let [max-idx (list/fold n/max head tail)]
+ [#let [max-idx (list;fold n/max head tail)]
g!inputs (<| (monad.seq @) (list.repeat (inc max-idx)) (macro.gensym "input"))
#let [g!outputs (|> (monad.fold maybe.monad
(function (_ from to)
@@ -166,8 +166,8 @@
swaps)
maybe.assume
row.to-list)
- g!inputsT+ (list/map (|>> (~) ..CK (`)) g!inputs)
- g!outputsT+ (list/map (|>> (~) ..CK (`)) g!outputs)]]
+ g!inputsT+ (list;map (|>> (~) ..CK (`)) g!inputs)
+ g!outputsT+ (list;map (|>> (~) ..CK (`)) g!outputs)]]
(wrap (list (` (: (All [(~+ g!inputs) (~ g!context)]
(Procedure (~! <m>)
[(~+ g!inputsT+) (~ g!context)]
diff --git a/stdlib/source/lux/world/db/jdbc.jvm.lux b/stdlib/source/lux/world/db/jdbc.jvm.lux
index 285eff34a..b91bb2a72 100644
--- a/stdlib/source/lux/world/db/jdbc.jvm.lux
+++ b/stdlib/source/lux/world/db/jdbc.jvm.lux
@@ -6,7 +6,7 @@
[monad (#+ Monad do)]
["ex" exception]
[concurrency
- ["." promise (#+ Promise) ("#/." monad)]]
+ ["." promise (#+ Promise) ("#;." monad)]]
[security
["!" capability (#+ capability:)]]]
[data
@@ -15,7 +15,7 @@
[text
format]
[collection
- ["." list ("#/." fold)]]]
+ ["." list ("#;." fold)]]]
["." io (#+ IO)]
[world
[net (#+ URL)]]
@@ -171,5 +171,5 @@
(do (error.with promise.monad)
[db (promise.future (..connect creds))
result (action (..async db))
- _ (promise/wrap (io.run (!.use (:: db close) [])))]
+ _ (promise;wrap (io.run (!.use (:: db close) [])))]
(wrap result)))
diff --git a/stdlib/source/lux/world/db/jdbc/input.jvm.lux b/stdlib/source/lux/world/db/jdbc/input.jvm.lux
index 8e1797ab0..dc6ef141c 100644
--- a/stdlib/source/lux/world/db/jdbc/input.jvm.lux
+++ b/stdlib/source/lux/world/db/jdbc/input.jvm.lux
@@ -6,7 +6,7 @@
[data
["." error (#+ Error)]
[collection
- ["." list ("#/." fold)]]]
+ ["." list ("#;." fold)]]]
[time
["." instant (#+ Instant)]]
["." io (#+ IO)]
diff --git a/stdlib/source/lux/world/db/sql.lux b/stdlib/source/lux/world/db/sql.lux
index fc53fc099..94563bdf1 100644
--- a/stdlib/source/lux/world/db/sql.lux
+++ b/stdlib/source/lux/world/db/sql.lux
@@ -3,10 +3,10 @@
[control
[monad (#+ do)]]
[data
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
[type
abstract]])
@@ -107,7 +107,7 @@
(def: enumerate
(-> (List (SQL Any)) Text)
- (|>> (list/map (|>> :representation))
+ (|>> (list;map (|>> :representation))
(text.join-with ", ")))
## Value
@@ -214,8 +214,8 @@
_
(|> columns
- (list/map (.function (_ [column alias])
- (if (text/= ..no-alias alias)
+ (list;map (.function (_ [column alias])
+ (if (text;= ..no-alias alias)
(:representation column)
(format (:representation column) " AS " alias))))
(text.join-with ", ")))
@@ -295,7 +295,7 @@
(format (:representation query)
" ORDER BY "
(|> pairs
- (list/map (.function (_ [value order])
+ (list;map (.function (_ [value order])
(format (:representation value) " " (:representation order))))
(text.join-with ", "))))))
@@ -322,7 +322,7 @@
(..parenthesize (..enumerate columns))
" VALUES "
(|> rows
- (list/map (|>> ..enumerate ..parenthesize))
+ (list;map (|>> ..enumerate ..parenthesize))
(text.join-with ", "))
)))
@@ -335,7 +335,7 @@
_
(format " SET " (|> pairs
- (list/map (.function (_ [column value])
+ (list;map (.function (_ [column value])
(format (:representation column) "=" (:representation value))))
(text.join-with ", ")))))))
diff --git a/stdlib/source/lux/world/file.lux b/stdlib/source/lux/world/file.lux
index b12b2afe6..0f35422b7 100644
--- a/stdlib/source/lux/world/file.lux
+++ b/stdlib/source/lux/world/file.lux
@@ -9,12 +9,12 @@
["!" capability (#+ capability:)]]]
[data
["." maybe]
- ["." error (#+ Error) ("#/." functor)]
+ ["." error (#+ Error) ("#;." functor)]
["." text
format]
[collection
["." array (#+ Array)]
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
[time
["." instant (#+ Instant)]
["." duration]]
@@ -22,7 +22,7 @@
["." template]]
[world
["." binary (#+ Binary)]]
- ["." io (#+ IO) ("#/." functor)]
+ ["." io (#+ IO) ("#;." functor)]
[host (#+ import:)]
[tool
[compiler
@@ -114,14 +114,14 @@
[[delete]]]))
(def: move (..can-open
- (|>> (!.use (:: file move)) (io/map (error/map async-file)) promise.future))))))
+ (|>> (!.use (:: file move)) (io;map (error;map async-file)) promise.future))))))
(def: (async-directory directory)
(-> (Directory IO) (Directory Promise))
(`` (structure (~~ (do-template [<name> <async>]
[(def: <name> (..can-query
(|>> (!.use (:: directory <name>))
- (io/map (error/map (list/map <async>)))
+ (io;map (error;map (list;map <async>)))
promise.future)))]
[files ..async-file]
@@ -135,7 +135,7 @@
(`` (structure
(~~ (do-template [<name> <async>]
[(def: <name> (..can-open
- (|>> (!.use (:: system <name>)) (io/map (error/map <async>)) promise.future)))]
+ (|>> (!.use (:: system <name>)) (io;map (error;map <async>)) promise.future)))]
[file ..async-file]
[create-file ..async-file]
@@ -327,7 +327,7 @@
(|> children
array.to-list
(monad.filter @ (|>> <method>))
- (:: @ map (monad.map @ (|>> java/io/File::getAbsolutePath (:: @ map <capability>))))
+ (:: @ map (monad.map @ (|>> java/io/File::getAbsolutePath (:: @ map <capability>))))
(:: @ join))
#.None
diff --git a/stdlib/source/lux/world/net/http/cookie.lux b/stdlib/source/lux/world/net/http/cookie.lux
index 4f10a6dc8..8bb3285ad 100644
--- a/stdlib/source/lux/world/net/http/cookie.lux
+++ b/stdlib/source/lux/world/net/http/cookie.lux
@@ -2,7 +2,7 @@
[lux #*
[control
[monad (#+ do)]
- ["p" parser ("#/." monad)]]
+ ["p" parser ("#;." monad)]]
[data
["." error (#+ Error)]
[text
@@ -78,7 +78,7 @@
[context' (..cookie context)
_ (l.this "; ")]
(cookies context'))
- (p/wrap context)))
+ (p;wrap context)))
(def: #export (get header)
(-> Text (Error Context))
diff --git a/stdlib/source/lux/world/net/http/request.lux b/stdlib/source/lux/world/net/http/request.lux
index fac71de93..e13ae884d 100644
--- a/stdlib/source/lux/world/net/http/request.lux
+++ b/stdlib/source/lux/world/net/http/request.lux
@@ -16,7 +16,7 @@
["." json (#+ JSON)]
["." context (#+ Context Property)]]
[collection
- ["." list ("#/." functor fold)]
+ ["." list ("#;." functor fold)]
["." dictionary]]]
[world
["." binary (#+ Binary)]]]
@@ -34,8 +34,8 @@
(:: error.functor map (|>> [(n/+ amount offset)])
(binary.copy amount 0 input offset output))))
[0 (|> inputs
- (list/map binary.size)
- (list/fold n/+ 0)
+ (list;map binary.size)
+ (list;fold n/+ 0)
binary.create)]
inputs))]
output))
diff --git a/stdlib/source/lux/world/net/http/response.lux b/stdlib/source/lux/world/net/http/response.lux
index 93d6f0df9..bac0fcaaa 100644
--- a/stdlib/source/lux/world/net/http/response.lux
+++ b/stdlib/source/lux/world/net/http/response.lux
@@ -3,7 +3,7 @@
[control
[concurrency
["." promise]
- ["." frp ("#/." monad)]]]
+ ["." frp ("#;." monad)]]]
[data
["." text
format
@@ -12,7 +12,7 @@
["." html]
["." css (#+ CSS)]
["." context]
- ["." json (#+ JSON) ("#/." codec)]]]
+ ["." json (#+ JSON) ("#;." codec)]]]
["." io]
[world
["." binary (#+ Binary)]]]
@@ -29,7 +29,7 @@
(def: #export empty
(-> Status Response)
- (let [body (frp/wrap (encoding.to-utf8 ""))]
+ (let [body (frp;wrap (encoding.to-utf8 ""))]
(function (_ status)
[status
{#//.headers (|> context.empty
@@ -52,7 +52,7 @@
{#//.headers (|> context.empty
(header.content-length (binary.size data))
(header.content-type type))
- #//.body (frp/wrap data)}])
+ #//.body (frp;wrap data)}])
(def: #export bad-request
(-> Text Response)
diff --git a/stdlib/source/lux/world/net/http/route.lux b/stdlib/source/lux/world/net/http/route.lux
index 4359735c6..b3e3c3639 100644
--- a/stdlib/source/lux/world/net/http/route.lux
+++ b/stdlib/source/lux/world/net/http/route.lux
@@ -6,7 +6,7 @@
["." promise]]]
[data
["." maybe]
- ["." text ("#/." equivalence)]]]
+ ["." text ("#;." equivalence)]]]
["." // (#+ URI Server)
["#." status]
["#." response]])
diff --git a/stdlib/source/lux/world/service/journal.lux b/stdlib/source/lux/world/service/journal.lux
index 1bd9c3fda..6a2e8ff90 100644
--- a/stdlib/source/lux/world/service/journal.lux
+++ b/stdlib/source/lux/world/service/journal.lux
@@ -7,9 +7,9 @@
["!" capability (#+ capability:)]]]
[data
[error (#+ Error)]
- ["." text ("#/." equivalence)]]
+ ["." text ("#;." equivalence)]]
[time
- ["." instant (#+ Instant) ("#/." equivalence)]]])
+ ["." instant (#+ Instant) ("#;." equivalence)]]])
(type: #export (Entry a)
{#what a
@@ -29,14 +29,14 @@
(def: bottom start)
(def: top end)))
-(structure: #export (equivalence (^open "_/."))
+(structure: #export (equivalence (^open "_;."))
(All [a] (-> (Equivalence a) (Equivalence (Entry a))))
(def: (= reference sample)
- (and (_/= (get@ #what reference) (get@ #what sample))
- (text/= (get@ #why reference) (get@ #why sample))
- (text/= (get@ #how reference) (get@ #how sample))
- (text/= (get@ #who reference) (get@ #who sample))
- (text/= (get@ #where reference) (get@ #where sample))
+ (and (_;= (get@ #what reference) (get@ #what sample))
+ (text;= (get@ #why reference) (get@ #why sample))
+ (text;= (get@ #how reference) (get@ #how sample))
+ (text;= (get@ #who reference) (get@ #who sample))
+ (text;= (get@ #where reference) (get@ #where sample))
(instant/= (get@ #when reference) (get@ #when sample)))))
(capability: #export (Can-Write ! a)
diff --git a/stdlib/source/lux/world/shell.lux b/stdlib/source/lux/world/shell.lux
index a26d63259..82541c5f3 100644
--- a/stdlib/source/lux/world/shell.lux
+++ b/stdlib/source/lux/world/shell.lux
@@ -16,7 +16,7 @@
["." context (#+ Context)]]
[collection
["." array (#+ Array)]
- ["." list ("#/." fold functor)]
+ ["." list ("#;." fold functor)]
["." dictionary]]]
[tool
[compiler
@@ -39,7 +39,7 @@
dangerous)
indices (list.n/range 0 (dec (text.size dangerous)))]
(function (_ unsafe)
- (list/fold (function (_ index safer)
+ (list;fold (function (_ index safer)
(let [bad (|> dangerous (text.nth index) maybe.assume text.from-code)
good (if windows?
" "
@@ -65,7 +65,7 @@
(def: (arguments-array arguments)
(-> (List Text) (Array java/lang/String))
(product.right
- (list/fold (function (_ argument [idx output])
+ (list;fold (function (_ argument [idx output])
[(inc idx) (jvm.array-write idx argument output)])
[0 (jvm.array java/lang/String (list.size arguments))]
arguments)))
@@ -77,7 +77,7 @@
(-> Context
(java/util/Map java/lang/String java/lang/String)
(java/util/Map java/lang/String java/lang/String))
- (list/fold (function (_ [key value] target')
+ (list;fold (function (_ [key value] target')
(exec (java/util/Map::put key value target')
target'))
target
@@ -154,7 +154,7 @@
[windows? (:: @ map (|>> java/lang/String::toLowerCase ..windows?)
(java/lang/System::getProperty "os.name"))
#let [builder (java/lang/ProcessBuilder::new (arguments-array (list& (sanitize-command windows? command)
- (list/map (sanitize-argument windows?) arguments))))]
+ (list;map (sanitize-argument windows?) arguments))))]
environment (:: @ map (load-environment environment)
(java/lang/ProcessBuilder::environment builder))
process (java/lang/ProcessBuilder::start builder)]
diff --git a/stdlib/source/program/licentia.lux b/stdlib/source/program/licentia.lux
index 0b7bca16f..87ec7a9eb 100644
--- a/stdlib/source/program/licentia.lux
+++ b/stdlib/source/program/licentia.lux
@@ -28,7 +28,7 @@
[format
["." json]]]
["." cli (#+ program:)]
- ["." io (#+ IO) ("#/." monad)]
+ ["." io (#+ IO) ("#;." monad)]
[world
["." file (#+ Path File)]]
[host (#+ import:)]]
@@ -58,7 +58,7 @@
(do (error.with io.monad)
[file (!.use (:: file.system file) input)
blob (!.use (:: file content) [])
- document (io/wrap (do error.monad
+ document (io;wrap (do error.monad
[raw-json (encoding.from-utf8 blob)
json (|> raw-json
(:coerce java/lang/String)
diff --git a/stdlib/source/program/licentia/document.lux b/stdlib/source/program/licentia/document.lux
index 9afbb8d7b..c04cd9d72 100644
--- a/stdlib/source/program/licentia/document.lux
+++ b/stdlib/source/program/licentia/document.lux
@@ -4,7 +4,7 @@
["." text
format]
[collection
- ["." list ("#/." functor)]]]])
+ ["." list ("#;." functor)]]]])
(def: #export (quote text)
(-> Text Text)
@@ -24,7 +24,7 @@
(def: #export paragraph
(-> (List Text) Text)
- (|>> (list/map ..sentence)
+ (|>> (list;map ..sentence)
(text.join-with text.new-line)))
(do-template [<name> <word>]
diff --git a/stdlib/source/program/licentia/license/black-list.lux b/stdlib/source/program/licentia/license/black-list.lux
index 1b1ec2dff..ac5ab8a2c 100644
--- a/stdlib/source/program/licentia/license/black-list.lux
+++ b/stdlib/source/program/licentia/license/black-list.lux
@@ -1,11 +1,11 @@
(.module:
[lux #*
[data
- ["." maybe ("#/." functor)]
+ ["." maybe ("#;." functor)]
["." text
format]
[collection
- ["." list ("#/." functor)]]]]
+ ["." list ("#;." functor)]]]]
["." // (#+ Entity Black-List)
["_" term]
[//
@@ -21,11 +21,11 @@
effect "shall not be granted to the following entities, or any subsidiary thereof"
justification (|> black-list
(get@ #//.justification)
- (maybe/map (|>> (format ", due to ")))
+ (maybe;map (|>> (format ", due to ")))
(maybe.default ""))
entities (|> black-list
(get@ #//.entities)
- (list/map ..entity)
+ (list;map ..entity)
(text.join-with text.new-line))]
(format scope " " effect justification ":" text.new-line
entities)))
diff --git a/stdlib/source/program/licentia/license/commercial.lux b/stdlib/source/program/licentia/license/commercial.lux
index 37b2e2d74..787d92034 100644
--- a/stdlib/source/program/licentia/license/commercial.lux
+++ b/stdlib/source/program/licentia/license/commercial.lux
@@ -4,7 +4,7 @@
["." text
format]
[collection
- ["." list ("#/." monoid)]]]]
+ ["." list ("#;." monoid)]]]]
["." // (#+ Commercial)
["_" term]
[//
diff --git a/stdlib/source/program/licentia/license/distribution.lux b/stdlib/source/program/licentia/license/distribution.lux
index a42a83ba9..077735b2c 100644
--- a/stdlib/source/program/licentia/license/distribution.lux
+++ b/stdlib/source/program/licentia/license/distribution.lux
@@ -4,7 +4,7 @@
["." text
format]
[collection
- ["." list ("#/." monoid)]]]]
+ ["." list ("#;." monoid)]]]]
["." // (#+ Distribution)
["_" term]
[//
@@ -103,7 +103,7 @@
(def: #export (extension distribution)
(-> Distribution Text)
- ($.paragraph ($_ list/compose
+ ($.paragraph ($_ list;compose
(if (get@ #//.can-re-license? distribution)
(list allow-re-licensing)
(list))
diff --git a/stdlib/source/program/licentia/license/extension.lux b/stdlib/source/program/licentia/license/extension.lux
index 7a12f45b9..83da58873 100644
--- a/stdlib/source/program/licentia/license/extension.lux
+++ b/stdlib/source/program/licentia/license/extension.lux
@@ -4,7 +4,7 @@
["." text
format]
[collection
- ["." list ("#/." monoid)]]]]
+ ["." list ("#;." monoid)]]]]
["." // (#+ Extension)
["_" term]
["." grant]
diff --git a/stdlib/source/program/licentia/license/notice.lux b/stdlib/source/program/licentia/license/notice.lux
index b1cf5658e..7e775078c 100644
--- a/stdlib/source/program/licentia/license/notice.lux
+++ b/stdlib/source/program/licentia/license/notice.lux
@@ -4,7 +4,7 @@
["." text
format]
[collection
- ["." list ("#/." functor)]]]]
+ ["." list ("#;." functor)]]]]
["." // #_
["#." time]
["#." copyright]
@@ -26,5 +26,5 @@
(def: #export copyright
(-> (List //copyright.Holder) Text)
- (|>> (list/map ..copyright-holder)
+ (|>> (list;map ..copyright-holder)
(text.join-with text.new-line)))
diff --git a/stdlib/source/program/licentia/output.lux b/stdlib/source/program/licentia/output.lux
index 475c4b908..29d61dd42 100644
--- a/stdlib/source/program/licentia/output.lux
+++ b/stdlib/source/program/licentia/output.lux
@@ -1,11 +1,11 @@
(.module:
[lux (#- Definition)
[data
- ["." maybe ("#/." functor)]
+ ["." maybe ("#;." functor)]
["." text
format]
[collection
- ["." list ("#/." functor monoid)]]]]
+ ["." list ("#;." functor monoid)]]]]
[//
["." license (#+ Identification
Termination
@@ -175,7 +175,7 @@
"")]
[(get@ #license.same-license? value) "License Retention"
- ($.paragraph (list/compose extension.sharing-requirement
+ ($.paragraph (list;compose extension.sharing-requirement
extension.license-conflict-resolution))]
[(get@ #license.must-be-distinguishable? value) (format _.extension " Distinctness")
@@ -251,7 +251,7 @@
(-> License Text)
(let [identification (|> value
(get@ #license.identification)
- (maybe/map ..identification)
+ (maybe;map ..identification)
(maybe.default ""))
identified? (case (get@ #license.identification value)
(#.Some _)
@@ -269,12 +269,12 @@
black-lists
($.block ($.section {#$.title (format "Denial of " _.license)
#$.content (|> black-lists
- (list/map black-list.black-list)
+ (list;map black-list.black-list)
(text.join-with ..black-list-spacing))})))
($.section {#$.title "Definitions"
#$.content (|> definition.all
- (list/map (|>> ..definition $.block))
+ (list;map (|>> ..definition $.block))
(text.join-with ""))})
($.block ($.section {#$.title (format "Acceptance of " _.license)
@@ -294,7 +294,7 @@
(|> value
(get@ #license.attribution)
- (maybe/map (|>> ..attribution
+ (maybe;map (|>> ..attribution
["Attribution Information"]
$.section
$.block))
diff --git a/stdlib/source/program/scriptum.lux b/stdlib/source/program/scriptum.lux
index a51a1765b..defca9477 100644
--- a/stdlib/source/program/scriptum.lux
+++ b/stdlib/source/program/scriptum.lux
@@ -13,12 +13,12 @@
["." error (#+ Error)]
[format
["md" markdown (#+ Markdown Span Block)]]
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format
["." encoding]]
[collection
- ["." sequence (#+ Sequence) ("#/." functor)]
- ["." list ("#/." functor fold)]]]
+ ["." sequence (#+ Sequence) ("#;." functor)]
+ ["." list ("#;." functor fold)]]]
["." function]
["." type]
["." macro]
@@ -44,7 +44,7 @@
(def: type-var-names
(Sequence Text)
- (|> 0 (sequence.iterate inc) (sequence/map parameter-type-name)))
+ (|> 0 (sequence.iterate inc) (sequence;map parameter-type-name)))
(do-template [<name> <partition>]
[(def: (<name> id)
@@ -81,13 +81,13 @@
(|> level
dec
(list.n/range 0)
- (list/map (|>> (n/+ (inc offset)) parameter-type-name)))))
+ (list;map (|>> (n/+ (inc offset)) parameter-type-name)))))
(def: (prefix-lines prefix lines)
(-> Text Text Text)
(|> lines
(text.split-all-with text.new-line)
- (list/map (|>> (format prefix)))
+ (list;map (|>> (format prefix)))
(text.join-with text.new-line)))
(def: (pprint-type-definition level type-func-info tags module signature? recursive-type? type)
@@ -106,7 +106,7 @@
(format "(primitive " (%t name) ")")
_
- (format "(primitive " (%t name) " " (|> params (list/map (pprint-type-definition level type-func-info #.None module signature? recursive-type?)) (text.join-with " ")) ")"))
+ (format "(primitive " (%t name) " " (|> params (list;map (pprint-type-definition level type-func-info #.None module signature? recursive-type?)) (text.join-with " ")) ")"))
[_ (#.Sum _)]
(let [members (type.flatten-variant type)]
@@ -114,20 +114,20 @@
#.Nil
(format "(| "
(|> members
- (list/map (pprint-type-definition level type-func-info #.None module signature? recursive-type?))
+ (list;map (pprint-type-definition level type-func-info #.None module signature? recursive-type?))
(text.join-with " "))
")")
_
(|> members
(list.zip2 tags)
- (list/map (function (_ [[_ t-name] type])
+ (list;map (function (_ [[_ t-name] type])
(case type
(#.Product _)
(let [types (type.flatten-tuple type)]
(format "(#" t-name " "
(|> types
- (list/map (pprint-type-definition level type-func-info #.None module signature? recursive-type?))
+ (list;map (pprint-type-definition level type-func-info #.None module signature? recursive-type?))
(text.join-with " "))
")"))
@@ -139,12 +139,12 @@
(let [members (type.flatten-tuple type)]
(case tags
#.Nil
- (format "[" (|> members (list/map (pprint-type-definition level type-func-info #.None module signature? recursive-type?)) (text.join-with " ")) "]")
+ (format "[" (|> members (list;map (pprint-type-definition level type-func-info #.None module signature? recursive-type?)) (text.join-with " ")) "]")
_
(let [member-docs (|> members
(list.zip2 tags)
- (list/map (function (_ [[_ t-name] type])
+ (list;map (function (_ [[_ t-name] type])
(if signature?
(format "(: " (pprint-type-definition level type-func-info #.None module signature? recursive-type? type) text.new-line " " t-name ")")
(format "#" t-name " " (pprint-type-definition level type-func-info #.None module signature? recursive-type? type)))))
@@ -155,7 +155,7 @@
[_ (#.Function input output)]
(let [[ins out] (type.flatten-function type)]
- (format "(-> " (|> ins (list/map (pprint-type-definition level type-func-info #.None module signature? recursive-type?)) (text.join-with " "))
+ (format "(-> " (|> ins (list;map (pprint-type-definition level type-func-info #.None module signature? recursive-type?)) (text.join-with " "))
" "
(pprint-type-definition level type-func-info #.None module signature? recursive-type? out)
")"))
@@ -190,10 +190,10 @@
[_ (#.Apply param fun)]
(let [[type-func type-arguments] (type.flatten-application type)]
- (format "(" (pprint-type-definition level type-func-info tags module signature? recursive-type? type-func) " " (|> type-arguments (list/map (pprint-type-definition level type-func-info #.None module signature? recursive-type?)) (text.join-with " ")) ")"))
+ (format "(" (pprint-type-definition level type-func-info tags module signature? recursive-type? type-func) " " (|> type-arguments (list;map (pprint-type-definition level type-func-info #.None module signature? recursive-type?)) (text.join-with " ")) ")"))
[_ (#.Named [_module _name] type)]
- (if (text/= module _module)
+ (if (text;= module _module)
_name
(%name [_module _name]))
)))
@@ -207,20 +207,20 @@
(format "(primitive " (%t name) ")")
_
- (format "(primitive " (%t name) " " (|> params (list/map (pprint-type level type-func-name module)) (list.interpose " ") (text.join-with "")) ")"))
+ (format "(primitive " (%t name) " " (|> params (list;map (pprint-type level type-func-name module)) (list.interpose " ") (text.join-with "")) ")"))
(#.Sum _)
(let [members (type.flatten-variant type)]
- (format "(| " (|> members (list/map (pprint-type level type-func-name module)) (list.interpose " ") (text.join-with "")) ")"))
+ (format "(| " (|> members (list;map (pprint-type level type-func-name module)) (list.interpose " ") (text.join-with "")) ")"))
(#.Product _)
(let [members (type.flatten-tuple type)]
- (format "[" (|> members (list/map (pprint-type level type-func-name module)) (list.interpose " ") (text.join-with "")) "]"))
+ (format "[" (|> members (list;map (pprint-type level type-func-name module)) (list.interpose " ") (text.join-with "")) "]"))
(#.Function input output)
(let [[ins out] (type.flatten-function type)]
(format "(-> "
- (|> ins (list/map (pprint-type level type-func-name module)) (list.interpose " ") (text.join-with ""))
+ (|> ins (list;map (pprint-type level type-func-name module)) (list.interpose " ") (text.join-with ""))
" "
(pprint-type level type-func-name module out)
")"))
@@ -247,10 +247,10 @@
(#.Apply param fun)
(let [[type-func type-arguments] (type.flatten-application type)]
- (format "(" (pprint-type level type-func-name module type-func) " " (|> type-arguments (list/map (pprint-type level type-func-name module)) (list.interpose " ") (text.join-with "")) ")"))
+ (format "(" (pprint-type level type-func-name module type-func) " " (|> type-arguments (list;map (pprint-type level type-func-name module)) (list.interpose " ") (text.join-with "")) ")"))
(#.Named [_module _name] type)
- (if (text/= module _module)
+ (if (text;= module _module)
_name
(%name [_module _name]))
))
@@ -268,7 +268,7 @@
(def: (lux-module? module-name)
(-> Text Bit)
- (or (text/= "lux" module-name)
+ (or (text;= "lux" module-name)
(text.starts-with? "lux/" module-name)))
(def: (add-definition [name [def-type def-annotations def-value]] organization)
@@ -299,9 +299,9 @@
(def: name-sort
(All [r] (-> [Text r] [Text r] Bit))
- (let [text/< (:: text.order <)]
+ (let [text;< (:: text.order <)]
(function (_ [n1 _] [n2 _])
- (text/< n1 n2))))
+ (text;< n1 n2))))
(def: (organize-definitions defs)
(-> (List [Text Definition]) Organization)
@@ -309,7 +309,7 @@
#macros (list)
#structures (list)
#values (list)}]
- (|> (list/fold add-definition init defs)
+ (|> (list;fold add-definition init defs)
(update@ #types (list.sort name-sort))
(update@ #macros (list.sort name-sort))
(update@ #structures (list.sort name-sort))
@@ -363,7 +363,7 @@
(when> recursive-type? [unrecurse-type])
(pprint-type-definition (dec nesting) [_name type-arguments] (maybe.default (list) tags) module signature? recursive-type?)
(text.split-all-with text.new-line)
- (list/map (|>> (format " ")))
+ (list;map (|>> (format " ")))
(text.join-with text.new-line))
")"))))
@@ -389,14 +389,14 @@
md.empty)
type-code)))))
types)]
- (wrap (list/fold (function.flip md.then)
+ (wrap (list;fold (function.flip md.then)
(md.heading/2 "Types")
type-docs))))
(def: (document-macros module-name names)
(-> Text (List [Text Code]) (Markdown Block))
(|> names
- (list/map (: (-> [Text Code] (Markdown Block))
+ (list;map (: (-> [Text Code] (Markdown Block))
(function (_ [name def-annotations])
($_ md.then
(md.heading/3 name)
@@ -405,7 +405,7 @@
(do maybe.monad
[documentation (macro.get-documentation def-annotations)]
(wrap (md.code documentation))))))))
- (list/fold (function.flip md.then)
+ (list;fold (function.flip md.then)
(md.heading/2 "Macros"))))
(do-template [<singular> <plural> <header>]
@@ -416,7 +416,7 @@
(def: (<plural> module values)
(-> Text (List Value) (Markdown Block))
(|> values
- (list/map (function (_ [name def-annotations value-type])
+ (list;map (function (_ [name def-annotations value-type])
(let [?doc (macro.get-documentation def-annotations)
usage (case (macro.function-arguments def-annotations)
#.Nil
@@ -433,7 +433,7 @@
_
md.empty)
(<singular> module value-type)))))
- (list/fold (function.flip md.then)
+ (list;fold (function.flip md.then)
(md.heading/2 <header>))))]
[document-structure document-structures "Structures"]
@@ -444,7 +444,7 @@
(-> [Text Text] Text Text)
(|> block
(text.split-all-with text.new-line)
- (list/map (text.enclose pre+post))
+ (list;map (text.enclose pre+post))
(text.join-with text.new-line)))
(def: (document-module [[module-name module] organization])
@@ -502,7 +502,7 @@
(list.sort name-sort))]
lux-exports (monad.map @ (function.compose macro.exports product.left)
lux-modules)
- module-documentation (|> (list/map organize-definitions lux-exports)
+ module-documentation (|> (list;map organize-definitions lux-exports)
(list.zip2 lux-modules)
(monad.map @ document-module))
#let [_ (io.run (monad.map io.monad save-documentation! module-documentation))]]
diff --git a/stdlib/source/test/licentia.lux b/stdlib/source/test/licentia.lux
index 0dd3183ca..1526b8a04 100644
--- a/stdlib/source/test/licentia.lux
+++ b/stdlib/source/test/licentia.lux
@@ -6,13 +6,13 @@
[control
[monad (#+ do)]]
[data
- ["." bit ("#/." equivalence)]
- ["." maybe ("#/." functor)]
+ ["." bit ("#;." equivalence)]
+ ["." maybe ("#;." functor)]
[number
- ["." nat ("#/." interval)]]
+ ["." nat ("#;." interval)]]
["." text]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
[math
["r" random (#+ Random)]]]
{#program
@@ -44,9 +44,9 @@
(def: period
(Random (Period Nat))
(do r.monad
- [start (r.filter (|>> (n/= nat/top) not)
+ [start (r.filter (|>> (n/= nat;top) not)
r.nat)
- #let [wiggle-room (n/- start nat/top)]
+ #let [wiggle-room (n/- start nat;top)]
end (:: @ map
(|>> (n/% wiggle-room) (n/max 1))
r.nat)]
@@ -174,10 +174,10 @@
(_.test "Litigation conditions are present."
(present? liability.litigation))
(_.test "Liability acceptance conditions may be present."
- (bit/= (get@ #license.can-accept? liability)
+ (bit;= (get@ #license.can-accept? liability)
(present? liability.can-accept)))
(_.test "Liability acceptance conditions may be present."
- (bit/= (get@ #license.disclaim-high-risk? liability)
+ (bit;= (get@ #license.disclaim-high-risk? liability)
(present? liability.disclaim-high-risk)))
))
@@ -196,13 +196,13 @@
(Concern Commercial)
($_ _.and
(_.test "Non-commercial clause is present."
- (bit/= (not (get@ #license.can-sell? commercial))
+ (bit;= (not (get@ #license.can-sell? commercial))
(present? commercial.cannot-sell)))
(_.test "Contributor credit condition is present."
- (bit/= (get@ #license.require-contributor-credit? commercial)
+ (bit;= (get@ #license.require-contributor-credit? commercial)
(present? commercial.require-contributor-attribution)))
(_.test "Anti-endorsement condition is present."
- (bit/= (not (get@ #license.allow-contributor-endorsement? commercial))
+ (bit;= (not (get@ #license.allow-contributor-endorsement? commercial))
(present? commercial.disallow-contributor-endorsement)))
))
@@ -210,11 +210,11 @@
(Concern Extension)
($_ _.and
(_.test "The license is viral."
- (bit/= (get@ #license.same-license? extension)
+ (bit;= (get@ #license.same-license? extension)
(and (list.every? present? extension.sharing-requirement)
(list.every? present? extension.license-conflict-resolution))))
(_.test "Extensions must be distinguishable from the original work."
- (bit/= (get@ #license.must-be-distinguishable? extension)
+ (bit;= (get@ #license.must-be-distinguishable? extension)
(present? extension.distinctness-requirement)))
(_.test "The community must be notified of new extensions."
(case (get@ #license.notification-period extension)
@@ -224,7 +224,7 @@
#.None
true))
(_.test "Must describe modifications."
- (bit/= (get@ #license.must-describe-modifications? extension)
+ (bit;= (get@ #license.must-describe-modifications? extension)
(present? extension.description-requirement)))
))
@@ -236,14 +236,14 @@
(_.test "The attribution phrase is present."
(|> attribution
(get@ #license.phrase)
- (maybe/map present?)
+ (maybe;map present?)
(maybe.default true)))
(_.test "The attribution URL is present."
(present? (get@ #license.url attribution)))
(_.test "The attribution image is present."
(|> attribution
(get@ #license.image)
- (maybe/map present?)
+ (maybe;map present?)
(maybe.default true)))
))
@@ -296,7 +296,7 @@
yes)
every-entity-is-mentioned? (|> black-list
(get@ #license.entities)
- (list/map black-list.entity)
+ (list;map black-list.entity)
(list.every? present?))]
(and black-list-is-justified?
every-entity-is-mentioned?)))
diff --git a/stdlib/source/test/lux.lux b/stdlib/source/test/lux.lux
index 85ed47228..d6d667d72 100644
--- a/stdlib/source/test/lux.lux
+++ b/stdlib/source/test/lux.lux
@@ -20,7 +20,7 @@
["." i64]]]
["." function]
["." math
- ["r" random (#+ Random) ("#/." functor)]]
+ ["r" random (#+ Random) ("#;." functor)]]
["_" test (#+ Test)]
## These modules do not need to be tested.
[type
@@ -295,8 +295,8 @@
Test
($_ _.and
(do r.monad
- [factor (r/map (|>> (n/% 10) (n/max 1)) r.nat)
- iterations (r/map (n/% 100) r.nat)
+ [factor (r;map (|>> (n/% 10) (n/max 1)) r.nat)
+ iterations (r;map (n/% 100) r.nat)
#let [expected (n/* factor iterations)]]
(_.test "Can write loops."
(n/= expected
@@ -396,13 +396,13 @@
(..conversion <gen> <forward> <backward> <=>))]
["Int -> Nat"
- i/= .nat .int (r/map (i/% +1,000,000) r.int)]
+ i/= .nat .int (r;map (i/% +1,000,000) r.int)]
["Nat -> Int"
- n/= .int .nat (r/map (n/% 1,000,000) r.nat)]
+ n/= .int .nat (r;map (n/% 1,000,000) r.nat)]
["Int -> Frac"
- i/= int-to-frac frac-to-int (r/map (i/% +1,000,000) r.int)]
+ i/= int-to-frac frac-to-int (r;map (i/% +1,000,000) r.int)]
["Frac -> Int"
- f/= frac-to-int int-to-frac (r/map math.floor r.frac)]
+ f/= frac-to-int int-to-frac (r;map math.floor r.frac)]
["Rev -> Frac"
r/= rev-to-frac frac-to-rev frac-rev]
)))))
diff --git a/stdlib/source/test/lux/cli.lux b/stdlib/source/test/lux/cli.lux
index 8c04a119d..c59c47faf 100644
--- a/stdlib/source/test/lux/cli.lux
+++ b/stdlib/source/test/lux/cli.lux
@@ -7,8 +7,8 @@
[data
["." error]
[number
- ["." nat ("#/." decimal)]]
- ["." text ("#/." equivalence)
+ ["." nat ("#;." decimal)]]
+ ["." text ("#;." equivalence)
format]
[collection
["." list]]]
@@ -22,9 +22,9 @@
Test
(do r.monad
[num-args (|> r.nat (:: @ map (n/% 10)))
- #let [gen-arg (:: @ map nat/encode r.nat)]
+ #let [gen-arg (:: @ map nat;encode r.nat)]
yes gen-arg
- #let [gen-ignore (r.filter (|>> (text/= yes) not)
+ #let [gen-ignore (r.filter (|>> (text;= yes) not)
(r.unicode 5))]
no gen-ignore
pre-ignore (r.list 5 gen-ignore)
@@ -36,7 +36,7 @@
#0
(#error.Success arg)
- (text/= arg yes))))
+ (text;= arg yes))))
(_.test "Can test tokens."
(and (|> (/.run (list yes) (/.this yes))
(case> (#error.Failure _)
@@ -51,12 +51,12 @@
(#error.Success _)
#0))))
(_.test "Can use custom token parsers."
- (|> (/.run (list yes) (/.parse nat/decode))
+ (|> (/.run (list yes) (/.parse nat;decode))
(case> (#error.Failure _)
#0
(#error.Success parsed)
- (text/= (nat/encode parsed)
+ (text;= (nat;encode parsed)
yes))))
(_.test "Can query if there are any more inputs."
(and (|> (/.run (list) /.end)
diff --git a/stdlib/source/test/lux/compiler/default/phase/analysis/case.lux b/stdlib/source/test/lux/compiler/default/phase/analysis/case.lux
index a05eda326..5c47960c1 100644
--- a/stdlib/source/test/lux/compiler/default/phase/analysis/case.lux
+++ b/stdlib/source/test/lux/compiler/default/phase/analysis/case.lux
@@ -6,12 +6,12 @@
[data
["." product]
["." maybe]
- ["." text ("#/." equivalence)]
+ ["." text ("#;." equivalence)]
[collection
- ["." list ("#/." monad)]
+ ["." list ("#;." monad)]
["." set]]]
[math
- ["r" random ("#/." monad)]]
+ ["r" random ("#;." monad)]]
["." type
["." check]]
[macro
@@ -35,7 +35,7 @@
#.Nil
(#.Cons head+ #.Nil)
- (list/map (|>> list) head+)
+ (list;map (|>> list) head+)
(#.Cons head+ tail++)
(do list.monad
@@ -47,7 +47,7 @@
(-> Bit (List [Code Code]) Code (r.Random (List Code)))
(case inputC
[_ (#.Bit _)]
- (r/wrap (list (' #1) (' #0)))
+ (r;wrap (list (' #1) (' #0)))
(^template [<tag> <gen> <wrapper>]
[_ (<tag> _)]
@@ -62,7 +62,7 @@
#.None
(wrap (list (' _)))))
- (r/wrap (list (' _)))))
+ (r;wrap (list (' _)))))
([#.Nat r.nat code.nat]
[#.Int r.int code.int]
[#.Rev r.rev code.rev]
@@ -70,26 +70,26 @@
[#.Text (r.unicode 5) code.text])
(^ [_ (#.Tuple (list))])
- (r/wrap (list (' [])))
+ (r;wrap (list (' [])))
(^ [_ (#.Record (list))])
- (r/wrap (list (' {})))
+ (r;wrap (list (' {})))
[_ (#.Tuple members)]
(do r.monad
[member-wise-patterns (monad.map @ (exhaustive-branches allow-literals? variantTC) members)]
(wrap (|> member-wise-patterns
exhaustive-weaving
- (list/map code.tuple))))
+ (list;map code.tuple))))
[_ (#.Record kvs)]
(do r.monad
- [#let [ks (list/map product.left kvs)
- vs (list/map product.right kvs)]
+ [#let [ks (list;map product.left kvs)
+ vs (list;map product.right kvs)]
member-wise-patterns (monad.map @ (exhaustive-branches allow-literals? variantTC) vs)]
(wrap (|> member-wise-patterns
exhaustive-weaving
- (list/map (|>> (list.zip2 ks) code.record)))))
+ (list;map (|>> (list.zip2 ks) code.record)))))
(^ [_ (#.Form (list [_ (#.Tag _)] _))])
(do r.monad
@@ -97,13 +97,13 @@
(function (_ [_tag _code])
(do @
[v-branches (exhaustive-branches allow-literals? variantTC _code)]
- (wrap (list/map (function (_ pattern) (` ((~ _tag) (~ pattern))))
+ (wrap (list;map (function (_ pattern) (` ((~ _tag) (~ pattern))))
v-branches))))
variantTC)]
- (wrap (list/join bundles)))
+ (wrap (list;join bundles)))
_
- (r/wrap (list))
+ (r;wrap (list))
))
(def: #export (input variant-tags record-tags primitivesC)
@@ -111,7 +111,7 @@
(r.rec
(function (_ input)
($_ r.either
- (r/map product.right _primitive.primitive)
+ (r;map product.right _primitive.primitive)
(do r.monad
[choice (|> r.nat (:: @ map (n/% (list.size variant-tags))))
#let [choiceT (maybe.assume (list.nth choice variant-tags))
@@ -121,7 +121,7 @@
[size (|> r.nat (:: @ map (n/% 3)))
elems (r.list size input)]
(wrap (code.tuple elems)))
- (r/wrap (code.record (list.zip2 record-tags primitivesC)))
+ (r;wrap (code.record (list.zip2 record-tags primitivesC)))
))))
(def: (branch body pattern)
@@ -136,16 +136,16 @@
(do @
[module-name (r.unicode 5)
variant-name (r.unicode 5)
- record-name (|> (r.unicode 5) (r.filter (|>> (text/= variant-name) not)))
+ record-name (|> (r.unicode 5) (r.filter (|>> (text;= variant-name) not)))
size (|> r.nat (:: @ map (|>> (n/% 10) (n/max 2))))
variant-tags (|> (r.set text.hash size (r.unicode 5)) (:: @ map set.to-list))
record-tags (|> (r.set text.hash size (r.unicode 5)) (:: @ map set.to-list))
primitivesTC (r.list size _primitive.primitive)
- #let [primitivesT (list/map product.left primitivesTC)
- primitivesC (list/map product.right primitivesTC)
+ #let [primitivesT (list;map product.left primitivesTC)
+ primitivesC (list;map product.right primitivesTC)
code-tag (|>> [module-name] code.tag)
- variant-tags+ (list/map code-tag variant-tags)
- record-tags+ (list/map code-tag record-tags)
+ variant-tags+ (list;map code-tag variant-tags)
+ record-tags+ (list;map code-tag record-tags)
variantTC (list.zip2 variant-tags+ primitivesC)]
inputC (input variant-tags+ record-tags+ primitivesC)
[outputT outputC] _primitive.primitive
@@ -155,11 +155,11 @@
redundant-patterns (exhaustive-branches #0 variantTC inputC)
redundancy-idx (|> r.nat (:: @ map (n/% (list.size redundant-patterns))))
heterogeneous-idx (|> r.nat (:: @ map (n/% (list.size exhaustive-patterns))))
- #let [exhaustive-branchesC (list/map (branch outputC)
+ #let [exhaustive-branchesC (list;map (branch outputC)
exhaustive-patterns)
non-exhaustive-branchesC (list.take (dec (list.size exhaustive-branchesC))
exhaustive-branchesC)
- redundant-branchesC (<| (list/map (branch outputC))
+ redundant-branchesC (<| (list;map (branch outputC))
list.concat
(list (list.take redundancy-idx redundant-patterns)
(list (maybe.assume (list.nth redundancy-idx redundant-patterns)))
diff --git a/stdlib/source/test/lux/compiler/default/phase/analysis/function.lux b/stdlib/source/test/lux/compiler/default/phase/analysis/function.lux
index 829f83713..acdb9e7ff 100644
--- a/stdlib/source/test/lux/compiler/default/phase/analysis/function.lux
+++ b/stdlib/source/test/lux/compiler/default/phase/analysis/function.lux
@@ -7,10 +7,10 @@
["." error]
["." maybe]
["." product]
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
[math
["r" random]]
["." type]
@@ -48,7 +48,7 @@
(<| (times 100)
(do @
[func-name (r.unicode 5)
- arg-name (|> (r.unicode 5) (r.filter (|>> (text/= func-name) not)))
+ arg-name (|> (r.unicode 5) (r.filter (|>> (text;= func-name) not)))
[outputT outputC] _primitive.primitive
[inputT _] _primitive.primitive
#let [g!arg (code.local-identifier arg-name)]]
@@ -80,8 +80,8 @@
partial-args (|> r.nat (:: @ map (n/% full-args)))
var-idx (|> r.nat (:: @ map (|>> (n/% full-args) (n/max 1))))
inputsTC (r.list full-args _primitive.primitive)
- #let [inputsT (list/map product.left inputsTC)
- inputsC (list/map product.right inputsTC)]
+ #let [inputsT (list;map product.left inputsTC)
+ inputsC (list;map product.right inputsTC)]
[outputT outputC] _primitive.primitive
#let [funcT (type.function inputsT outputT)
partialT (type.function (list.drop partial-args inputsT) outputT)
diff --git a/stdlib/source/test/lux/compiler/default/phase/analysis/primitive.lux b/stdlib/source/test/lux/compiler/default/phase/analysis/primitive.lux
index b73e4f81c..0c716dd3f 100644
--- a/stdlib/source/test/lux/compiler/default/phase/analysis/primitive.lux
+++ b/stdlib/source/test/lux/compiler/default/phase/analysis/primitive.lux
@@ -9,8 +9,8 @@
[text
format]]
[math
- ["r" random ("#/." monad)]]
- ["." type ("#/." equivalence)]
+ ["r" random ("#;." monad)]]
+ ["." type ("#;." equivalence)]
[macro
["." code]]
[compiler
@@ -35,13 +35,13 @@
(def: unit
(r.Random Code)
- (r/wrap (' [])))
+ (r;wrap (' [])))
(def: #export primitive
(r.Random [Type Code])
(`` ($_ r.either
(~~ (do-template [<type> <code-wrapper> <value-gen>]
- [(r.and (r/wrap <type>) (r/map <code-wrapper> <value-gen>))]
+ [(r.and (r;wrap <type>) (r;map <code-wrapper> <value-gen>))]
[Any code.tuple (r.list 0 ..unit)]
[Bit code.bit r.bit]
diff --git a/stdlib/source/test/lux/compiler/default/phase/analysis/procedure/common.lux b/stdlib/source/test/lux/compiler/default/phase/analysis/procedure/common.lux
index 5464981a1..7d83f00c8 100644
--- a/stdlib/source/test/lux/compiler/default/phase/analysis/procedure/common.lux
+++ b/stdlib/source/test/lux/compiler/default/phase/analysis/procedure/common.lux
@@ -13,7 +13,7 @@
format]]
[math
["r" random]]
- ["." type ("#/." equivalence)]
+ ["." type ("#;." equivalence)]
[macro
["." code]]
[compiler
@@ -51,7 +51,7 @@
(do @
[[primT primC] _primitive.primitive
[antiT antiC] (|> _primitive.primitive
- (r.filter (|>> product.left (type/= primT) not)))]
+ (r.filter (|>> product.left (type;= primT) not)))]
($_ seq
(test "Can test for reference equality."
(check-success+ "lux is" (list primC primC) Bit))
diff --git a/stdlib/source/test/lux/compiler/default/phase/analysis/reference.lux b/stdlib/source/test/lux/compiler/default/phase/analysis/reference.lux
index b2f64ac19..4cf1f9da0 100644
--- a/stdlib/source/test/lux/compiler/default/phase/analysis/reference.lux
+++ b/stdlib/source/test/lux/compiler/default/phase/analysis/reference.lux
@@ -5,11 +5,11 @@
pipe]
[data
["." error (#+ Error)]
- ["." name ("#/." equivalence)]
- ["." text ("#/." equivalence)]]
+ ["." name ("#;." equivalence)]
+ ["." text ("#;." equivalence)]]
[math
["r" random]]
- ["." type ("#/." equivalence)]
+ ["." type ("#;." equivalence)]
[macro
["." code]]
[compiler
@@ -70,7 +70,7 @@
scope-name (r.unicode 5)
var-name (r.unicode 5)
dependent-module (|> (r.unicode 5)
- (r.filter (|>> (text/= def-module) not)))]
+ (r.filter (|>> (text;= def-module) not)))]
($_ seq
(test "Can analyse variable."
(|> (scope.with-scope scope-name
@@ -79,7 +79,7 @@
(_primitive.phase (code.local-identifier var-name)))))
(phase.run _primitive.state)
(case> (^ (#error.Success [inferredT (#analysis.Reference (reference.local var))]))
- (and (type/= expectedT inferredT)
+ (and (type;= expectedT inferredT)
(n/= 0 var))
_
@@ -93,8 +93,8 @@
(module.with-module 0 def-module)
(phase.run _primitive.state)
(case> (^ (#error.Success [_ inferredT (#analysis.Reference (reference.constant constant-name))]))
- (and (type/= expectedT inferredT)
- (name/= def-name constant-name))
+ (and (type;= expectedT inferredT)
+ (name;= def-name constant-name))
_
#0))))
diff --git a/stdlib/source/test/lux/compiler/default/phase/analysis/structure.lux b/stdlib/source/test/lux/compiler/default/phase/analysis/structure.lux
index 34a43c042..6d575fd08 100644
--- a/stdlib/source/test/lux/compiler/default/phase/analysis/structure.lux
+++ b/stdlib/source/test/lux/compiler/default/phase/analysis/structure.lux
@@ -4,17 +4,17 @@
[monad (#+ do)]
pipe]
[data
- ["." bit ("#/." equivalence)]
+ ["." bit ("#;." equivalence)]
["e" error]
["." product]
["." maybe]
["." text]
[collection
- ["." list ("#/." functor)]
+ ["." list ("#;." functor)]
["." set]]]
[math
["r" random]]
- ["." type ("#/." equivalence)
+ ["." type ("#;." equivalence)
["." check]]
[macro
["." code]]
@@ -53,7 +53,7 @@
(inc (get@ #analysis.lefts variant))
(get@ #analysis.lefts variant))]
(|> size dec (n/= tag)
- (bit/= (get@ #analysis.right? variant))
+ (bit;= (get@ #analysis.right? variant))
(and (n/= tag variant-tag)))))
(def: (check-sum type size tag analysis)
@@ -101,7 +101,7 @@
(tagged module tags type)
(phase.run _primitive.state)
(case> (#e.Success [_ productT productA])
- (and (type/= type productT)
+ (and (type;= type productT)
(right-size? size productA))
_
@@ -115,14 +115,14 @@
primitives (r.list size _primitive.primitive)
+choice (|> r.nat (:: @ map (n/% (inc size))))
[_ +valueC] _primitive.primitive
- #let [variantT (type.variant (list/map product.left primitives))
+ #let [variantT (type.variant (list;map product.left primitives))
[valueT valueC] (maybe.assume (list.nth choice primitives))
+size (inc size)
+primitives (list.concat (list (list.take choice primitives)
(list [(#.Parameter 1) +valueC])
(list.drop choice primitives)))
[+valueT +valueC] (maybe.assume (list.nth +choice +primitives))
- +variantT (type.variant (list/map product.left +primitives))]]
+ +variantT (type.variant (list;map product.left +primitives))]]
($_ seq
(test "Can analyse sum."
(check-sum variantT size choice
@@ -166,16 +166,16 @@
primitives (r.list size _primitive.primitive)
choice (|> r.nat (:: @ map (n/% size)))
[_ +valueC] _primitive.primitive
- #let [tupleT (type.tuple (list/map product.left primitives))
+ #let [tupleT (type.tuple (list;map product.left primitives))
[singletonT singletonC] (|> primitives (list.nth choice) maybe.assume)
+primitives (list.concat (list (list.take choice primitives)
(list [(#.Parameter 1) +valueC])
(list.drop choice primitives)))
- +tupleT (type.tuple (list/map product.left +primitives))]]
+ +tupleT (type.tuple (list;map product.left +primitives))]]
($_ seq
(test "Can analyse product."
(|> (typeA.with-type tupleT
- (/.product _primitive.phase (list/map product.right primitives)))
+ (/.product _primitive.phase (list;map product.right primitives)))
(phase.run _primitive.state)
(case> (#e.Success tupleA)
(right-size? size tupleA)
@@ -184,10 +184,10 @@
#0)))
(test "Can infer product."
(|> (typeA.with-inference
- (/.product _primitive.phase (list/map product.right primitives)))
+ (/.product _primitive.phase (list;map product.right primitives)))
(phase.run _primitive.state)
(case> (#e.Success [_type tupleA])
- (and (type/= tupleT _type)
+ (and (type;= tupleT _type)
(right-size? size tupleA))
_
@@ -200,9 +200,9 @@
(|> (do phase.monad
[[_ varT] (typeA.with-env check.var)
_ (typeA.with-env
- (check.check varT (type.tuple (list/map product.left primitives))))]
+ (check.check varT (type.tuple (list;map product.left primitives))))]
(typeA.with-type varT
- (/.product _primitive.phase (list/map product.right primitives))))
+ (/.product _primitive.phase (list;map product.right primitives))))
(phase.run _primitive.state)
(case> (#e.Success tupleA)
(right-size? size tupleA)
@@ -211,11 +211,11 @@
#0)))
(test "Can analyse product through existential quantification."
(|> (typeA.with-type (type.ex-q 1 +tupleT)
- (/.product _primitive.phase (list/map product.right +primitives)))
+ (/.product _primitive.phase (list;map product.right +primitives)))
check-succeeds))
(test "Cannot analyse product through universal quantification."
(|> (typeA.with-type (type.univ-q 1 +tupleT)
- (/.product _primitive.phase (list/map product.right +primitives)))
+ (/.product _primitive.phase (list;map product.right +primitives)))
check-fails))
))))
@@ -230,7 +230,7 @@
module-name (r.unicode 5)
type-name (r.unicode 5)
#let [varT (#.Parameter 1)
- primitivesT (list/map product.left primitives)
+ primitivesT (list;map product.left primitives)
[choiceT choiceC] (maybe.assume (list.nth choice primitives))
[other-choiceT other-choiceC] (maybe.assume (list.nth other-choice primitives))
variantT (type.variant primitivesT)
@@ -268,9 +268,9 @@
type-name (r.unicode 5)
choice (|> r.nat (:: @ map (n/% size)))
#let [varT (#.Parameter 1)
- tagsC (list/map (|>> [module-name] code.tag) tags)
- primitivesT (list/map product.left primitives)
- primitivesC (list/map product.right primitives)
+ tagsC (list;map (|>> [module-name] code.tag) tags)
+ primitivesT (list;map product.left primitives)
+ primitivesC (list;map product.right primitives)
tupleT (type.tuple primitivesT)
namedT (#.Named [module-name type-name] tupleT)
recordC (list.zip2 tagsC primitivesC)
diff --git a/stdlib/source/test/lux/compiler/default/phase/synthesis/case.lux b/stdlib/source/test/lux/compiler/default/phase/synthesis/case.lux
index 7a67e4bfa..9a635eb9e 100644
--- a/stdlib/source/test/lux/compiler/default/phase/synthesis/case.lux
+++ b/stdlib/source/test/lux/compiler/default/phase/synthesis/case.lux
@@ -4,7 +4,7 @@
[monad (#+ do)]
pipe]
[data
- ["." error ("#/." functor)]]
+ ["." error ("#;." functor)]]
[compiler
[default
["." reference]
@@ -33,7 +33,7 @@
(|> maskA
expression.phase
(phase.run [bundle.empty //.init])
- (error/map (//primitive.corresponds? maskedA))
+ (error;map (//primitive.corresponds? maskedA))
(error.default #0))))))
(context: "Let expressions."
diff --git a/stdlib/source/test/lux/compiler/default/phase/synthesis/function.lux b/stdlib/source/test/lux/compiler/default/phase/synthesis/function.lux
index 4866086aa..9d7edb358 100644
--- a/stdlib/source/test/lux/compiler/default/phase/synthesis/function.lux
+++ b/stdlib/source/test/lux/compiler/default/phase/synthesis/function.lux
@@ -11,12 +11,12 @@
[text
format]
[collection
- ["." list ("#/." functor fold)]
+ ["." list ("#;." functor fold)]
["dict" dictionary (#+ Dictionary)]
["." set]]]
[compiler
[default
- ["." reference (#+ Variable) ("variable/." equivalence)]
+ ["." reference (#+ Variable) ("variable;." equivalence)]
["." phase
["." analysis (#+ Arity Analysis)]
["//" synthesis (#+ Synthesis)
@@ -53,13 +53,13 @@
(do r.monad
[num-locals (|> r.nat (:: @ map (|>> (n/% 100) (n/max 10))))
#let [indices (list.n/range 0 (dec num-locals))
- local-env (list/map (|>> #reference.Local) indices)
- foreign-env (list/map (|>> #reference.Foreign) indices)]
+ local-env (list;map (|>> #reference.Local) indices)
+ foreign-env (list;map (|>> #reference.Foreign) indices)]
[arity bodyA predictionA] (: (r.Random [Arity Analysis Variable])
(loop [arity 1
current-env foreign-env]
(let [current-env/size (list.size current-env)
- resolver (list/fold (function (_ [idx var] resolver)
+ resolver (list;fold (function (_ [idx var] resolver)
(dict.put idx var resolver))
(: (Dictionary Nat Variable)
(dict.new number.hash))
@@ -72,10 +72,10 @@
picks (|> (r.set number.hash num-picks (pick current-env/size))
(:: @ map set.to-list))
[arity bodyA predictionA] (recur (inc arity)
- (list/map (function (_ pick)
+ (list;map (function (_ pick)
(maybe.assume (list.nth pick current-env)))
picks))
- #let [picked-env (list/map (|>> #reference.Foreign) picks)]]
+ #let [picked-env (list;map (|>> #reference.Foreign) picks)]]
(wrap [arity
(#analysis.Function picked-env bodyA)
predictionA]))
diff --git a/stdlib/source/test/lux/compiler/default/phase/synthesis/structure.lux b/stdlib/source/test/lux/compiler/default/phase/synthesis/structure.lux
index 97d4c037d..d24131f04 100644
--- a/stdlib/source/test/lux/compiler/default/phase/synthesis/structure.lux
+++ b/stdlib/source/test/lux/compiler/default/phase/synthesis/structure.lux
@@ -4,7 +4,7 @@
[monad (#+ do)]
pipe]
[data
- ["." bit ("#/." equivalence)]
+ ["." bit ("#;." equivalence)]
["." product]
["." error]
[collection
@@ -40,7 +40,7 @@
(case> (^ (#error.Success (//.variant [leftsS right?S valueS])))
(let [tagS (if right?S (inc leftsS) leftsS)]
(and (n/= tagA tagS)
- (|> tagS (n/= (dec size)) (bit/= right?S))
+ (|> tagS (n/= (dec size)) (bit;= right?S))
(//primitive.corresponds? memberA valueS)))
_
diff --git a/stdlib/source/test/lux/compiler/default/syntax.lux b/stdlib/source/test/lux/compiler/default/syntax.lux
index 6f1d2152d..530bbfbad 100644
--- a/stdlib/source/test/lux/compiler/default/syntax.lux
+++ b/stdlib/source/test/lux/compiler/default/syntax.lux
@@ -11,7 +11,7 @@
["." list]
["." dictionary (#+ Dictionary)]]]
[math
- ["r" random ("#/." monad)]]
+ ["r" random ("#;." monad)]]
[macro
["." code]]
[compiler
@@ -48,18 +48,18 @@
(r.Random Code)
(let [numeric^ (: (r.Random Code)
($_ r.either
- (|> r.bit (r/map code.bit))
- (|> r.nat (r/map code.nat))
- (|> r.int (r/map code.int))
- (|> r.rev (r/map code.rev))
- (|> r.frac (r/map code.frac))))
+ (|> r.bit (r;map code.bit))
+ (|> r.nat (r;map code.nat))
+ (|> r.int (r;map code.int))
+ (|> r.rev (r;map code.rev))
+ (|> r.frac (r;map code.frac))))
textual^ (: (r.Random Code)
($_ r.either
(do r.monad
- [size (|> r.nat (r/map (n/% 20)))]
- (|> (r.unicode size) (r/map code.text)))
- (|> name^ (r/map code.identifier))
- (|> name^ (r/map code.tag))))
+ [size (|> r.nat (r;map (n/% 20)))]
+ (|> (r.unicode size) (r;map code.text)))
+ (|> name^ (r;map code.identifier))
+ (|> name^ (r;map code.tag))))
simple^ (: (r.Random Code)
($_ r.either
numeric^
@@ -67,16 +67,16 @@
(r.rec
(function (_ code^)
(let [multi^ (do r.monad
- [size (|> r.nat (r/map (n/% 3)))]
+ [size (|> r.nat (r;map (n/% 3)))]
(r.list size code^))
composite^ (: (r.Random Code)
($_ r.either
- (|> multi^ (r/map code.form))
- (|> multi^ (r/map code.tuple))
+ (|> multi^ (r;map code.form))
+ (|> multi^ (r;map code.tuple))
(do r.monad
- [size (|> r.nat (r/map (n/% 3)))]
+ [size (|> r.nat (r;map (n/% 3)))]
(|> (r.list size (r.and code^ code^))
- (r/map code.record)))))]
+ (r;map code.record)))))]
(r.either simple^
composite^))))))
@@ -118,7 +118,7 @@
(r.Random Text)
(let [char-gen (|> r.nat (r.filter (|>> (n/= (`` (char (~~ (static text.new-line))))) not)))]
(do r.monad
- [size (|> r.nat (r/map (n/% 20)))]
+ [size (|> r.nat (r;map (n/% 20)))]
(r.text char-gen size))))
(def: comment^
diff --git a/stdlib/source/test/lux/control/apply.lux b/stdlib/source/test/lux/control/apply.lux
index 42d2fa8b9..1cd756509 100644
--- a/stdlib/source/test/lux/control/apply.lux
+++ b/stdlib/source/test/lux/control/apply.lux
@@ -2,7 +2,9 @@
[lux #*
[control
[monad (#+ do)]]
- data/text/format
+ [data
+ [text
+ format]]
["." function]
[math
["r" random]]
@@ -12,36 +14,36 @@
[//
[functor (#+ Injection Comparison)]])
-(def: (identity injection comparison (^open "_/."))
+(def: (identity injection comparison (^open "_;."))
(All [f] (-> (Injection f) (Comparison f) (Apply f) Test))
(do r.monad
[sample (:: @ map injection r.nat)]
(_.test "Identity."
((comparison n/=)
- (_/apply (injection function.identity) sample)
+ (_;apply (injection function.identity) sample)
sample))))
-(def: (homomorphism injection comparison (^open "_/."))
+(def: (homomorphism injection comparison (^open "_;."))
(All [f] (-> (Injection f) (Comparison f) (Apply f) Test))
(do r.monad
[sample r.nat
increase (:: @ map n/+ r.nat)]
(_.test "Homomorphism."
((comparison n/=)
- (_/apply (injection increase) (injection sample))
+ (_;apply (injection increase) (injection sample))
(injection (increase sample))))))
-(def: (interchange injection comparison (^open "_/."))
+(def: (interchange injection comparison (^open "_;."))
(All [f] (-> (Injection f) (Comparison f) (Apply f) Test))
(do r.monad
[sample r.nat
increase (:: @ map n/+ r.nat)]
(_.test "Interchange."
((comparison n/=)
- (_/apply (injection increase) (injection sample))
- (_/apply (injection (function (_ f) (f sample))) (injection increase))))))
+ (_;apply (injection increase) (injection sample))
+ (_;apply (injection (function (_ f) (f sample))) (injection increase))))))
-(def: (composition injection comparison (^open "_/."))
+(def: (composition injection comparison (^open "_;."))
(All [f] (-> (Injection f) (Comparison f) (Apply f) Test))
(do r.monad
[sample r.nat
@@ -49,12 +51,12 @@
decrease (:: @ map n/- r.nat)]
(_.test "Composition."
((comparison n/=)
- (_$ _/apply
+ (_$ _;apply
(injection function.compose)
(injection increase)
(injection decrease)
(injection sample))
- ($_ _/apply
+ ($_ _;apply
(injection increase)
(injection decrease)
(injection sample))))))
diff --git a/stdlib/source/test/lux/control/concurrency/actor.lux b/stdlib/source/test/lux/control/concurrency/actor.lux
index 90c88744c..014e4d758 100644
--- a/stdlib/source/test/lux/control/concurrency/actor.lux
+++ b/stdlib/source/test/lux/control/concurrency/actor.lux
@@ -6,7 +6,7 @@
["M" monad (#+ do Monad)]
["ex" exception]
[concurrency
- ["." promise ("#/." monad)]]]
+ ["." promise ("#;." monad)]]]
[data
["." error]
[text
@@ -27,14 +27,14 @@
(wrap output)))
((stop cause state)
- (promise/wrap (log! (if (ex.match? /.poisoned cause)
+ (promise;wrap (log! (if (ex.match? /.poisoned cause)
(format "Counter was poisoned: " (%n state))
cause)))))
(message: #export Counter
(count! {increment Nat} state self Nat)
(let [state' (n/+ increment state)]
- (promise/wrap (#error.Success [state' state']))))
+ (promise;wrap (#error.Success [state' state']))))
(def: #export test
Test
diff --git a/stdlib/source/test/lux/control/concurrency/frp.lux b/stdlib/source/test/lux/control/concurrency/frp.lux
index b49a9e649..ea4d7adad 100644
--- a/stdlib/source/test/lux/control/concurrency/frp.lux
+++ b/stdlib/source/test/lux/control/concurrency/frp.lux
@@ -5,13 +5,13 @@
[control
["." monad (#+ do)]
[concurrency
- ["." promise ("#/." monad)]
+ ["." promise ("#;." monad)]
["." atom (#+ Atom atom)]]]
[data
[number
["." nat]]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
[math
["r" random]]]
{1
@@ -19,7 +19,7 @@
(def: #export test
Test
- (let [(^open "list/.") (list.equivalence nat.equivalence)]
+ (let [(^open "list;.") (list.equivalence nat.equivalence)]
(do r.monad
[inputs (r.list 5 r.nat)
sample r.nat]
@@ -30,7 +30,7 @@
(/.filter n/even?)
/.consume)]
(_.assert "Can filter a channel's elements."
- (list/= (list.filter n/even? inputs)
+ (list;= (list.filter n/even? inputs)
output))))
(wrap (do promise.monad
[output (|> inputs
@@ -38,22 +38,22 @@
(:: /.functor map inc)
/.consume)]
(_.assert "Functor goes over every element in a channel."
- (list/= (list/map inc inputs)
+ (list;= (list;map inc inputs)
output))))
(wrap (do promise.monad
[output (/.consume (:: /.apply apply
(/.sequential 0 (list inc))
(/.sequential 0 (list sample))))]
(_.assert "Apply works over all channel values."
- (list/= (list (inc sample))
+ (list;= (list (inc sample))
output))))
(wrap (do promise.monad
[output (/.consume
(do /.monad
- [f (/.from-promise (promise/wrap inc))
- a (/.from-promise (promise/wrap sample))]
+ [f (/.from-promise (promise;wrap inc))
+ a (/.from-promise (promise;wrap sample))]
(wrap (f a))))]
(_.assert "Valid monad."
- (list/= (list (inc sample))
+ (list;= (list (inc sample))
output))))
))))
diff --git a/stdlib/source/test/lux/control/concurrency/promise.lux b/stdlib/source/test/lux/control/concurrency/promise.lux
index e50320901..295c26e20 100644
--- a/stdlib/source/test/lux/control/concurrency/promise.lux
+++ b/stdlib/source/test/lux/control/concurrency/promise.lux
@@ -5,7 +5,7 @@
["M" monad (#+ Monad do)]
pipe
[concurrency
- ["&" promise ("&/." monad)]]]
+ ["&" promise ("&;." monad)]]]
[math
["r" random]]]
lux/test)
@@ -50,7 +50,7 @@
(and ?left (not ?right)))))
(test "Can poll a promise for its value."
- (and (|> (&.poll (&/wrap #1))
+ (and (|> (&.poll (&;wrap #1))
(case> (#.Some #1) #1 _ #0))
(|> (&.poll (&.delay 200 #1))
(case> #.None #1 _ #0))))
diff --git a/stdlib/source/test/lux/control/concurrency/semaphore.lux b/stdlib/source/test/lux/control/concurrency/semaphore.lux
index 3ceac16b7..4aa4b08a5 100644
--- a/stdlib/source/test/lux/control/concurrency/semaphore.lux
+++ b/stdlib/source/test/lux/control/concurrency/semaphore.lux
@@ -8,10 +8,10 @@
["." atom (#+ Atom)]]]
[data
["." maybe]
- ["." text ("#/." equivalence monoid)
+ ["." text ("#;." equivalence monoid)
format]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
["." io]
[math
["r" random]]]
@@ -74,7 +74,7 @@
## (/.signal semaphore))
## _ blocked]
## (assert "A blocked process can be un-blocked by a signal somewhere else."
-## (text/= "BA"
+## (text;= "BA"
## (io.run (atom.read resource)))))))
## ))))
@@ -108,9 +108,9 @@
## _ processB
## #let [outcome (io.run (atom.read resource))]]
## (assert "Mutexes only allow one process to execute at a time."
-## (or (text/= (format expected-As expected-Bs)
+## (or (text;= (format expected-As expected-Bs)
## outcome)
-## (text/= (format expected-Bs expected-As)
+## (text;= (format expected-Bs expected-As)
## outcome))))))
## ))))
@@ -128,7 +128,7 @@
## ($_ seq
## (wrap (do promise.monad
## [#let [ids (list.n/range 0 (dec limit))
-## waiters (list/map (function (_ id)
+## waiters (list;map (function (_ id)
## (let [process (waiter resource barrier id)]
## (exec (io.run (atom.update (|>> (format "_")) resource))
## process)))
diff --git a/stdlib/source/test/lux/control/concurrency/stm.lux b/stdlib/source/test/lux/control/concurrency/stm.lux
index 869a995b0..6e386c630 100644
--- a/stdlib/source/test/lux/control/concurrency/stm.lux
+++ b/stdlib/source/test/lux/control/concurrency/stm.lux
@@ -12,7 +12,7 @@
[data
["." number]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
[math
["r" random]]]
lux/test)
@@ -65,7 +65,7 @@
(do promise.monad
[_ (|> process.parallelism
(list.n/range 1)
- (list/map (function (_ _)
+ (list;map (function (_ _)
(|> iterations-per-process
(list.n/range 1)
(M.map @ (function (_ _) (&.commit (&.update inc _concurrency-var)))))))
diff --git a/stdlib/source/test/lux/control/continuation.lux b/stdlib/source/test/lux/control/continuation.lux
index ec4495a20..cb238cd88 100644
--- a/stdlib/source/test/lux/control/continuation.lux
+++ b/stdlib/source/test/lux/control/continuation.lux
@@ -34,12 +34,12 @@
(<| (_.context (%name (name-of /.Cont)))
(do r.monad
[sample r.nat
- #let [(^open "_/.") /.apply
- (^open "_/.") /.monad]
+ #let [(^open "_;.") /.apply
+ (^open "_;.") /.monad]
elems (r.list 3 r.nat)]
($_ _.and
(_.test "Can run continuations to compute their values."
- (n/= sample (/.run (_/wrap sample))))
+ (n/= sample (/.run (_;wrap sample))))
(functorT.laws ..injection ..comparison /.functor)
(applyT.laws ..injection ..comparison /.apply)
@@ -67,14 +67,14 @@
(wrap output))))))
(_.test "Can use delimited continuations with shifting."
- (let [(^open "_/.") /.monad
- (^open "list/.") (list.equivalence nat.equivalence)
+ (let [(^open "_;.") /.monad
+ (^open "list;.") (list.equivalence nat.equivalence)
visit (: (-> (List Nat)
(Cont (List Nat) (List Nat)))
(function (visit xs)
(case xs
#.Nil
- (_/wrap #.Nil)
+ (_;wrap #.Nil)
(#.Cons x xs')
(do /.monad
@@ -83,6 +83,6 @@
[tail (k xs')]
(wrap (#.Cons x tail)))))]
(visit output)))))]
- (list/= elems
+ (list;= elems
(/.run (/.reset (visit elems))))))
))))
diff --git a/stdlib/source/test/lux/control/equivalence.lux b/stdlib/source/test/lux/control/equivalence.lux
index 714905c41..4e7992d58 100644
--- a/stdlib/source/test/lux/control/equivalence.lux
+++ b/stdlib/source/test/lux/control/equivalence.lux
@@ -3,13 +3,15 @@
["_" test (#+ Test)]
[control
[monad (#+ do)]]
- data/text/format
+ [data
+ [text
+ format]]
[math
["r" random (#+ Random)]]]
{1
["." / (#+ Equivalence)]})
-(def: #export (test (^open "_/.") generator)
+(def: #export (test (^open "_;.") generator)
(All [a] (-> (Equivalence a) (Random a) Test))
(do r.monad
[left generator
@@ -17,8 +19,8 @@
(<| (_.context (%name (name-of /.Equivalence)))
($_ _.and
(_.test "Reflexivity."
- (_/= left left))
+ (_;= left left))
(_.test "Symmetry."
- (if (_/= left right)
- (_/= right left)
- (not (_/= right left))))))))
+ (if (_;= left right)
+ (_;= right left)
+ (not (_;= right left))))))))
diff --git a/stdlib/source/test/lux/control/functor.lux b/stdlib/source/test/lux/control/functor.lux
index ea0525e04..08b706b03 100644
--- a/stdlib/source/test/lux/control/functor.lux
+++ b/stdlib/source/test/lux/control/functor.lux
@@ -2,7 +2,9 @@
[lux #*
[control
[monad (#+ do)]]
- data/text/format
+ [data
+ [text
+ format]]
["." function]
[math
["r" random]]
@@ -18,26 +20,26 @@
(-> (-> a a Bit)
(-> (f a) (f a) Bit))))
-(def: (identity injection comparison (^open "_/."))
+(def: (identity injection comparison (^open "_;."))
(All [f] (-> (Injection f) (Comparison f) (Functor f) Test))
(do r.monad
[sample (:: @ map injection r.nat)]
(_.test "Identity."
((comparison n/=)
- (_/map function.identity sample)
+ (_;map function.identity sample)
sample))))
-(def: (homomorphism injection comparison (^open "_/."))
+(def: (homomorphism injection comparison (^open "_;."))
(All [f] (-> (Injection f) (Comparison f) (Functor f) Test))
(do r.monad
[sample r.nat
increase (:: @ map n/+ r.nat)]
(_.test "Homomorphism."
((comparison n/=)
- (_/map increase (injection sample))
+ (_;map increase (injection sample))
(injection (increase sample))))))
-(def: (composition injection comparison (^open "_/."))
+(def: (composition injection comparison (^open "_;."))
(All [f] (-> (Injection f) (Comparison f) (Functor f) Test))
(do r.monad
[sample (:: @ map injection r.nat)
@@ -45,8 +47,8 @@
decrease (:: @ map n/- r.nat)]
(_.test "Composition."
((comparison n/=)
- (|> sample (_/map increase) (_/map decrease))
- (|> sample (_/map (|>> increase decrease)))))))
+ (|> sample (_;map increase) (_;map decrease))
+ (|> sample (_;map (|>> increase decrease)))))))
(def: #export (laws injection comparison functor)
(All [f] (-> (Injection f) (Comparison f) (Functor f) Test))
diff --git a/stdlib/source/test/lux/control/interval.lux b/stdlib/source/test/lux/control/interval.lux
index 4874d3742..dbac4cc8e 100644
--- a/stdlib/source/test/lux/control/interval.lux
+++ b/stdlib/source/test/lux/control/interval.lux
@@ -15,7 +15,7 @@
[math
["r" random (#+ Random)]]]
{1
- ["." / (#+ Interval) ("_/." equivalence)]}
+ ["." / (#+ Interval) ("_;." equivalence)]}
{0
[test
[lux
@@ -80,7 +80,7 @@
right-outer ..outer]
($_ _.and
(_.test "The union of an interval to itself yields the same interval."
- (_/= some-interval (/.union some-interval some-interval)))
+ (_;= some-interval (/.union some-interval some-interval)))
(_.test "The union of 2 inner intervals is another inner interval."
(/.inner? (/.union left-inner right-inner)))
(_.test "The union of 2 outer intervals yields an inner interval when their complements don't overlap, and an outer when they do."
@@ -101,7 +101,7 @@
right-outer ..outer]
($_ _.and
(_.test "The intersection of an interval to itself yields the same interval."
- (_/= some-interval (/.intersection some-interval some-interval)))
+ (_;= some-interval (/.intersection some-interval some-interval)))
(_.test "The intersection of 2 inner intervals yields an inner interval when they overlap, and an outer when they don't."
(if (/.overlaps? left-inner right-inner)
(/.inner? (/.intersection left-inner right-inner))
@@ -116,7 +116,7 @@
[some-interval ..interval]
($_ _.and
(_.test "The complement of a complement is the same as the original."
- (_/= some-interval (|> some-interval /.complement /.complement)))
+ (_;= some-interval (|> some-interval /.complement /.complement)))
(_.test "The complement of an interval does not overlap it."
(not (/.overlaps? some-interval (/.complement some-interval))))
)))
diff --git a/stdlib/source/test/lux/control/monad.lux b/stdlib/source/test/lux/control/monad.lux
index 5cb498222..2edcd1705 100644
--- a/stdlib/source/test/lux/control/monad.lux
+++ b/stdlib/source/test/lux/control/monad.lux
@@ -1,6 +1,8 @@
(.module:
[lux #*
- data/text/format
+ [data
+ [text
+ format]]
["." function]
[math
["r" random]]
@@ -10,41 +12,41 @@
[//
[functor (#+ Injection Comparison)]])
-(def: (left-identity injection comparison (^open "_/."))
+(def: (left-identity injection comparison (^open "_;."))
(All [f] (-> (Injection f) (Comparison f) (Monad f) Test))
(do r.monad
[sample r.nat
morphism (:: @ map (function (_ diff)
- (|>> (n/+ diff) _/wrap))
+ (|>> (n/+ diff) _;wrap))
r.nat)]
(_.test "Left identity."
((comparison n/=)
- (|> (injection sample) (_/map morphism) _/join)
+ (|> (injection sample) (_;map morphism) _;join)
(morphism sample)))))
-(def: (right-identity injection comparison (^open "_/."))
+(def: (right-identity injection comparison (^open "_;."))
(All [f] (-> (Injection f) (Comparison f) (Monad f) Test))
(do r.monad
[sample r.nat]
(_.test "Right identity."
((comparison n/=)
- (|> (injection sample) (_/map _/wrap) _/join)
+ (|> (injection sample) (_;map _;wrap) _;join)
(injection sample)))))
-(def: (associativity injection comparison (^open "_/."))
+(def: (associativity injection comparison (^open "_;."))
(All [f] (-> (Injection f) (Comparison f) (Monad f) Test))
(do r.monad
[sample r.nat
increase (:: @ map (function (_ diff)
- (|>> (n/+ diff) _/wrap))
+ (|>> (n/+ diff) _;wrap))
r.nat)
decrease (:: @ map (function (_ diff)
- (|>> (n/- diff) _/wrap))
+ (|>> (n/- diff) _;wrap))
r.nat)]
(_.test "Associativity."
((comparison n/=)
- (|> (injection sample) (_/map increase) _/join (_/map decrease) _/join)
- (|> (injection sample) (_/map (|>> increase (_/map decrease) _/join)) _/join)))))
+ (|> (injection sample) (_;map increase) _;join (_;map decrease) _;join)
+ (|> (injection sample) (_;map (|>> increase (_;map decrease) _;join)) _;join)))))
(def: #export (laws injection comparison monad)
(All [f] (-> (Injection f) (Comparison f) (Monad f) Test))
diff --git a/stdlib/source/test/lux/control/parser.lux b/stdlib/source/test/lux/control/parser.lux
index 47740098d..58c2a98d0 100644
--- a/stdlib/source/test/lux/control/parser.lux
+++ b/stdlib/source/test/lux/control/parser.lux
@@ -13,10 +13,10 @@
["." error (#+ Error)]
[number
["." nat]]
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
[math
["r" random]]
[macro
@@ -29,7 +29,7 @@
(All [a] (-> Text (Error a) Bit))
(case input
(#error.Failure actual)
- (text/= expected actual)
+ (text;= expected actual)
_
#0))
@@ -90,16 +90,16 @@
#1))))
(_.test "Can apply a parser 0 or more times."
(and (|> (/.some s.nat)
- (/.run (list/map code.nat expected+))
+ (/.run (list;map code.nat expected+))
(match actual
(:: (list.equivalence nat.equivalence) = expected+ actual)))
(|> (/.some s.nat)
- (/.run (list/map (|>> .int code.int) expected+))
+ (/.run (list;map (|>> .int code.int) expected+))
(match #.Nil
#1))))
(_.test "Can apply a parser 1 or more times."
(and (|> (/.many s.nat)
- (/.run (list/map code.nat expected+))
+ (/.run (list;map code.nat expected+))
(match actual
(:: (list.equivalence nat.equivalence) = expected+ actual)))
(|> (/.many s.nat)
@@ -107,7 +107,7 @@
(match (list actual)
(n/= expected0 actual)))
(|> (/.many s.nat)
- (/.run (list/map (|>> .int code.int) expected+))
+ (/.run (list;map (|>> .int code.int) expected+))
fails?)))
(_.test "Can use either parser."
(let [even (/.filter n/even? s.nat)
@@ -145,63 +145,63 @@
(should-fail failure)))
(_.test "Can apply a parser N times."
(and (|> (/.exactly times s.nat)
- (/.run (list/map code.nat expected+))
+ (/.run (list;map code.nat expected+))
(match actual
(:: (list.equivalence nat.equivalence) =
(list.take times expected+)
actual)))
(|> (/.exactly (inc variadic) s.nat)
- (/.run (list/map code.nat expected+))
+ (/.run (list;map code.nat expected+))
fails?)))
(_.test "Can apply a parser at-least N times."
(and (|> (/.at-least times s.nat)
- (/.run (list/map code.nat expected+))
+ (/.run (list;map code.nat expected+))
(match actual
(:: (list.equivalence nat.equivalence) =
expected+
actual)))
(|> (/.at-least (inc variadic) s.nat)
- (/.run (list/map code.nat expected+))
+ (/.run (list;map code.nat expected+))
fails?)))
(_.test "Can apply a parser at-most N times."
(and (|> (/.at-most times s.nat)
- (/.run (list/map code.nat expected+))
+ (/.run (list;map code.nat expected+))
(match actual
(:: (list.equivalence nat.equivalence) =
(list.take times expected+)
actual)))
(|> (/.at-most (inc variadic) s.nat)
- (/.run (list/map code.nat expected+))
+ (/.run (list;map code.nat expected+))
(match actual
(:: (list.equivalence nat.equivalence) =
expected+
actual)))))
(_.test "Can apply a parser between N and M times."
(and (|> (/.between times variadic s.nat)
- (/.run (list/map code.nat expected+))
+ (/.run (list;map code.nat expected+))
(match actual
(:: (list.equivalence nat.equivalence) =
expected+
actual)))
(|> (/.between times variadic s.nat)
- (/.run (list/map code.nat (list.take times expected+)))
+ (/.run (list;map code.nat (list.take times expected+)))
(match actual
(:: (list.equivalence nat.equivalence) =
(list.take times expected+)
actual)))))
(_.test "Can parse while taking separators into account."
(|> (/.sep-by (s.this (code.text separator)) s.nat)
- (/.run (list.interpose (code.text separator) (list/map code.nat expected+)))
+ (/.run (list.interpose (code.text separator) (list;map code.nat expected+)))
(match actual
(:: (list.equivalence nat.equivalence) =
expected+
actual))))
(_.test "Can obtain the whole of the remaining input."
(|> /.remaining
- (/.run (list/map code.nat expected+))
+ (/.run (list;map code.nat expected+))
(match actual
(:: (list.equivalence code.equivalence) =
- (list/map code.nat expected+)
+ (list;map code.nat expected+)
actual))))
)))
diff --git a/stdlib/source/test/lux/control/pipe.lux b/stdlib/source/test/lux/control/pipe.lux
index 371021ddd..fda914291 100644
--- a/stdlib/source/test/lux/control/pipe.lux
+++ b/stdlib/source/test/lux/control/pipe.lux
@@ -5,7 +5,7 @@
[monad (#+ do)]]
[data
["." identity]
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format]]
[math
["r" random]]]
@@ -32,7 +32,7 @@
(let> x [(n/+ x x)]))))
(_.test "'Conditional' branching."
- (text/= (cond (n/= 0 sample) "zero"
+ (text;= (cond (n/= 0 sample) "zero"
(n/even? sample) "even"
"odd")
(|> sample
@@ -41,7 +41,7 @@
[(new> "odd" [])]))))
(_.test "'If' branching."
- (text/= (if (n/even? sample)
+ (text;= (if (n/even? sample)
"even"
"odd")
(|> sample
@@ -84,10 +84,10 @@
[%n]))]
(and (n/= (inc sample) left)
(n/= (dec sample) middle)
- (text/= (%n sample) right))))
+ (text;= (%n sample) right))))
(_.test "Pattern-matching."
- (text/= (case (n/% 10 sample)
+ (text;= (case (n/% 10 sample)
0 "zero"
1 "one"
2 "two"
diff --git a/stdlib/source/test/lux/control/reader.lux b/stdlib/source/test/lux/control/reader.lux
index 2d83244d6..7cdd022bb 100644
--- a/stdlib/source/test/lux/control/reader.lux
+++ b/stdlib/source/test/lux/control/reader.lux
@@ -44,11 +44,11 @@
(applyT.laws ..injection ..comparison /.apply)
(monadT.laws ..injection ..comparison /.monad)
- (let [(^open "io/.") io.monad]
+ (let [(^open "io;.") io.monad]
(_.test "Can add reader functionality to any monad."
(|> (: (/.Reader Any (IO Nat))
(do (/.with io.monad)
- [a (/.lift (io/wrap sample))
+ [a (/.lift (io;wrap sample))
b (wrap factor)]
(wrap (n/* b a))))
(/.run [])
diff --git a/stdlib/source/test/lux/control/security/integrity.lux b/stdlib/source/test/lux/control/security/integrity.lux
index 7998ba83d..c57d9fde5 100644
--- a/stdlib/source/test/lux/control/security/integrity.lux
+++ b/stdlib/source/test/lux/control/security/integrity.lux
@@ -11,7 +11,7 @@
[".T" monad]]}]
[data
["." error]
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format]]
[math
["r" random]]]
@@ -36,7 +36,7 @@
#let [dirty (/.taint raw)]]
($_ _.and
(_.test "Can clean a dirty value by trusting it."
- (text/= raw (/.trust dirty)))
+ (text;= raw (/.trust dirty)))
(_.test "Can validate a dirty value."
(case (/.validate (function (_ value)
(if (|> value text.size (n/> 0))
@@ -44,7 +44,7 @@
(#error.Failure "Empty text is invalid.")))
dirty)
(#error.Success clean)
- (text/= raw clean)
+ (text;= raw clean)
(#error.Failure error)
false))
diff --git a/stdlib/source/test/lux/control/security/privacy.lux b/stdlib/source/test/lux/control/security/privacy.lux
index fc229d07b..e624ace99 100644
--- a/stdlib/source/test/lux/control/security/privacy.lux
+++ b/stdlib/source/test/lux/control/security/privacy.lux
@@ -12,7 +12,7 @@
[".T" apply]
[".T" monad]]}]
[data
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format]]
[math
["r" random]]]
@@ -53,7 +53,7 @@
(structure
(def: &equivalence
(structure (def: (= reference sample)
- (text/= (!.use %/can-reveal reference)
+ (text;= (!.use %/can-reveal reference)
(!.use %/can-reveal sample)))))
(def: hash
(|>> (!.use %/can-reveal)
diff --git a/stdlib/source/test/lux/control/state.lux b/stdlib/source/test/lux/control/state.lux
index 49cbbcb15..75dd43212 100644
--- a/stdlib/source/test/lux/control/state.lux
+++ b/stdlib/source/test/lux/control/state.lux
@@ -67,10 +67,7 @@
Test
(do r.monad
[state r.nat
- value r.nat
- #let [(^open "&/.") /.functor
- (^open "&/.") /.apply
- (^open "&/.") /.monad]]
+ value r.nat]
($_ _.and
(functorT.laws ..injection (..comparison state) /.functor)
(applyT.laws ..injection (..comparison state) /.apply)
@@ -105,11 +102,11 @@
[state r.nat
left r.nat
right r.nat]
- (let [(^open "io/.") io.monad]
+ (let [(^open "io;.") io.monad]
(_.test "Can add state functionality to any monad."
(|> (: (/.State' io.IO Nat Nat)
(do (/.with io.monad)
- [a (/.lift io.monad (io/wrap left))
+ [a (/.lift io.monad (io;wrap left))
b (wrap right)]
(wrap (n/+ a b))))
(/.run' state)
diff --git a/stdlib/source/test/lux/control/writer.lux b/stdlib/source/test/lux/control/writer.lux
index bed2d68d1..49610dafe 100644
--- a/stdlib/source/test/lux/control/writer.lux
+++ b/stdlib/source/test/lux/control/writer.lux
@@ -13,7 +13,7 @@
[".T" monad]]}]
[data
["." product]
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format]]
[math
["r" random]]]
@@ -38,7 +38,7 @@
(<| (_.context (%name (name-of /.Writer)))
($_ _.and
(_.test "Can write any value."
- (text/= log
+ (text;= log
(product.left (/.write log))))
(functorT.laws (..injection text.monoid) ..comparison /.functor)
@@ -46,10 +46,10 @@
(monadT.laws (..injection text.monoid) ..comparison (/.monad text.monoid))
(let [lift (/.lift text.monoid io.monad)
- (^open "io/.") io.monad]
+ (^open "io;.") io.monad]
(_.test "Can add writer functionality to any monad."
(|> (io.run (do (/.with text.monoid io.monad)
- [a (lift (io/wrap left))
+ [a (lift (io;wrap left))
b (wrap right)]
(wrap (n/+ a b))))
product.right
diff --git a/stdlib/source/test/lux/data/collection/dictionary.lux b/stdlib/source/test/lux/data/collection/dictionary.lux
index b3a275238..80d673574 100644
--- a/stdlib/source/test/lux/data/collection/dictionary.lux
+++ b/stdlib/source/test/lux/data/collection/dictionary.lux
@@ -8,7 +8,7 @@
["." maybe]
[collection
["&" dictionary]
- ["." list ("#/." fold functor)]]]
+ ["." list ("#;." functor)]]]
[math
["r" random]]]
lux/test)
@@ -100,7 +100,7 @@
(test "If you merge, and the second dict has overlapping keys, it should overwrite yours."
(let [dict' (|> dict &.entries
- (list/map (function (_ [k v]) [k (inc v)]))
+ (list;map (function (_ [k v]) [k (inc v)]))
(&.from-list number.hash))
(^open ".") (&.equivalence number.equivalence)]
(= dict' (&.merge dict' dict))))
diff --git a/stdlib/source/test/lux/data/collection/dictionary/ordered.lux b/stdlib/source/test/lux/data/collection/dictionary/ordered.lux
index 233afe569..2d1f5a0ba 100644
--- a/stdlib/source/test/lux/data/collection/dictionary/ordered.lux
+++ b/stdlib/source/test/lux/data/collection/dictionary/ordered.lux
@@ -10,7 +10,7 @@
["s" set]
["dict" dictionary
["&" ordered]]
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
[math
["r" random]]]
lux/test)
@@ -29,8 +29,8 @@
sorted-pairs (list.sort (function (_ [left _] [right _])
(n/< left right))
pairs)
- sorted-values (list/map product.right sorted-pairs)
- (^open "&/.") (&.equivalence number.nat-equivalence)]]
+ sorted-values (list;map product.right sorted-pairs)
+ (^open "&;.") (&.equivalence number.nat-equivalence)]]
($_ seq
(test "Can query the size of a dictionary."
(n/= size (&.size sample)))
@@ -60,14 +60,14 @@
(test "Converting dictionaries to/from lists cannot change their values."
(|> sample
&.entries (&.from-list number.nat-order)
- (&/= sample)))
+ (&;= sample)))
(test "Order is preserved."
- (let [(^open "list/.") (list.equivalence (: (Equivalence [Nat Nat])
+ (let [(^open "list;.") (list.equivalence (: (Equivalence [Nat Nat])
(function (_ [kr vr] [ks vs])
(and (n/= kr ks)
(n/= vr vs)))))]
- (list/= (&.entries sample)
+ (list;= (&.entries sample)
sorted-pairs)))
(test "Every key in a dictionary must be identifiable."
diff --git a/stdlib/source/test/lux/data/collection/list.lux b/stdlib/source/test/lux/data/collection/list.lux
index 9919f3dd1..e5ec2b5b2 100644
--- a/stdlib/source/test/lux/data/collection/list.lux
+++ b/stdlib/source/test/lux/data/collection/list.lux
@@ -30,7 +30,7 @@
other-sample (r.list other-size r.nat)
separator r.nat
#let [(^open ".") (&.equivalence number.equivalence)
- (^open "&/.") &.functor]]
+ (^open "&;.") &.functor]]
($_ seq
(test "The size function should correctly portray the size of the list."
(n/= size (&.size sample)))
@@ -76,7 +76,7 @@
other-sample (r.list other-size r.nat)
separator r.nat
#let [(^open ".") (&.equivalence number.equivalence)
- (^open "&/.") &.functor]]
+ (^open "&;.") &.functor]]
($_ seq
(test "Appending the head and the tail should yield the original list."
(let [head (maybe.assume (&.head sample))
@@ -139,7 +139,7 @@
from (|> r.nat (:: @ map (n/% 10)))
to (|> r.nat (:: @ map (n/% 10)))
#let [(^open ".") (&.equivalence number.equivalence)
- (^open "&/.") &.functor]]
+ (^open "&;.") &.functor]]
($_ seq
(test "If you zip 2 lists, the result's size will be that of the smaller list."
(n/= (&.size (&.zip2 sample other-sample))
@@ -211,28 +211,28 @@
(test "Can enumerate all elements in a list."
(let [enum-sample (&.enumerate sample)]
(and (= (&.indices (&.size enum-sample))
- (&/map product.left enum-sample))
+ (&;map product.left enum-sample))
(= sample
- (&/map product.right enum-sample)))))
+ (&;map product.right enum-sample)))))
(test "Ranges can be constructed forward and backwards."
- (and (let [(^open "list/.") (&.equivalence number.equivalence)]
- (list/= (&.n/range from to)
+ (and (let [(^open "list;.") (&.equivalence number.equivalence)]
+ (list;= (&.n/range from to)
(&.reverse (&.n/range to from))))
- (let [(^open "list/.") (&.equivalence number.equivalence)
+ (let [(^open "list;.") (&.equivalence number.equivalence)
from (.int from)
to (.int to)]
- (list/= (&.i/range from to)
+ (list;= (&.i/range from to)
(&.reverse (&.i/range to from))))))
))))
## TODO: Add again once new-luxc becomes the standard compiler.
(context: "Monad transformer"
(let [lift (&.lift io.monad)
- (^open "io/.") io.monad]
+ (^open "io;.") io.monad]
(test "Can add list functionality to any monad."
(|> (io.run (do (&.ListT io.monad)
- [a (lift (io/wrap +123))
+ [a (lift (io;wrap +123))
b (wrap +456)]
(wrap (i/+ a b))))
(case> (^ (list +579)) #1
diff --git a/stdlib/source/test/lux/data/collection/queue.lux b/stdlib/source/test/lux/data/collection/queue.lux
index 4f4f12ef0..f84246a7f 100644
--- a/stdlib/source/test/lux/data/collection/queue.lux
+++ b/stdlib/source/test/lux/data/collection/queue.lux
@@ -30,10 +30,10 @@
(n/= size (&.size (&.pop (&.push non-member sample))))))
(test "Transforming to/from list can't change the queue."
- (let [(^open "&/.") (&.equivalence number.equivalence)]
+ (let [(^open "&;.") (&.equivalence number.equivalence)]
(|> sample
&.to-list &.from-list
- (&/= sample))))
+ (&;= sample))))
(test "I can always peek at a non-empty queue."
(case (&.peek sample)
diff --git a/stdlib/source/test/lux/data/collection/row.lux b/stdlib/source/test/lux/data/collection/row.lux
index dd70b7272..f4c7ad3a0 100644
--- a/stdlib/source/test/lux/data/collection/row.lux
+++ b/stdlib/source/test/lux/data/collection/row.lux
@@ -7,7 +7,7 @@
["." maybe]
[collection
["&" row]
- ["." list ("#/." fold)]]]
+ ["." list ("#;." fold)]]]
[math
["r" random]]]
lux/test)
@@ -20,11 +20,11 @@
sample (r.row size r.nat)
other-sample (r.row size r.nat)
non-member (|> r.nat (r.filter (|>> (&.member? number.equivalence sample) not)))
- #let [(^open "&/.") (&.equivalence number.equivalence)
- (^open "&/.") &.apply
- (^open "&/.") &.monad
- (^open "&/.") &.fold
- (^open "&/.") &.monoid]]
+ #let [(^open "&;.") (&.equivalence number.equivalence)
+ (^open "&;.") &.apply
+ (^open "&;.") &.monad
+ (^open "&;.") &.fold
+ (^open "&;.") &.monoid]]
($_ seq
(test "Can query size of row."
(if (&.empty? sample)
@@ -50,33 +50,33 @@
(n/= (inc non-member))))
(test "Can safely transform to/from lists."
- (|> sample &.to-list &.from-list (&/= sample)))
+ (|> sample &.to-list &.from-list (&;= sample)))
(test "Can identify members of a row."
(and (not (&.member? number.equivalence sample non-member))
(&.member? number.equivalence (&.add non-member sample) non-member)))
(test "Can fold over elements of row."
- (n/= (list/fold n/+ 0 (&.to-list sample))
- (&/fold n/+ 0 sample)))
+ (n/= (list;fold n/+ 0 (&.to-list sample))
+ (&;fold n/+ 0 sample)))
(test "Functor goes over every element."
- (let [there (&/map inc sample)
- back-again (&/map dec there)]
- (and (not (&/= sample there))
- (&/= sample back-again))))
+ (let [there (&;map inc sample)
+ back-again (&;map dec there)]
+ (and (not (&;= sample there))
+ (&;= sample back-again))))
(test "Apply allows you to create singleton rows, and apply rows of functions to rows of values."
- (and (&/= (&.row non-member) (&/wrap non-member))
- (&/= (&/map inc sample) (&/apply (&/wrap inc) sample))))
+ (and (&;= (&.row non-member) (&;wrap non-member))
+ (&;= (&;map inc sample) (&;apply (&;wrap inc) sample))))
(test "Row concatenation is a monad."
- (&/= (&/compose sample other-sample)
- (&/join (&.row sample other-sample))))
+ (&;= (&;compose sample other-sample)
+ (&;join (&.row sample other-sample))))
(test "Can reverse."
- (and (not (&/= sample
+ (and (not (&;= sample
(&.reverse sample)))
- (not (&/= sample
+ (not (&;= sample
(&.reverse (&.reverse sample))))))
))))
diff --git a/stdlib/source/test/lux/data/collection/sequence.lux b/stdlib/source/test/lux/data/collection/sequence.lux
index 6e806e629..90971d2e9 100644
--- a/stdlib/source/test/lux/data/collection/sequence.lux
+++ b/stdlib/source/test/lux/data/collection/sequence.lux
@@ -6,8 +6,8 @@
[data
["." maybe]
[number
- ["." nat ("#/." codec)]]
- ["." text ("#/." monoid)]
+ ["." nat ("#;." codec)]]
+ ["." text ("#;." monoid)]
[collection
["." list]
["&" sequence]]]
@@ -24,29 +24,29 @@
elem r.nat
cycle-seed (r.list size r.nat)
cycle-sample-idx (|> r.nat (:: @ map (n/% 1000)))
- #let [(^open "List/.") (list.equivalence number.equivalence)
+ #let [(^open "List;.") (list.equivalence number.equivalence)
sample0 (&.iterate inc 0)
sample1 (&.iterate inc offset)]]
($_ seq
(test "Can move along a sequence and take slices off it."
- (and (and (List/= (list.n/range 0 (dec size))
+ (and (and (List;= (list.n/range 0 (dec size))
(&.take size sample0))
- (List/= (list.n/range offset (dec (n/+ offset size)))
+ (List;= (list.n/range offset (dec (n/+ offset size)))
(&.take size (&.drop offset sample0)))
(let [[drops takes] (&.split size sample0)]
- (and (List/= (list.n/range 0 (dec size))
+ (and (List;= (list.n/range 0 (dec size))
drops)
- (List/= (list.n/range size (dec (n/* 2 size)))
+ (List;= (list.n/range size (dec (n/* 2 size)))
(&.take size takes)))))
- (and (List/= (list.n/range 0 (dec size))
+ (and (List;= (list.n/range 0 (dec size))
(&.take-while (n/< size) sample0))
- (List/= (list.n/range offset (dec (n/+ offset size)))
+ (List;= (list.n/range offset (dec (n/+ offset size)))
(&.take-while (n/< (n/+ offset size))
(&.drop-while (n/< offset) sample0)))
(let [[drops takes] (&.split-while (n/< size) sample0)]
- (and (List/= (list.n/range 0 (dec size))
+ (and (List;= (list.n/range 0 (dec size))
drops)
- (List/= (list.n/range size (dec (n/* 2 size)))
+ (List;= (list.n/range size (dec (n/* 2 size)))
(&.take-while (n/< (n/* 2 size)) takes)))))
))
@@ -55,7 +55,7 @@
(test "Can obtain the head & tail of a sequence."
(and (n/= offset (&.head sample1))
- (List/= (list.n/range (inc offset) (n/+ offset size))
+ (List;= (list.n/range (inc offset) (n/+ offset size))
(&.take size (&.tail sample1)))))
(test "Can filter sequences."
@@ -69,29 +69,29 @@
(&.nth offset odds))))))
(test "Functor goes over 'all' elements in a sequence."
- (let [(^open "&/.") &.functor
- there (&/map (n/* factor) sample0)
- back-again (&/map (n// factor) there)]
- (and (not (List/= (&.take size sample0)
+ (let [(^open "&;.") &.functor
+ there (&;map (n/* factor) sample0)
+ back-again (&;map (n// factor) there)]
+ (and (not (List;= (&.take size sample0)
(&.take size there)))
- (List/= (&.take size sample0)
+ (List;= (&.take size sample0)
(&.take size back-again)))))
(test "CoMonad produces a value for every element in a sequence."
- (let [(^open "&/.") &.functor]
- (List/= (&.take size (&/map (n/* factor) sample1))
+ (let [(^open "&;.") &.functor]
+ (List;= (&.take size (&;map (n/* factor) sample1))
(&.take size
(be &.comonad
[inputs sample1]
(n/* factor (&.head inputs)))))))
(test "'unfold' generalizes 'iterate'."
- (let [(^open "&/.") &.functor
- (^open "List/.") (list.equivalence text.equivalence)]
- (List/= (&.take size
- (&/map nat/encode (&.iterate inc offset)))
+ (let [(^open "&;.") &.functor
+ (^open "List;.") (list.equivalence text.equivalence)]
+ (List;= (&.take size
+ (&;map nat;encode (&.iterate inc offset)))
(&.take size
- (&.unfold (function (_ n) [(inc n) (nat/encode n)])
+ (&.unfold (function (_ n) [(inc n) (nat;encode n)])
offset)))))
(test "Can cycle over the same elements as an infinite sequence."
diff --git a/stdlib/source/test/lux/data/collection/set.lux b/stdlib/source/test/lux/data/collection/set.lux
index bbdc945f7..b383f32c2 100644
--- a/stdlib/source/test/lux/data/collection/set.lux
+++ b/stdlib/source/test/lux/data/collection/set.lux
@@ -25,7 +25,7 @@
setR (r.set number.hash sizeR gen-nat)
non-member (|> gen-nat
(r.filter (|>> (&.member? setL) not)))
- #let [(^open "&/.") &.equivalence]]
+ #let [(^open "&;.") &.equivalence]]
($_ seq
(test "I can query the size of a set."
(and (n/= sizeL (&.size setL))
@@ -34,7 +34,7 @@
(test "Converting sets to/from lists can't change their values."
(|> setL
&.to-list (&.from-list number.hash)
- (&/= setL)))
+ (&;= setL)))
(test "Every set is a sub-set of the union of itself with another."
(let [setLR (&.union setL setR)]
@@ -47,13 +47,13 @@
(&.super? setLR setR))))
(test "Union with the empty set leaves a set unchanged."
- (&/= setL
+ (&;= setL
(&.union (&.new number.hash)
setL)))
(test "Intersection with the empty set results in the empty set."
(let [empty-set (&.new number.hash)]
- (&/= empty-set
+ (&;= empty-set
(&.intersection empty-set setL))))
(test "After substracting a set A from another B, no member of A can be a member of B."
diff --git a/stdlib/source/test/lux/data/collection/set/ordered.lux b/stdlib/source/test/lux/data/collection/set/ordered.lux
index 384a0506b..78d096cef 100644
--- a/stdlib/source/test/lux/data/collection/set/ordered.lux
+++ b/stdlib/source/test/lux/data/collection/set/ordered.lux
@@ -26,7 +26,7 @@
sizeR gen-nat
listL (|> (r.set number.hash sizeL gen-nat) (:: @ map set.to-list))
listR (|> (r.set number.hash sizeR gen-nat) (:: @ map set.to-list))
- #let [(^open "&/.") &.equivalence
+ #let [(^open "&;.") &.equivalence
setL (&.from-list number.order listL)
setR (&.from-list number.order listR)
sortedL (list.sort n/< listL)
@@ -61,7 +61,7 @@
(test "Converting sets to/from lists can't change their values."
(|> setL
&.to-list (&.from-list number.order)
- (&/= setL)))
+ (&;= setL)))
(test "Order is preserved."
(let [listL (&.to-list setL)
@@ -80,13 +80,13 @@
(&.super? setLR setR))))
(test "Union with the empty set leaves a set unchanged."
- (&/= setL
+ (&;= setL
(&.union (&.new number.order)
setL)))
(test "Intersection with the empty set results in the empty set."
(let [empty-set (&.new number.order)]
- (&/= empty-set
+ (&;= empty-set
(&.intersection empty-set setL))))
(test "After substracting a set A from another B, no member of A can be a member of B."
diff --git a/stdlib/source/test/lux/data/collection/tree/rose.lux b/stdlib/source/test/lux/data/collection/tree/rose.lux
index 388065ef0..f4ddee14e 100644
--- a/stdlib/source/test/lux/data/collection/tree/rose.lux
+++ b/stdlib/source/test/lux/data/collection/tree/rose.lux
@@ -5,10 +5,10 @@
[data
["." product]
["." number]
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format]
[collection
- ["." list ("#/." functor fold)]
+ ["." list ("#;." functor fold)]
[tree
["&" rose]]]]
[math
@@ -24,8 +24,8 @@
[value r.nat
num-children (|> r.nat (:: @ map (n/% 3)))
children' (r.list num-children gen-tree)
- #let [size' (list/fold n/+ 0 (list/map product.left children'))
- children (list/map product.right children')]]
+ #let [size' (list;fold n/+ 0 (list;map product.left children'))
+ children (list;map product.right children')]]
(wrap [(inc size')
(&.branch value children)]))
))))
@@ -34,18 +34,18 @@
(<| (times 100)
(do @
[[size sample] gen-tree
- #let [(^open "&/.") (&.equivalence number.equivalence)
- (^open "&/.") &.fold
+ #let [(^open "&;.") (&.equivalence number.equivalence)
+ (^open "&;.") &.fold
concat (function (_ addition partial) (format partial (%n addition)))]]
($_ seq
(test "Can compare trees for equivalence."
- (&/= sample sample))
+ (&;= sample sample))
(test "Can flatten a tree to get all the nodes as a flat tree."
(n/= size
(list.size (&.flatten sample))))
(test "Can fold trees."
- (text/= (&/fold concat "" sample)
- (list/fold concat "" (&.flatten sample))))
+ (text;= (&;fold concat "" sample)
+ (list;fold concat "" (&.flatten sample))))
))))
diff --git a/stdlib/source/test/lux/data/collection/tree/rose/zipper.lux b/stdlib/source/test/lux/data/collection/tree/rose/zipper.lux
index 3abf1dd26..769e11293 100644
--- a/stdlib/source/test/lux/data/collection/tree/rose/zipper.lux
+++ b/stdlib/source/test/lux/data/collection/tree/rose/zipper.lux
@@ -41,7 +41,7 @@
pre-val r.nat
post-val r.nat
#let [(^open "tree/.") (rose.equivalence number.equivalence)
- (^open "list/.") (list.equivalence number.equivalence)]]
+ (^open "list;.") (list.equivalence number.equivalence)]]
($_ seq
(test "Trees can be converted to/from zippers."
(|> sample
@@ -102,7 +102,7 @@
(|> sample &.zip (&.set new-val) &.value (n/= new-val)))
(test "Zipper traversal follows the outline of the tree depth-first."
- (list/= (rose.flatten sample)
+ (list;= (rose.flatten sample)
(loop [zipper (&.zip sample)]
(if (&.end? zipper)
(list (&.value zipper))
@@ -110,7 +110,7 @@
(recur (&.next zipper)))))))
(test "Backwards zipper traversal yield reverse tree flatten."
- (list/= (list.reverse (rose.flatten sample))
+ (list;= (list.reverse (rose.flatten sample))
(loop [zipper (to-end (&.zip sample))]
(if (&.root? zipper)
(list (&.value zipper))
diff --git a/stdlib/source/test/lux/data/color.lux b/stdlib/source/test/lux/data/color.lux
index 24ed8f615..5546a9d90 100644
--- a/stdlib/source/test/lux/data/color.lux
+++ b/stdlib/source/test/lux/data/color.lux
@@ -5,7 +5,7 @@
[data
["@" color]
[number
- ["." frac ("#/." number)]]]
+ ["." frac ("#;." number)]]]
["." math
["r" random]]]
lux/test)
@@ -95,6 +95,6 @@
(saturation gray'ed))
(|> (luminance gray'ed)
(f/- (luminance mediocre))
- frac/abs
+ frac;abs
(f/<= error-margin)))))
))))
diff --git a/stdlib/source/test/lux/data/error.lux b/stdlib/source/test/lux/data/error.lux
index 7f491dc2c..78e63338e 100644
--- a/stdlib/source/test/lux/data/error.lux
+++ b/stdlib/source/test/lux/data/error.lux
@@ -9,25 +9,25 @@
lux/test)
(context: "Errors"
- (let [(^open "//.") /.apply
- (^open "//.") /.monad]
+ (let [(^open "&;.") /.apply
+ (^open "&;.") /.monad]
($_ seq
(test "Functor correctly handles both cases."
(and (|> (: (Error Int) (#/.Success +10))
- (//map inc)
+ (&;map inc)
(case> (#/.Success +11) #1 _ #0))
(|> (: (Error Int) (#/.Failure "YOLO"))
- (//map inc)
+ (&;map inc)
(case> (#/.Failure "YOLO") #1 _ #0))
))
(test "Apply correctly handles both cases."
- (and (|> (//wrap +20)
+ (and (|> (&;wrap +20)
(case> (#/.Success +20) #1 _ #0))
- (|> (//apply (//wrap inc) (//wrap +10))
+ (|> (&;apply (&;wrap inc) (&;wrap +10))
(case> (#/.Success +11) #1 _ #0))
- (|> (//apply (//wrap inc) (#/.Failure "YOLO"))
+ (|> (&;apply (&;wrap inc) (#/.Failure "YOLO"))
(case> (#/.Failure "YOLO") #1 _ #0))))
(test "Monad correctly handles both cases."
@@ -48,10 +48,10 @@
(context: "Monad transformer"
(let [lift (/.lift io.monad)
- (^open "io/.") io.monad]
+ (^open "io;.") io.monad]
(test "Can add error functionality to any monad."
(|> (io.run (do (/.ErrorT io.monad)
- [a (lift (io/wrap +123))
+ [a (lift (io;wrap +123))
b (wrap +456)]
(wrap (i/+ a b))))
(case> (#/.Success +579)
diff --git a/stdlib/source/test/lux/data/format/xml.lux b/stdlib/source/test/lux/data/format/xml.lux
index 05784915f..35e7dc4a1 100644
--- a/stdlib/source/test/lux/data/format/xml.lux
+++ b/stdlib/source/test/lux/data/format/xml.lux
@@ -8,15 +8,15 @@
["." name]
["E" error]
["." maybe]
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format]
[format
["&" xml]]
[collection
["dict" dictionary]
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
[math
- ["r" random ("#/." monad)]]]
+ ["r" random ("#;." monad)]]]
lux/test)
(def: char-range
@@ -34,7 +34,7 @@
(def: (size^ bottom top)
(-> Nat Nat (r.Random Nat))
(let [constraint (|>> (n/% top) (n/max bottom))]
- (r/map constraint r.nat)))
+ (r;map constraint r.nat)))
(def: (xml-text^ bottom top)
(-> Nat Nat (r.Random Text))
@@ -62,16 +62,16 @@
(<| (times 100)
(do @
[sample gen-xml
- #let [(^open "&/.") &.equivalence
- (^open "&/.") &.codec]]
+ #let [(^open "&;.") &.equivalence
+ (^open "&;.") &.codec]]
($_ seq
(test "Every XML is equal to itself."
- (&/= sample sample))
+ (&;= sample sample))
(test "Can encode/decode XML."
- (|> sample &/encode &/decode
+ (|> sample &;encode &;decode
(case> (#.Right result)
- (&/= sample result)
+ (&;= sample result)
(#.Left error)
#0)))
@@ -88,21 +88,21 @@
value (xml-text^ 1 10)
#let [node (#&.Node tag
(dict.put attr value &.attrs)
- (list/map (|>> #&.Text) children))]]
+ (list;map (|>> #&.Text) children))]]
($_ seq
(test "Can parse text."
(E.default #0
(do E.monad
[output (&.run (#&.Text text)
&.text)]
- (wrap (text/= text output)))))
+ (wrap (text;= text output)))))
(test "Can parse attributes."
(E.default #0
(do E.monad
[output (|> (&.attr attr)
(p.before &.ignore)
(&.run node))]
- (wrap (text/= value output)))))
+ (wrap (text;= value output)))))
(test "Can parse nodes."
(E.default #0
(do E.monad
diff --git a/stdlib/source/test/lux/data/identity.lux b/stdlib/source/test/lux/data/identity.lux
index 22511e7b3..293f5d075 100644
--- a/stdlib/source/test/lux/data/identity.lux
+++ b/stdlib/source/test/lux/data/identity.lux
@@ -5,32 +5,32 @@
comonad]
[data
["&" identity]
- ["." text ("#/." monoid equivalence)]]]
+ ["." text ("#;." monoid equivalence)]]]
lux/test)
(context: "Identity"
- (let [(^open "&/.") &.apply
- (^open "&/.") &.monad
- (^open "&/.") &.comonad]
+ (let [(^open "&;.") &.apply
+ (^open "&;.") &.monad
+ (^open "&;.") &.comonad]
($_ seq
(test "Functor does not affect values."
- (text/= "yololol" (&/map (text/compose "yolo") "lol")))
+ (text;= "yololol" (&;map (text;compose "yolo") "lol")))
(test "Apply does not affect values."
- (and (text/= "yolo" (&/wrap "yolo"))
- (text/= "yololol" (&/apply (&/wrap (text/compose "yolo")) (&/wrap "lol")))))
+ (and (text;= "yolo" (&;wrap "yolo"))
+ (text;= "yololol" (&;apply (&;wrap (text;compose "yolo")) (&;wrap "lol")))))
(test "Monad does not affect values."
- (text/= "yololol" (do &.monad
- [f (wrap text/compose)
+ (text;= "yololol" (do &.monad
+ [f (wrap text;compose)
a (wrap "yolo")
b (wrap "lol")]
(wrap (f a b)))))
(test "CoMonad does not affect values."
- (and (text/= "yololol" (&/unwrap "yololol"))
- (text/= "yololol" (be &.comonad
- [f text/compose
+ (and (text;= "yololol" (&;unwrap "yololol"))
+ (text;= "yololol" (be &.comonad
+ [f text;compose
a "yolo"
b "lol"]
(f a b)))))
diff --git a/stdlib/source/test/lux/data/lazy.lux b/stdlib/source/test/lux/data/lazy.lux
index f00b572ab..5fe6464ff 100644
--- a/stdlib/source/test/lux/data/lazy.lux
+++ b/stdlib/source/test/lux/data/lazy.lux
@@ -46,9 +46,9 @@
(n/= (inc sample))))
(test "Apply apply."
- (let [(^open "&/.") &.monad
- (^open "&/.") &.apply]
- (|> (&/apply (&/wrap inc) (&/wrap sample))
+ (let [(^open "&;.") &.monad
+ (^open "&;.") &.apply]
+ (|> (&;apply (&;wrap inc) (&;wrap sample))
&.thaw
(n/= (inc sample)))))
))))
diff --git a/stdlib/source/test/lux/data/maybe.lux b/stdlib/source/test/lux/data/maybe.lux
index a6ec17131..f42be25bf 100644
--- a/stdlib/source/test/lux/data/maybe.lux
+++ b/stdlib/source/test/lux/data/maybe.lux
@@ -4,42 +4,42 @@
["M" monad (#+ Monad do)]
pipe]
[data
- ["&" maybe ("#/." monoid)]
- ["." text ("#/." monoid)]]
- ["." io ("#/." monad)]]
+ ["&" maybe ("#;." monoid)]
+ ["." text ("#;." monoid)]]
+ ["." io ("#;." monad)]]
lux/test)
(context: "Maybe"
- (let [(^open "&/.") &.apply
- (^open "&/.") &.monad
- (^open "&/.") (&.equivalence text.equivalence)]
+ (let [(^open "&;.") &.apply
+ (^open "&;.") &.monad
+ (^open "&;.") (&.equivalence text.equivalence)]
($_ seq
(test "Can compare Maybe values."
- (and (&/= #.None #.None)
- (&/= (#.Some "yolo") (#.Some "yolo"))
- (not (&/= (#.Some "yolo") (#.Some "lol")))
- (not (&/= (#.Some "yolo") #.None))))
+ (and (&;= #.None #.None)
+ (&;= (#.Some "yolo") (#.Some "yolo"))
+ (not (&;= (#.Some "yolo") (#.Some "lol")))
+ (not (&;= (#.Some "yolo") #.None))))
(test "Monoid respects Maybe."
- (and (&/= #.None &/identity)
- (&/= (#.Some "yolo") (&/compose (#.Some "yolo") (#.Some "lol")))
- (&/= (#.Some "yolo") (&/compose (#.Some "yolo") #.None))
- (&/= (#.Some "lol") (&/compose #.None (#.Some "lol")))
- (&/= #.None (: (Maybe Text) (&/compose #.None #.None)))))
+ (and (&;= #.None &;identity)
+ (&;= (#.Some "yolo") (&;compose (#.Some "yolo") (#.Some "lol")))
+ (&;= (#.Some "yolo") (&;compose (#.Some "yolo") #.None))
+ (&;= (#.Some "lol") (&;compose #.None (#.Some "lol")))
+ (&;= #.None (: (Maybe Text) (&;compose #.None #.None)))))
(test "Functor respects Maybe."
- (and (&/= #.None (&/map (text/compose "yolo") #.None))
- (&/= (#.Some "yololol") (&/map (text/compose "yolo") (#.Some "lol")))))
+ (and (&;= #.None (&;map (text;compose "yolo") #.None))
+ (&;= (#.Some "yololol") (&;map (text;compose "yolo") (#.Some "lol")))))
(test "Apply respects Maybe."
- (and (&/= (#.Some "yolo") (&/wrap "yolo"))
- (&/= (#.Some "yololol")
- (&/apply (&/wrap (text/compose "yolo")) (&/wrap "lol")))))
+ (and (&;= (#.Some "yolo") (&;wrap "yolo"))
+ (&;= (#.Some "yololol")
+ (&;apply (&;wrap (text;compose "yolo")) (&;wrap "lol")))))
(test "Monad respects Maybe."
- (&/= (#.Some "yololol")
+ (&;= (#.Some "yololol")
(do &.monad
- [f (wrap text/compose)
+ [f (wrap text;compose)
a (wrap "yolo")
b (wrap "lol")]
(wrap (f a b)))))
@@ -59,7 +59,7 @@
(let [lift (&.lift io.monad)]
(test "Can add maybe functionality to any monad."
(|> (io.run (do (&.MaybeT io.monad)
- [a (lift (io/wrap +123))
+ [a (lift (io;wrap +123))
b (wrap +456)]
(wrap (i/+ a b))))
(case> (#.Some +579)
diff --git a/stdlib/source/test/lux/data/name.lux b/stdlib/source/test/lux/data/name.lux
index 57d4d9a1e..32744ad5f 100644
--- a/stdlib/source/test/lux/data/name.lux
+++ b/stdlib/source/test/lux/data/name.lux
@@ -5,7 +5,7 @@
pipe]
[data
["&" name]
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format]]
[math
["r" random]]]
@@ -30,44 +30,44 @@
module2 (gen-part sizeM2)
short2 (gen-part sizeN2)
#let [name2 [module2 short2]]
- #let [(^open "&/.") &.equivalence
- (^open "&/.") &.codec]]
+ #let [(^open "&;.") &.equivalence
+ (^open "&;.") &.codec]]
($_ seq
(test "Can get the module & short parts of an name."
(and (is? module1 (&.module name1))
(is? short1 (&.short name1))))
(test "Can compare names for equivalence."
- (and (&/= name1 name1)
- (if (&/= name1 name2)
- (and (text/= module1 module2)
- (text/= short1 short2))
- (or (not (text/= module1 module2))
- (not (text/= short1 short2))))))
+ (and (&;= name1 name1)
+ (if (&;= name1 name2)
+ (and (text;= module1 module2)
+ (text;= short1 short2))
+ (or (not (text;= module1 module2))
+ (not (text;= short1 short2))))))
(test "Can encode names as text."
(|> name1
- &/encode &/decode
- (case> (#.Right dec-name) (&/= name1 dec-name)
+ &;encode &;decode
+ (case> (#.Right dec-name) (&;= name1 dec-name)
_ #0)))
(test "Encoding an name without a module component results in text equal to the short of the name."
(if (text.empty? module1)
- (text/= short1 (&/encode name1))
+ (text;= short1 (&;encode name1))
#1))
))))
(context: "Name-related macros."
- (let [(^open "&/.") &.equivalence]
+ (let [(^open "&;.") &.equivalence]
($_ seq
(test "Can obtain Name from identifier."
- (and (&/= ["lux" "yolo"] (name-of .yolo))
- (&/= ["test/lux/data/name" "yolo"] (name-of ..yolo))
- (&/= ["" "yolo"] (name-of yolo))
- (&/= ["lux/test" "yolo"] (name-of lux/test.yolo))))
+ (and (&;= ["lux" "yolo"] (name-of .yolo))
+ (&;= ["test/lux/data/name" "yolo"] (name-of ..yolo))
+ (&;= ["" "yolo"] (name-of yolo))
+ (&;= ["lux/test" "yolo"] (name-of lux/test.yolo))))
(test "Can obtain Name from tag."
- (and (&/= ["lux" "yolo"] (name-of #.yolo))
- (&/= ["test/lux/data/name" "yolo"] (name-of #..yolo))
- (&/= ["" "yolo"] (name-of #yolo))
- (&/= ["lux/test" "yolo"] (name-of #lux/test.yolo)))))))
+ (and (&;= ["lux" "yolo"] (name-of #.yolo))
+ (&;= ["test/lux/data/name" "yolo"] (name-of #..yolo))
+ (&;= ["" "yolo"] (name-of #yolo))
+ (&;= ["lux/test" "yolo"] (name-of #lux/test.yolo)))))))
diff --git a/stdlib/source/test/lux/data/number.lux b/stdlib/source/test/lux/data/number.lux
index 9460b149b..7b57ffc63 100644
--- a/stdlib/source/test/lux/data/number.lux
+++ b/stdlib/source/test/lux/data/number.lux
@@ -5,7 +5,7 @@
pipe]
[data
number
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format]]
[math
["r" random]]]
@@ -37,11 +37,11 @@
(^open ".") <Order>]]
(test "" (and (>= x (abs x))
## abs(0.0) == 0.0 && negate(abs(0.0)) == -0.0
- (or (text/= "Frac" category)
+ (or (text;= "Frac" category)
(not (= x (negate x))))
(= x (negate (negate x)))
## There is loss of precision when multiplying
- (or (text/= "Rev" category)
+ (or (text;= "Rev" category)
(= x (* (signum x)
(abs x)))))))))]
diff --git a/stdlib/source/test/lux/data/number/complex.lux b/stdlib/source/test/lux/data/number/complex.lux
index a622ef6b3..106edf33d 100644
--- a/stdlib/source/test/lux/data/number/complex.lux
+++ b/stdlib/source/test/lux/data/number/complex.lux
@@ -5,10 +5,10 @@
pipe]
[data
["." number
- ["." frac ("#/." number)]
+ ["." frac ("#;." number)]
["&" complex]]
[collection
- ["." list ("#/." functor)]]]
+ ["." list ("#;." functor)]]]
["." math
["r" random]]]
lux/test)
@@ -17,9 +17,9 @@
(def: (within? margin standard value)
(-> Frac &.Complex &.Complex Bit)
- (let [real-dist (frac/abs (f/- (get@ #&.real standard)
+ (let [real-dist (frac;abs (f/- (get@ #&.real standard)
(get@ #&.real value)))
- imgn-dist (frac/abs (f/- (get@ #&.imaginary standard)
+ imgn-dist (frac;abs (f/- (get@ #&.imaginary standard)
(get@ #&.imaginary value)))]
(and (f/< margin real-dist)
(f/< margin imgn-dist))))
@@ -64,8 +64,8 @@
(test "Absolute value of complex >= absolute value of any of the parts."
(let [r+i (&.complex real imaginary)
abs (get@ #&.real (&.abs r+i))]
- (and (f/>= (frac/abs real) abs)
- (f/>= (frac/abs imaginary) abs))))
+ (and (f/>= (frac;abs real) abs)
+ (f/>= (frac;abs imaginary) abs))))
(test "The absolute value of a complex number involving a NaN on either dimension, results in a NaN value."
(and (number.not-a-number? (get@ #&.real (&.abs (&.complex number.not-a-number imaginary))))
@@ -131,7 +131,7 @@
(let [cx (&.conjugate x)]
(and (f/= (get@ #&.real x)
(get@ #&.real cx))
- (f/= (frac/negate (get@ #&.imaginary x))
+ (f/= (frac;negate (get@ #&.imaginary x))
(get@ #&.imaginary cx)))))
(test "The reciprocal functions is its own inverse."
@@ -198,5 +198,5 @@
(test "Can calculate the N roots for any complex number."
(|> sample
(&.roots degree)
- (list/map (&.pow' (|> degree .int int-to-frac)))
+ (list;map (&.pow' (|> degree .int int-to-frac)))
(list.every? (within? margin-of-error sample)))))))
diff --git a/stdlib/source/test/lux/data/number/ratio.lux b/stdlib/source/test/lux/data/number/ratio.lux
index 63d1e5fc8..a68e5abca 100644
--- a/stdlib/source/test/lux/data/number/ratio.lux
+++ b/stdlib/source/test/lux/data/number/ratio.lux
@@ -5,7 +5,7 @@
pipe]
[data
[number
- ["&" ratio ("&/." number)]]]
+ ["&" ratio ("&;." number)]]]
[math
["r" random]]]
lux/test)
@@ -77,16 +77,16 @@
[sample gen-ratio]
($_ seq
(test "Negation is it's own inverse."
- (let [there (&/negate sample)
- back-again (&/negate there)]
+ (let [there (&;negate sample)
+ back-again (&;negate there)]
(and (not (&.= there sample))
(&.= back-again sample))))
(test "All ratios are already at their absolute value."
- (|> sample &/abs (&.= sample)))
+ (|> sample &;abs (&.= sample)))
(test "Signum is the identity."
- (|> sample (&.* (&/signum sample)) (&.= sample)))
+ (|> sample (&.* (&;signum sample)) (&.= sample)))
))))
(context: "Order"
@@ -106,9 +106,9 @@
(<| (times 100)
(do @
[sample gen-ratio
- #let [(^open "&/.") &.codec]]
+ #let [(^open "&;.") &.codec]]
(test "Can encode/decode ratios."
- (|> sample &/encode &/decode
+ (|> sample &;encode &;decode
(case> (#.Right output)
(&.= sample output)
diff --git a/stdlib/source/test/lux/data/text.lux b/stdlib/source/test/lux/data/text.lux
index 01cd2220d..ea9a36fe2 100644
--- a/stdlib/source/test/lux/data/text.lux
+++ b/stdlib/source/test/lux/data/text.lux
@@ -114,30 +114,30 @@
parts (r.list sizeL part-gen)
#let [sample1 (&.concat (list.interpose sep1 parts))
sample2 (&.concat (list.interpose sep2 parts))
- (^open "&/.") &.equivalence]]
+ (^open "&;.") &.equivalence]]
($_ seq
(test "Can split text through a separator."
(n/= (list.size parts)
(list.size (&.split-all-with sep1 sample1))))
(test "Can replace occurrences of a piece of text inside a larger text."
- (&/= sample2
+ (&;= sample2
(&.replace-all sep1 sep2 sample1)))
))))
(context: "Structures"
- (let [(^open "&/.") &.order]
+ (let [(^open "&;.") &.order]
($_ seq
- (test "" (&/< "bcd" "abc"))
- (test "" (not (&/< "abc" "abc")))
- (test "" (not (&/< "abc" "bcd")))
- (test "" (&/<= "bcd" "abc"))
- (test "" (&/<= "abc" "abc"))
- (test "" (not (&/<= "abc" "bcd")))
- (test "" (&/> "abc" "bcd"))
- (test "" (not (&/> "abc" "abc")))
- (test "" (not (&/> "bcd" "abc")))
- (test "" (&/>= "abc" "bcd"))
- (test "" (&/>= "abc" "abc"))
- (test "" (not (&/>= "bcd" "abc")))
+ (test "" (&;< "bcd" "abc"))
+ (test "" (not (&;< "abc" "abc")))
+ (test "" (not (&;< "abc" "bcd")))
+ (test "" (&;<= "bcd" "abc"))
+ (test "" (&;<= "abc" "abc"))
+ (test "" (not (&;<= "abc" "bcd")))
+ (test "" (&;> "abc" "bcd"))
+ (test "" (not (&;> "abc" "abc")))
+ (test "" (not (&;> "bcd" "abc")))
+ (test "" (&;>= "abc" "bcd"))
+ (test "" (&;>= "abc" "abc"))
+ (test "" (not (&;>= "bcd" "abc")))
)))
diff --git a/stdlib/source/test/lux/data/text/format.lux b/stdlib/source/test/lux/data/text/format.lux
index d3bbafe7e..1a7ab01cf 100644
--- a/stdlib/source/test/lux/data/text/format.lux
+++ b/stdlib/source/test/lux/data/text/format.lux
@@ -8,14 +8,14 @@
lux/test)
(context: "Formatters"
- (let [(^open "&/.") text.equivalence]
+ (let [(^open "&;.") text.equivalence]
($_ seq
(test "Can format common values simply."
- (and (&/= "#1" (%b #1))
- (&/= "123" (%n 123))
- (&/= "+123" (%i +123))
- (&/= "+123.456" (%f +123.456))
- (&/= ".5" (%r .5))
- (&/= (format text.double-quote "YOLO" text.double-quote) (%t "YOLO"))
- (&/= "User-id: +123 -- Active: #1" (format "User-id: " (%i +123) " -- Active: " (%b #1)))))
+ (and (&;= "#1" (%b #1))
+ (&;= "123" (%n 123))
+ (&;= "+123" (%i +123))
+ (&;= "+123.456" (%f +123.456))
+ (&;= ".5" (%r .5))
+ (&;= (format text.double-quote "YOLO" text.double-quote) (%t "YOLO"))
+ (&;= "User-id: +123 -- Active: #1" (format "User-id: " (%i +123) " -- Active: " (%b #1)))))
)))
diff --git a/stdlib/source/test/lux/data/text/lexer.lux b/stdlib/source/test/lux/data/text/lexer.lux
index dc8cf75c9..77419362a 100644
--- a/stdlib/source/test/lux/data/text/lexer.lux
+++ b/stdlib/source/test/lux/data/text/lexer.lux
@@ -6,7 +6,7 @@
["p" parser]]
[data
["." error (#+ Error)]
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format
["&" lexer]]
[collection
@@ -26,17 +26,17 @@
(-> Text (Error Text) Bit)
(case input
(#.Right output)
- (text/= test output)
+ (text;= test output)
_
#0))
(def: (should-passL test input)
(-> (List Text) (Error (List Text)) Bit)
- (let [(^open "list/.") (list.equivalence text.equivalence)]
+ (let [(^open "list;.") (list.equivalence text.equivalence)]
(case input
(#.Right output)
- (list/= test output)
+ (list;= test output)
_
#0)))
@@ -47,10 +47,10 @@
(#.Right output)
(case [test output]
[(#.Left test) (#.Left output)]
- (text/= test output)
+ (text;= test output)
[(#.Right test) (#.Right output)]
- (text/= test output)
+ (text;= test output)
_
#0)
@@ -78,7 +78,7 @@
[size (|> r.nat (:: @ map (|>> (n/% 100) (n/max 10))))
sample (r.unicode size)
non-sample (|> (r.unicode size)
- (r.filter (|>> (text/= sample) not)))]
+ (r.filter (|>> (text;= sample) not)))]
($_ seq
(test "Can find literal text fragments."
(and (|> (&.run sample
diff --git a/stdlib/source/test/lux/data/text/regex.lux b/stdlib/source/test/lux/data/text/regex.lux
index cbb44f332..ffa5612da 100644
--- a/stdlib/source/test/lux/data/text/regex.lux
+++ b/stdlib/source/test/lux/data/text/regex.lux
@@ -6,7 +6,7 @@
["p" parser]]
[data
[number (#+ hex)]
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format
["." lexer (#+ Lexer)]
["&" regex]]]
@@ -21,7 +21,7 @@
(-> (Lexer Text) Text Bit)
(|> (lexer.run input regex)
(case> (#.Right parsed)
- (text/= parsed input)
+ (text;= parsed input)
_
#0)))
@@ -30,7 +30,7 @@
(-> Text (Lexer Text) Text Bit)
(|> (lexer.run input regex)
(case> (#.Right parsed)
- (text/= test parsed)
+ (text;= test parsed)
_
#0)))
@@ -277,9 +277,9 @@
(&.^regex "(.{3})-(.{3})-(.{4})"
[_ match1 match2 match3])
(test "Can pattern-match using regular-expressions."
- (and (text/= sample1 match1)
- (text/= sample2 match2)
- (text/= sample3 match3)))
+ (and (text;= sample1 match1)
+ (text;= sample2 match2)
+ (text;= sample3 match3)))
_
(test "Cannot pattern-match using regular-expressions."
diff --git a/stdlib/source/test/lux/host.jvm.lux b/stdlib/source/test/lux/host.jvm.lux
index 318a66cec..20530d923 100644
--- a/stdlib/source/test/lux/host.jvm.lux
+++ b/stdlib/source/test/lux/host.jvm.lux
@@ -4,7 +4,7 @@
[monad (#+ Monad do)]
pipe]
[data
- ["." text ("#/." equivalence)]]
+ ["." text ("#;." equivalence)]]
[math
["r" random]]
["_" test (#+ Test)]]
@@ -94,7 +94,7 @@
(/.synchronized sample #1))
(_.test "Can access Class instances."
- (text/= "java.lang.Class" (Class::getName (/.class-for java/lang/Class))))
+ (text;= "java.lang.Class" (Class::getName (/.class-for java/lang/Class))))
(_.test "Can check if a value is null."
(and (/.null? (/.null))
diff --git a/stdlib/source/test/lux/macro/code.lux b/stdlib/source/test/lux/macro/code.lux
index cc5997606..fa40f0fec 100644
--- a/stdlib/source/test/lux/macro/code.lux
+++ b/stdlib/source/test/lux/macro/code.lux
@@ -5,7 +5,7 @@
[monad (#+ do Monad)]]
[data
[number]
- ["." text ("#/." equivalence)
+ ["." text ("#;." equivalence)
format]]
[math
["r" random]]
@@ -17,7 +17,7 @@
(with-expansions
[<tests> (do-template [<expr> <text>]
[(test (format "Can produce Code node: " <text>)
- (and (text/= <text> (&.to-text <expr>))
+ (and (text;= <text> (&.to-text <expr>))
(:: &.equivalence = <expr> <expr>)))]
[(&.bit #1) "#1"]
diff --git a/stdlib/source/test/lux/macro/poly/equivalence.lux b/stdlib/source/test/lux/macro/poly/equivalence.lux
index a73d71112..63f9fa955 100644
--- a/stdlib/source/test/lux/macro/poly/equivalence.lux
+++ b/stdlib/source/test/lux/macro/poly/equivalence.lux
@@ -7,7 +7,7 @@
["." bit]
["." maybe]
[number
- ["." int ("#/." number)]]
+ ["." int ("#;." number)]]
["." text
format]
[collection
@@ -49,7 +49,7 @@
(r.Random Record)
(do r.monad
[size (:: @ map (n/% 2) r.nat)
- #let [gen-int (|> r.int (:: @ map (|>> int/abs (i/% +1,000,000))))]]
+ #let [gen-int (|> r.int (:: @ map (|>> int;abs (i/% +1,000,000))))]]
($_ r.and
r.bit
gen-int
@@ -67,6 +67,6 @@
(<| (times 100)
(do @
[sample gen-record
- #let [(^open "&/.") ..equivalence]]
+ #let [(^open "&;.") ..equivalence]]
(test "Every instance equals itself."
- (&/= sample sample)))))
+ (&;= sample sample)))))
diff --git a/stdlib/source/test/lux/math.lux b/stdlib/source/test/lux/math.lux
index 0ed9cab76..8b95691f6 100644
--- a/stdlib/source/test/lux/math.lux
+++ b/stdlib/source/test/lux/math.lux
@@ -3,9 +3,9 @@
[control
[monad (#+ Monad do)]]
[data
- ["." bit ("#/." equivalence)]
+ ["." bit ("#;." equivalence)]
[number
- ["." frac ("#/." number)]]]
+ ["." frac ("#;." number)]]]
["&" math
infix
["r" random]]]
@@ -14,7 +14,7 @@
(def: (within? margin-of-error standard value)
(-> Frac Frac Frac Bit)
(f/< margin-of-error
- (frac/abs (f/- standard value))))
+ (frac;abs (f/- standard value))))
(def: margin Frac +0.0000001)
@@ -58,7 +58,7 @@
(test "The round will be an integer value, and will be < or > or = the original."
(let [round'd (&.round sample)]
(and (|> round'd frac-to-int int-to-frac (f/= round'd))
- (f/<= +1.0 (frac/abs (f/- sample round'd))))))
+ (f/<= +1.0 (frac;abs (f/- sample round'd))))))
))))
(context: "Exponentials and logarithms"
@@ -115,12 +115,12 @@
(infix [(n/* 3 9) &.n/gcd 450])))
(test "Can use non-numerical functions/macros as operators."
- (bit/= (and (n/< y x) (n/< z y))
+ (bit;= (and (n/< y x) (n/< z y))
(infix [[x n/< y] and [y n/< z]])))
(test "Can combine bit operations in special ways via special keywords."
- (and (bit/= (and (n/< y x) (n/< z y))
+ (and (bit;= (and (n/< y x) (n/< z y))
(infix [#and x n/< y n/< z]))
- (bit/= (and (n/< y x) (n/> z y))
+ (bit;= (and (n/< y x) (n/> z y))
(infix [#and x n/< y n/> z]))))
))))
diff --git a/stdlib/source/test/lux/math/logic/fuzzy.lux b/stdlib/source/test/lux/math/logic/fuzzy.lux
index b64b3cb8c..aaacd32ef 100644
--- a/stdlib/source/test/lux/math/logic/fuzzy.lux
+++ b/stdlib/source/test/lux/math/logic/fuzzy.lux
@@ -3,7 +3,7 @@
[control
[monad (#+ do Monad)]]
[data
- ["." bit ("#/." equivalence)]
+ ["." bit ("#;." equivalence)]
["." number]
[text
format]
@@ -45,12 +45,12 @@
(r/= _.false (&.membership top triangle))))
(test "Values within range, will have membership > 0."
- (bit/= (r/> _.false (&.membership sample triangle))
+ (bit;= (r/> _.false (&.membership sample triangle))
(and (<gt> bottom sample)
(<lt> top sample))))
(test "Values outside of range, will have membership = 0."
- (bit/= (r/= _.false (&.membership sample triangle))
+ (bit;= (r/= _.false (&.membership sample triangle))
(or (<lte> bottom sample)
(<gte> top sample))))
))))]
@@ -87,17 +87,17 @@
(r/= _.false (&.membership top trapezoid))))
(test "Values within inner range will have membership = 1"
- (bit/= (r/= _.true (&.membership sample trapezoid))
+ (bit;= (r/= _.true (&.membership sample trapezoid))
(and (<gte> middle-bottom sample)
(<lte> middle-top sample))))
(test "Values within range, will have membership > 0."
- (bit/= (r/> _.false (&.membership sample trapezoid))
+ (bit;= (r/> _.false (&.membership sample trapezoid))
(and (<gt> bottom sample)
(<lt> top sample))))
(test "Values outside of range, will have membership = 0."
- (bit/= (r/= _.false (&.membership sample trapezoid))
+ (bit;= (r/= _.false (&.membership sample trapezoid))
(or (<lte> bottom sample)
(<gte> top sample))))
))))]
@@ -141,7 +141,7 @@
(_.not (&.membership sample (&.complement left)))))
(test "Membership in the difference will never be higher than in the set being subtracted."
- (bit/= (r/> (&.membership sample right)
+ (bit;= (r/> (&.membership sample right)
(&.membership sample left))
(r/< (&.membership sample left)
(&.membership sample (&.difference left right)))))
@@ -155,12 +155,12 @@
($_ seq
(test (format "Values that satisfy a predicate have membership = 1."
"Values that don't have membership = 0.")
- (bit/= (r/= _.true (&.membership sample (&.from-predicate n/even?)))
+ (bit;= (r/= _.true (&.membership sample (&.from-predicate n/even?)))
(n/even? sample)))
(test (format "Values that belong to a set have membership = 1."
"Values that don't have membership = 0.")
- (bit/= (r/= _.true (&.membership sample (&.from-set set-10)))
+ (bit;= (r/= _.true (&.membership sample (&.from-set set-10)))
(set.member? set-10 sample)))
))))
@@ -174,10 +174,10 @@
member? (&.to-predicate threshold fuzzy)]]
($_ seq
(test "Can increase the threshold of membership of a fuzzy set."
- (bit/= (r/> _.false (&.membership sample vip-fuzzy))
+ (bit;= (r/> _.false (&.membership sample vip-fuzzy))
(r/> threshold (&.membership sample fuzzy))))
(test "Can turn fuzzy sets into predicates through a threshold."
- (bit/= (member? sample)
+ (bit;= (member? sample)
(r/> threshold (&.membership sample fuzzy))))
))))
diff --git a/stdlib/source/test/lux/math/modular.lux b/stdlib/source/test/lux/math/modular.lux
index 462fad44a..4f9449d2a 100644
--- a/stdlib/source/test/lux/math/modular.lux
+++ b/stdlib/source/test/lux/math/modular.lux
@@ -4,14 +4,14 @@
[monad (#+ do)]]
[data
["." product]
- ["." bit ("#/." equivalence)]
+ ["." bit ("#;." equivalence)]
["." error]
[text
format]]
[math
["r" random]
["/" modular]]
- ["." type ("#/." equivalence)]]
+ ["." type ("#;." equivalence)]]
lux/test)
(def: %3 (/.modulus +3))
@@ -43,7 +43,7 @@
(-> Int Int Bit)
(-> (/.Mod m) (/.Mod m) Bit)))
(function (_ param subject)
- (bit/= (m/? param subject)
+ (bit;= (m/? param subject)
(i/? (value param)
(value subject)))))
@@ -71,11 +71,11 @@
#let [copyM (|> normalM /.to-int /.from-int error.assume)]]
($_ seq
(test "Every modulus has a unique type, even if the numeric value is the same as another."
- (and (type/= (:of normalM)
+ (and (type;= (:of normalM)
(:of normalM))
- (not (type/= (:of normalM)
+ (not (type;= (:of normalM)
(:of alternativeM)))
- (not (type/= (:of normalM)
+ (not (type;= (:of normalM)
(:of copyM)))))
(test "Can extract the original integer from the modulus."
@@ -91,11 +91,11 @@
((comparison /.m/>= i/>=) param subject)))
(test "Mod'ed values are ordered."
- (and (bit/= (/.m/< param subject)
+ (and (bit;= (/.m/< param subject)
(not (/.m/>= param subject)))
- (bit/= (/.m/> param subject)
+ (bit;= (/.m/> param subject)
(not (/.m/<= param subject)))
- (bit/= (/.m/= param subject)
+ (bit;= (/.m/= param subject)
(not (or (/.m/< param subject)
(/.m/> param subject))))))
@@ -145,6 +145,6 @@
(/.congruent? normalM _subject _subject))
(test "If 2 numbers are congruent under a modulus, then they must also be equal under the same modulus."
- (bit/= (/.congruent? normalM _param _subject)
+ (bit;= (/.congruent? normalM _param _subject)
(/.m/= param subject)))
))))
diff --git a/stdlib/source/test/lux/time/date.lux b/stdlib/source/test/lux/time/date.lux
index 2aee2dcb0..f9a90cb48 100644
--- a/stdlib/source/test/lux/time/date.lux
+++ b/stdlib/source/test/lux/time/date.lux
@@ -6,7 +6,7 @@
[data
["." error]]
[math
- ["r" random ("#/." monad)]]
+ ["r" random ("#;." monad)]]
[time
["@." instant]
["@" date]]]
@@ -16,18 +16,18 @@
(def: month
(r.Random @.Month)
- (r.either (r.either (r.either (r/wrap #@.January)
- (r.either (r/wrap #@.February)
- (r/wrap #@.March)))
- (r.either (r/wrap #@.April)
- (r.either (r/wrap #@.May)
- (r/wrap #@.June))))
- (r.either (r.either (r/wrap #@.July)
- (r.either (r/wrap #@.August)
- (r/wrap #@.September)))
- (r.either (r/wrap #@.October)
- (r.either (r/wrap #@.November)
- (r/wrap #@.December))))))
+ (r.either (r.either (r.either (r;wrap #@.January)
+ (r.either (r;wrap #@.February)
+ (r;wrap #@.March)))
+ (r.either (r;wrap #@.April)
+ (r.either (r;wrap #@.May)
+ (r;wrap #@.June))))
+ (r.either (r.either (r;wrap #@.July)
+ (r.either (r;wrap #@.August)
+ (r;wrap #@.September)))
+ (r.either (r;wrap #@.October)
+ (r.either (r;wrap #@.November)
+ (r;wrap #@.December))))))
(context: "(Month) Equivalence."
(<| (times 100)
@@ -64,13 +64,13 @@
(def: day
(r.Random @.Day)
- (r.either (r.either (r.either (r/wrap #@.Sunday)
- (r/wrap #@.Monday))
- (r.either (r/wrap #@.Tuesday)
- (r/wrap #@.Wednesday)))
- (r.either (r.either (r/wrap #@.Thursday)
- (r/wrap #@.Friday))
- (r/wrap #@.Saturday))))
+ (r.either (r.either (r.either (r;wrap #@.Sunday)
+ (r;wrap #@.Monday))
+ (r.either (r;wrap #@.Tuesday)
+ (r;wrap #@.Wednesday)))
+ (r.either (r.either (r;wrap #@.Thursday)
+ (r;wrap #@.Friday))
+ (r;wrap #@.Saturday))))
(context: "(Day) Equivalence."
(<| (times 100)
diff --git a/stdlib/source/test/lux/type.lux b/stdlib/source/test/lux/type.lux
index b9a6f09e4..7f5d76730 100644
--- a/stdlib/source/test/lux/type.lux
+++ b/stdlib/source/test/lux/type.lux
@@ -27,13 +27,13 @@
(def: #export gen-type
(r.Random Type)
- (let [(^open "R/.") r.monad]
+ (let [(^open "R;.") r.monad]
(r.rec (function (_ gen-type)
(let [pairG (r.and gen-type gen-type)
idG r.nat
- quantifiedG (r.and (R/wrap (list)) gen-type)]
+ quantifiedG (r.and (R;wrap (list)) gen-type)]
($_ r.or
- (r.and gen-short (R/wrap (list)))
+ (r.and gen-short (R;wrap (list)))
pairG
pairG
pairG
@@ -97,15 +97,15 @@
#1)))
(list.repeat size)
(M.seq @))
- #let [(^open "&/.") &.equivalence
- (^open "L/.") (list.equivalence &.equivalence)]]
+ #let [(^open "&;.") &.equivalence
+ (^open "L;.") (list.equivalence &.equivalence)]]
(with-expansions
[<struct-tests> (do-template [<desc> <ctor> <dtor> <unit>]
[(test (format "Can build and tear-down " <desc> " types.")
(let [flat (|> members <ctor> <dtor>)]
- (or (L/= members flat)
- (and (L/= (list) members)
- (L/= (list <unit>) flat)))))]
+ (or (L;= members flat)
+ (and (L;= (list) members)
+ (L;= (list <unit>) flat)))))]
["variant" &.variant &.flatten-variant Nothing]
["tuple" &.tuple &.flatten-tuple Any]
@@ -127,13 +127,13 @@
_
#1))))
- #let [(^open "&/.") &.equivalence
- (^open "L/.") (list.equivalence &.equivalence)]]
+ #let [(^open "&;.") &.equivalence
+ (^open "L;.") (list.equivalence &.equivalence)]]
($_ seq
(test "Can build and tear-down function types."
(let [[inputs output] (|> (&.function members extra) &.flatten-function)]
- (and (L/= members inputs)
- (&/= extra output))))
+ (and (L;= members inputs)
+ (&;= extra output))))
(test "Can build and tear-down application types."
(let [[tfunc tparams] (|> extra (&.application members) &.flatten-application)]
@@ -152,13 +152,13 @@
_
#1))))
- #let [(^open "&/.") &.equivalence]]
+ #let [(^open "&;.") &.equivalence]]
(with-expansions
[<quant-tests> (do-template [<desc> <ctor> <dtor>]
[(test (format "Can build and tear-down " <desc> " types.")
(let [[flat-size flat-body] (|> extra (<ctor> size) <dtor>)]
(and (n/= size flat-size)
- (&/= extra flat-body))))]
+ (&;= extra flat-body))))]
["universally-quantified" &.univ-q &.flatten-univ-q]
["existentially-quantified" &.ex-q &.flatten-ex-q]
@@ -172,7 +172,7 @@
(_.test "Can extract types."
(let [example (: (Maybe Nat)
#.Nonae)]
- (type/= (type (List Nat))
+ (type;= (type (List Nat))
(:by-example [a]
{(Maybe a) example}
(List a))))))
diff --git a/stdlib/source/test/lux/type/check.lux b/stdlib/source/test/lux/type/check.lux
index bd0b14167..45f1ce821 100644
--- a/stdlib/source/test/lux/type/check.lux
+++ b/stdlib/source/test/lux/type/check.lux
@@ -7,13 +7,13 @@
["." product]
["." maybe]
["." number]
- ["." text ("#/." equivalence)]
+ ["." text ("#;." equivalence)]
[collection
- ["." list ("#/." functor)]
+ ["." list ("#;." functor)]
["." set]]]
[math
["r" random]]
- ["." type ("#/." equivalence)
+ ["." type ("#;." equivalence)
["@" check]]]
lux/test
["." //])
@@ -112,7 +112,7 @@
(<| (times 100)
(do @
[nameL //.gen-short
- nameR (|> //.gen-short (r.filter (|>> (text/= nameL) not)))
+ nameR (|> //.gen-short (r.filter (|>> (text;= nameL) not)))
paramL //.gen-type
paramR (|> //.gen-type (r.filter (|>> (@.checks? paramL) not)))]
($_ seq
@@ -186,7 +186,7 @@
(test "Can create rings of variables."
(type-checks? (do @.monad
[[[head-id head-type] ids+types [tail-id tail-type]] (build-ring num-connections)
- #let [ids (list/map product.left ids+types)]
+ #let [ids (list;map product.left ids+types)]
headR (@.ring head-id)
tailR (@.ring tail-id)]
(@.assert ""
@@ -201,7 +201,7 @@
(test "When a var in a ring is bound, all the ring is bound."
(type-checks? (do @.monad
[[[head-id headT] ids+types tailT] (build-ring num-connections)
- #let [ids (list/map product.left ids+types)]
+ #let [ids (list;map product.left ids+types)]
_ (@.check headT boundT)
head-bound (@.read head-id)
tail-bound (monad.map @ @.read ids)
@@ -209,8 +209,8 @@
tailR+ (monad.map @ @.ring ids)]
(let [rings-were-erased? (and (set.empty? headR)
(list.every? set.empty? tailR+))
- same-types? (list.every? (type/= boundT) (list& (maybe.default headT head-bound)
- (list/map (function (_ [tail-id ?tailT])
+ same-types? (list.every? (type;= boundT) (list& (maybe.default headT head-bound)
+ (list;map (function (_ [tail-id ?tailT])
(maybe.default (#.Var tail-id) ?tailT))
(list.zip2 ids tail-bound))))]
(@.assert ""
diff --git a/stdlib/source/test/lux/type/implicit.lux b/stdlib/source/test/lux/type/implicit.lux
index 49c52aa48..dffd9496c 100644
--- a/stdlib/source/test/lux/type/implicit.lux
+++ b/stdlib/source/test/lux/type/implicit.lux
@@ -6,7 +6,7 @@
[functor]
[monad (#+ Monad do)]]
[data
- ["." bit ("#/." equivalence)]
+ ["." bit ("#;." equivalence)]
[number]
[collection [list]]]
[math
@@ -21,10 +21,10 @@
y r.nat]
($_ seq
(test "Can automatically select first-order structures."
- (let [(^open "list/.") (list.equivalence number.equivalence)]
- (and (bit/= (:: number.equivalence = x y)
+ (let [(^open "list;.") (list.equivalence number.equivalence)]
+ (and (bit;= (:: number.equivalence = x y)
(::: = x y))
- (list/= (list.n/range 1 10)
+ (list;= (list.n/range 1 10)
(::: map inc (list.n/range 0 9)))
)))
diff --git a/stdlib/source/test/lux/world/file.lux b/stdlib/source/test/lux/world/file.lux
index 80d4a524b..deed8dbd2 100644
--- a/stdlib/source/test/lux/world/file.lux
+++ b/stdlib/source/test/lux/world/file.lux
@@ -19,7 +19,7 @@
["@" file (#+ Path File)]
["." binary (#+ Binary)]]
[math
- ["r" random ("#/." monad)]]]
+ ["r" random ("#;." monad)]]]
lux/test
[//
["_." binary]])
@@ -30,7 +30,7 @@
(def: (creation-and-deletion number)
(-> Nat Test)
- (r/wrap (do promise.monad
+ (r;wrap (do promise.monad
[#let [path (format "temp_file_" (%n number))]
result (promise.future
(do (error.ErrorT io.monad)
@@ -49,7 +49,7 @@
(def: (read-and-write number data)
(-> Nat Binary Test)
- (r/wrap (do promise.monad
+ (r;wrap (do promise.monad
[#let [path (format "temp_file_" (%n number))]
result (promise.future
(do (error.ErrorT io.monad)
diff --git a/stdlib/source/test/lux/world/net/tcp.lux b/stdlib/source/test/lux/world/net/tcp.lux
index 78be41610..43a304a58 100644
--- a/stdlib/source/test/lux/world/net/tcp.lux
+++ b/stdlib/source/test/lux/world/net/tcp.lux
@@ -8,7 +8,7 @@
["." taint]]]
[concurrency
["." promise (#+ Promise promise)]
- ["." frp ("#/." functor)]]
+ ["." frp ("#;." functor)]]
[data
["." error]
["." text
@@ -45,7 +45,7 @@
result (promise.future
(do io.monad
[[server-close server] (@.server port)
- #let [_ (frp/map (function (_ client)
+ #let [_ (frp;map (function (_ client)
(promise.future
(do @
[[trasmission-size transmission] (:: client read size)