Play with base ref forms

This commit is contained in:
Scott Richmond 2022-05-18 18:31:11 -04:00
parent 9e25f24b3f
commit fb89508bef

View File

@ -370,16 +370,10 @@
(def source "
fn swap! (r, f) -> {
let val = deref (r)
let new = f (val)
set! (r, new)
}
ref foo = nil
ref bar = nil
ref foo = 0
swap! (foo, inc)
swap! (foo, inc)
eq (foo, bar)
")