aboutsummaryrefslogtreecommitdiff
path: root/stdlib/source/lux/concurrency/stm.lux
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--stdlib/source/lux/concurrency/stm.lux14
1 files changed, 7 insertions, 7 deletions
diff --git a/stdlib/source/lux/concurrency/stm.lux b/stdlib/source/lux/concurrency/stm.lux
index 80633a41e..cf9624409 100644
--- a/stdlib/source/lux/concurrency/stm.lux
+++ b/stdlib/source/lux/concurrency/stm.lux
@@ -52,7 +52,7 @@
(def: (find-var-value var tx)
(All [a] (-> (Var a) Tx (Maybe a)))
- (:! (Maybe ($ 0))
+ (:! (Maybe ($ +0))
(find (: (-> (Ex [a] (Tx-Frame a))
(Maybe Unit))
(lambda [[_var _original _current]]
@@ -89,11 +89,11 @@
#;Nil
(#;Cons [_var _original _current] tx')
- (if (== (:! (Var ($ 0)) var)
- (:! (Var ($ 0)) _var))
- (#;Cons [(:! (Var ($ 0)) _var)
- (:! ($ 0) _original)
- (:! ($ 0) _current)]
+ (if (== (:! (Var ($ +0)) var)
+ (:! (Var ($ +0)) _var))
+ (#;Cons [(:! (Var ($ +0)) _var)
+ (:! ($ +0) _original)
+ (:! ($ +0) _current)]
tx')
(#;Cons [_var _original _current]
(update-tx-value var value tx')))
@@ -138,7 +138,7 @@
(def: #export (follow label target)
{#;doc "Creates a channel (identified by a given text) that will receive all changes to the value of the given var."}
(All [a] (-> Text (Var a) (IO (frp;Chan a))))
- (let [head (frp;chan ($ 0))
+ (let [head (frp;chan ($ +0))
chan-var (var head)
observer (lambda [value]
(case (io;run (|> chan-var raw-read (frp;write value)))