aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/specification
diff options
context:
space:
mode:
authorEduardo Julian2021-08-07 02:20:09 -0400
committerEduardo Julian2021-08-07 02:20:09 -0400
commit17e7566be51df5e428a6b10e6469201a8a9468da (patch)
tree0d4ed80c9c9d846784b5bf460f6e6f5fc5b96663 /stdlib/source/specification
parenteff4c59794868b89d60fdc411f9b544a270b817e (diff)
Made the be/de macros for (co)monadic expression extensible.
Diffstat (limited to '')
-rw-r--r--stdlib/source/specification/aedifex/repository.lux4
-rw-r--r--stdlib/source/specification/compositor.lux2
-rw-r--r--stdlib/source/specification/compositor/common.lux2
-rw-r--r--stdlib/source/specification/compositor/generation/case.lux4
-rw-r--r--stdlib/source/specification/compositor/generation/common.lux2
-rw-r--r--stdlib/source/specification/compositor/generation/function.lux2
-rw-r--r--stdlib/source/specification/compositor/generation/structure.lux4
-rw-r--r--stdlib/source/specification/lux/abstract/comonad.lux6
-rw-r--r--stdlib/source/specification/lux/world/console.lux2
-rw-r--r--stdlib/source/specification/lux/world/file.lux6
10 files changed, 17 insertions, 17 deletions
diff --git a/stdlib/source/specification/aedifex/repository.lux b/stdlib/source/specification/aedifex/repository.lux
index 1b16d774d..059a467e4 100644
--- a/stdlib/source/specification/aedifex/repository.lux
+++ b/stdlib/source/specification/aedifex/repository.lux
@@ -29,11 +29,11 @@
[expected (_binary.random 100)]
(in ($_ _.and'
(do async.monad
- [#let [good_uri (/remote.uri (get@ #//artifact.version valid_artifact) valid_artifact //artifact/extension.lux_library)]
+ [.let [good_uri (/remote.uri (get@ #//artifact.version valid_artifact) valid_artifact //artifact/extension.lux_library)]
good_upload! (\ subject upload good_uri expected)
good_download! (\ subject download good_uri)
- #let [bad_uri (/remote.uri (get@ #//artifact.version invalid_artifact) invalid_artifact //artifact/extension.lux_library)]
+ .let [bad_uri (/remote.uri (get@ #//artifact.version invalid_artifact) invalid_artifact //artifact/extension.lux_library)]
bad_upload! (\ subject upload bad_uri expected)
bad_download! (\ subject download bad_uri)]
(_.cover' [/.Repository]
diff --git a/stdlib/source/specification/compositor.lux b/stdlib/source/specification/compositor.lux
index 5645b0164..8cc92ff33 100644
--- a/stdlib/source/specification/compositor.lux
+++ b/stdlib/source/specification/compositor.lux
@@ -50,7 +50,7 @@
Test))
(do r.monad
[_ (in [])
- #let [?state,runner,definer (<| io.run
+ .let [?state,runner,definer (<| io.run
(do io.monad
[platform platform])
(/common.executors platform
diff --git a/stdlib/source/specification/compositor/common.lux b/stdlib/source/specification/compositor/common.lux
index 0b7c7979a..fdd930ec8 100644
--- a/stdlib/source/specification/compositor/common.lux
+++ b/stdlib/source/specification/compositor/common.lux
@@ -73,7 +73,7 @@
[?state (platform.initialize target expander analysis_bundle platform generation_bundle directive_bundle program extender)]
(in (do try.monad
[[directive_bundle directive_state] ?state
- #let [generation_state (get@ [#directive.generation
+ .let [generation_state (get@ [#directive.generation
#directive.state]
directive_state)]]
(in [[directive_bundle directive_state]
diff --git a/stdlib/source/specification/compositor/generation/case.lux b/stdlib/source/specification/compositor/generation/case.lux
index 117aab697..0ef6fc025 100644
--- a/stdlib/source/specification/compositor/generation/case.lux
+++ b/stdlib/source/specification/compositor/generation/case.lux
@@ -68,7 +68,7 @@
[size ..size
idx (|> r.nat (\ ! map (n.% size)))
[subS subP] case
- #let [unitS (synthesis.text synthesis.unit)
+ .let [unitS (synthesis.text synthesis.unit)
caseS (synthesis.tuple
(list.concat (list (list.repeat idx unitS)
(list subS)
@@ -83,7 +83,7 @@
[size ..size
idx (|> r.nat (\ ! map (n.% size)))
[subS subP] case
- #let [right? (tail? size idx)
+ .let [right? (tail? size idx)
caseS (synthesis.variant
{#analysis.lefts idx
#analysis.right? right?
diff --git a/stdlib/source/specification/compositor/generation/common.lux b/stdlib/source/specification/compositor/generation/common.lux
index c13cd9eae..e17692b30 100644
--- a/stdlib/source/specification/compositor/generation/common.lux
+++ b/stdlib/source/specification/compositor/generation/common.lux
@@ -181,7 +181,7 @@
sample_alpha (|> (r.ascii/alpha sample_size)
(r.only (|>> (text\= sample_upper) not)))
char_idx (|> r.nat (\ ! map (n.% sample_size)))
- #let [sample_lowerS (synthesis.text sample_lower)
+ .let [sample_lowerS (synthesis.text sample_lower)
sample_upperS (synthesis.text sample_upper)
sample_alphaS (synthesis.text sample_alpha)
concatenatedS (#synthesis.Extension "lux text concat" (list sample_lowerS sample_upperS))
diff --git a/stdlib/source/specification/compositor/generation/function.lux b/stdlib/source/specification/compositor/generation/function.lux
index 5be34bfa5..3589cdf28 100644
--- a/stdlib/source/specification/compositor/generation/function.lux
+++ b/stdlib/source/specification/compositor/generation/function.lux
@@ -53,7 +53,7 @@
[[arity local functionS] ..function
partial_arity (|> r.nat (\ ! map (|>> (n.% arity) (n.max 1))))
inputs (r.list arity r.safe_frac)
- #let [expectation (maybe.assume (list.item (dec local) inputs))
+ .let [expectation (maybe.assume (list.item (dec local) inputs))
inputsS (list\map (|>> synthesis.f64) inputs)]]
($_ _.and
(_.test "Can read arguments."
diff --git a/stdlib/source/specification/compositor/generation/structure.lux b/stdlib/source/specification/compositor/generation/structure.lux
index 4cc4f0676..46c25c8a3 100644
--- a/stdlib/source/specification/compositor/generation/structure.lux
+++ b/stdlib/source/specification/compositor/generation/structure.lux
@@ -33,7 +33,7 @@
(do {! r.monad}
[num_tags (|> r.nat (\ ! map (|>> (n.% 10) (n.max 2))))
tag_in (|> r.nat (\ ! map (n.% num_tags)))
- #let [last?_in (|> num_tags dec (n.= tag_in))]
+ .let [last?_in (|> num_tags dec (n.= tag_in))]
value_in r.i64]
(_.test (%.name (name_of synthesis.variant))
(|> (synthesis.variant {#analysis.lefts (if last?_in
@@ -76,7 +76,7 @@
(and (n.= size (array.size tuple_out))
(list.every? (function (_ [left right])
(i.= left (:as Int right)))
- (list.zipped/2 tuple_in (array.to_list tuple_out)))))
+ (list.zipped/2 tuple_in (array.list tuple_out)))))
(#try.Failure _)
false)))))
diff --git a/stdlib/source/specification/lux/abstract/comonad.lux b/stdlib/source/specification/lux/abstract/comonad.lux
index 8b45adb88..0f5f18965 100644
--- a/stdlib/source/specification/lux/abstract/comonad.lux
+++ b/stdlib/source/specification/lux/abstract/comonad.lux
@@ -20,7 +20,7 @@
morphism (\ ! map (function (_ diff)
(|>> _//out (n.+ diff)))
random.nat)
- #let [start (injection sample)]]
+ .let [start (injection sample)]]
(_.test "Left identity."
(n.= (morphism start)
(|> start _//split (_//map morphism) _//out)))))
@@ -29,7 +29,7 @@
(All [f] (-> (Injection f) (Comparison f) (CoMonad f) Test))
(do random.monad
[sample random.nat
- #let [start (injection sample)
+ .let [start (injection sample)
== (comparison n.=)]]
(_.test "Right identity."
(== start
@@ -45,7 +45,7 @@
decrease (\ ! map (function (_ diff)
(|>> _//out(n.- diff)))
random.nat)
- #let [start (injection sample)
+ .let [start (injection sample)
== (comparison n.=)]]
(_.test "Associativity."
(== (|> start _//split (_//map (|>> _//split (_//map increase) decrease)))
diff --git a/stdlib/source/specification/lux/world/console.lux b/stdlib/source/specification/lux/world/console.lux
index 5632e5cd8..154f8faca 100644
--- a/stdlib/source/specification/lux/world/console.lux
+++ b/stdlib/source/specification/lux/world/console.lux
@@ -29,7 +29,7 @@
?close/good (\ console close [])
?close/bad (\ console close [])
- #let [can_write!
+ .let [can_write!
(case ?write
(#try.Success _)
true
diff --git a/stdlib/source/specification/lux/world/file.lux b/stdlib/source/specification/lux/world/file.lux
index 147593f14..83bfc2465 100644
--- a/stdlib/source/specification/lux/world/file.lux
+++ b/stdlib/source/specification/lux/world/file.lux
@@ -126,7 +126,7 @@
[made_sub? (\ fs make_directory sub_dir)
directory_files (\ fs directory_files parent)
sub_directories (\ fs sub_directories parent)
- #let [(^open "list\.") (list.equivalence text.equivalence)]]
+ .let [(^open "list\.") (list.equivalence text.equivalence)]]
(in (<| (try.else false)
(do try.monad
[_ made_sub?]
@@ -173,7 +173,7 @@
in
(do {! async.monad}
[fs (async.future fs)
- #let [path (/.rooted fs parent child)]
+ .let [path (/.rooted fs parent child)]
directory?&make_directory
(..directory?&make_directory fs parent)
@@ -215,7 +215,7 @@
in
(do {! async.monad}
[fs (async.future fs)
- #let [dir/1 (/.rooted fs dir/0 dir/1)
+ .let [dir/1 (/.rooted fs dir/0 dir/1)
dir/2 (/.rooted fs dir/1 dir/2)]
pre_dir/0 (\ fs directory? dir/0)
pre_dir/1 (\ fs directory? dir/1)