aboutsummaryrefslogtreecommitdiff
path: root/stdlib/test
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--stdlib/test/test/lux/concurrency/session.lux30
1 files changed, 15 insertions, 15 deletions
diff --git a/stdlib/test/test/lux/concurrency/session.lux b/stdlib/test/test/lux/concurrency/session.lux
index 192421f02..ed538372c 100644
--- a/stdlib/test/test/lux/concurrency/session.lux
+++ b/stdlib/test/test/lux/concurrency/session.lux
@@ -18,12 +18,12 @@
(def: $transfer (<| << (!! Int) >>))
(def: transfer
- (Lazy (:~ $transfer))
- (<| $.send $.end))
+ (IO (:~ $transfer))
+ (io.io (lazy.thaw (<| $.send $.end))))
(context: "Transfer."
(do @
- [#let [[$me $you] (lazy.thaw ..transfer)]
+ [#let [[$me $you] (io.run ..transfer)]
expectation r.int]
($_ seq
(wrap (do promise.Monad<Promise>
@@ -41,13 +41,13 @@
(<| (!! Int) $recur)))))
(def: endless
- (Lazy (:~ $endless))
- ($.rec (function (_ recur)
- (<| $.send recur))))
+ (IO (:~ $endless))
+ (io.io (lazy.thaw ($.rec (function (_ recur)
+ (<| $.send recur))))))
(context: "Endless."
(do @
- [#let [[$me $you] (lazy.thaw ..endless)]
+ [#let [[$me $you] (io.run ..endless)]
expectation0 r.int
expectation1 r.int
expectation2 r.int]
@@ -78,19 +78,19 @@
>>))))
(def: calculation
- (Lazy (:~ (<< $calculation)))
- ($.rec
- (function (_ recur)
- ($_ $.fork
- (<| $.send $.send $.receive recur)
- (<| $.send $.receive recur)
- $.end))))
+ (IO (:~ (<< $calculation)))
+ (io.io (lazy.thaw ($.rec
+ (function (_ recur)
+ ($_ $.fork
+ (<| $.send $.send $.receive recur)
+ (<| $.send $.receive recur)
+ $.end))))))
(def: negate (i/* -1))
(context: "Complex session."
(do @
- [#let [[$me $you] (lazy.thaw calculation)]
+ [#let [[$me $you] (io.run calculation)]
param r.int
subject r.int
#let [expectation (i/+ param subject)]]