aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/specification/compositor/generation/common.lux
diff options
context:
space:
mode:
authorEduardo Julian2021-07-25 03:12:17 -0400
committerEduardo Julian2021-07-25 03:12:17 -0400
commit62b3abfcc014ca1c19d62aacdd497f6a250b372c (patch)
treec23155ecef6018b78b349f0ba6cd238872b24da7 /stdlib/source/specification/compositor/generation/common.lux
parent0f545b7e57d2564e351d907befd2ce26900c5521 (diff)
Better syntax for "library/lux.^multi".
Diffstat (limited to 'stdlib/source/specification/compositor/generation/common.lux')
-rw-r--r--stdlib/source/specification/compositor/generation/common.lux18
1 files changed, 9 insertions, 9 deletions
diff --git a/stdlib/source/specification/compositor/generation/common.lux b/stdlib/source/specification/compositor/generation/common.lux
index 3d377b7ca..e14aa8e52 100644
--- a/stdlib/source/specification/compositor/generation/common.lux
+++ b/stdlib/source/specification/compositor/generation/common.lux
@@ -75,7 +75,7 @@
(def: (i64 run)
(-> Runner Test)
(do r.monad
- [param (|> r.i64 (r.filter (|>> ("lux i64 =" 0) not)))
+ [param (|> r.i64 (r.only (|>> ("lux i64 =" 0) not)))
subject r.i64]
(`` ($_ _.and
(~~ (template [<extension> <type> <prepare> <comp> <subject-expr>]
@@ -123,7 +123,7 @@
(def: (f64 run)
(-> Runner Test)
(do r.monad
- [param (|> ..simple-frac (r.filter (|>> (f.= +0.0) not)))
+ [param (|> ..simple-frac (r.only (|>> (f.= +0.0) not)))
subject ..simple-frac]
(`` ($_ _.and
(~~ (template [<extension> <reference> <comp>]
@@ -179,7 +179,7 @@
sample-lower (r.ascii/lower-alpha sample-size)
sample-upper (r.ascii/upper-alpha sample-size)
sample-alpha (|> (r.ascii/alpha sample-size)
- (r.filter (|>> (text\= sample-upper) not)))
+ (r.only (|>> (text\= sample-upper) not)))
char-idx (|> r.nat (\ ! map (n.% sample-size)))
#let [sample-lowerS (synthesis.text sample-lower)
sample-upperS (synthesis.text sample-upper)
@@ -235,7 +235,7 @@
(synthesis.i64 +0)))
(run (..sanitize "lux text index"))
(case> (^multi (#try.Success valueV)
- [(:as (Maybe Nat) valueV) (#.Some valueV)])
+ {(:as (Maybe Nat) valueV) (#.Some valueV)})
(n.= 0 valueV)
_
@@ -245,7 +245,7 @@
(synthesis.i64 +0)))
(run (..sanitize "lux text index"))
(case> (^multi (#try.Success valueV)
- [(:as (Maybe Nat) valueV) (#.Some valueV)])
+ {(:as (Maybe Nat) valueV) (#.Some valueV)})
(n.= sample-size valueV)
_
@@ -258,7 +258,7 @@
(synthesis.i64 length)))
(run (..sanitize "lux text clip"))
(case> (^multi (#try.Success valueV)
- [(:as (Maybe Text) valueV) (#.Some valueV)])
+ {(:as (Maybe Text) valueV) (#.Some valueV)})
(text\= expected valueV)
_
@@ -272,7 +272,7 @@
(synthesis.i64 char-idx)))
(run (..sanitize "lux text char"))
(case> (^multi (#try.Success valueV)
- [(:as (Maybe Int) valueV) (#.Some valueV)])
+ {(:as (Maybe Int) valueV) (#.Some valueV)})
(text.contains? ("lux i64 char" valueV)
sample-lower)
@@ -303,7 +303,7 @@
(list (synthesis.text message)))})))
(run (..sanitize "lux try"))
(case> (^multi (#try.Success valueV)
- [(:as (Try Text) valueV) (#try.Failure error)])
+ {(:as (Try Text) valueV) (#try.Failure error)})
(text.contains? message error)
_
@@ -315,7 +315,7 @@
#synthesis.body (synthesis.text message)})))
(run (..sanitize "lux try"))
(case> (^multi (#try.Success valueV)
- [(:as (Try Text) valueV) (#try.Success valueV)])
+ {(:as (Try Text) valueV) (#try.Success valueV)})
(text\= message valueV)
_