aboutsummaryrefslogtreecommitdiff
path: root/licentia/source
diff options
context:
space:
mode:
authorEduardo Julian2021-09-05 22:52:26 -0400
committerEduardo Julian2021-09-05 22:52:26 -0400
commit132ffdae1add622c8a3c6065d7730a8fe8ea5e78 (patch)
tree540310f190007d192b892db2d0a520d17b73ad48 /licentia/source
parent09e2747bf8c6dcdc1d7318f2490f0de37d77b39f (diff)
Changed the syntax of do/be's (co)monad bindings.
Diffstat (limited to 'licentia/source')
-rw-r--r--licentia/source/program/licentia.lux2
-rw-r--r--licentia/source/test/licentia.lux4
2 files changed, 3 insertions, 3 deletions
diff --git a/licentia/source/program/licentia.lux b/licentia/source/program/licentia.lux
index a6e0820c3..1f5b9c05d 100644
--- a/licentia/source/program/licentia.lux
+++ b/licentia/source/program/licentia.lux
@@ -66,7 +66,7 @@
[?done (: (IO (Try Any))
(do (try.with io.monad)
[blob (\ file.default read input)
- document (io\wrap (do {! try.monad}
+ document (io\wrap (do [! try.monad]
[raw_json (\ utf8.codec decoded blob)
json (|> raw_json
java/lang/String::trim
diff --git a/licentia/source/test/licentia.lux b/licentia/source/test/licentia.lux
index e3204e598..8f967502a 100644
--- a/licentia/source/test/licentia.lux
+++ b/licentia/source/test/licentia.lux
@@ -46,7 +46,7 @@
(def: period
(Random (Period Nat))
- (do {! random.monad}
+ (do [! random.monad]
[start (random.filter (|>> (n.= n\top) not)
random.nat)
#let [wiggle_room (n.- start n\top)]
@@ -108,7 +108,7 @@
(def: (variable_list max_size gen_element)
(All (_ a) (-> Nat (Random a) (Random (List a))))
- (do {! random.monad}
+ (do [! random.monad]
[amount (\ ! each (n.% (n.max 1 max_size))
random.nat)]
(random.list amount gen_element)))