unison/unison-src/transcripts/fix942.md

38 lines
474 B
Markdown
Raw Permalink Normal View History

```ucm:hide
scratch/main> builtins.merge
```
2019-11-08 00:24:54 +03:00
First we add some code:
```unison
x = 0
y = x + 1
z = y + 2
```
```ucm
scratch/main> add
2019-11-08 00:24:54 +03:00
```
Now we edit `x` to be `7`, which should make `z` equal `10`:
```unison
x = 7
```
```ucm
scratch/main> update
scratch/main> view x y z
2019-11-08 00:24:54 +03:00
```
Uh oh! `z` is still referencing the old version. Just to confirm:
```unison
test> t1 = if z == 3 then [Fail "nooo!!!"] else [Ok "great"]
```
```ucm
scratch/main> add
scratch/main> test
2019-11-08 00:24:54 +03:00
```