unison/unison-src/transcripts/dont-upgrade-refs-that-exist-in-old.output.md
Greg Pfeil 0031542faf
Add a space before code block info strings
This is for consistency with the `cmark` style. Now the blocks we still
pretty-print ourselves will match the bulk of them that `cmark`
produces.
2024-07-10 13:56:07 -06:00

49 lines
983 B
Markdown

If `foo#old` exists in old, and `foo#new` exists in new, you might think `upgrade old new` would rewrite references to
`#old` with references to `#new`. And it will... \!\!unless\!\! `#old` still exists in new.
``` unison
lib.old.foo = 18
lib.new.other = 18
lib.new.foo = 19
mything = lib.old.foo + lib.old.foo
```
``` ucm
Loading changes detected in scratch.u.
I found and typechecked these definitions in scratch.u. If you
do an `add` or `update`, here's how your codebase would
change:
⍟ These new definitions are ok to `add`:
lib.new.foo : Nat
lib.new.other : Nat
lib.old.foo : Nat
mything : Nat
```
``` ucm
foo/main> add
⍟ I've added these definitions:
lib.new.foo : Nat
lib.new.other : Nat
lib.old.foo : Nat
mything : Nat
foo/main> upgrade old new
I upgraded old to new, and removed old.
foo/main> view mything
mything : Nat
mything =
use Nat +
other + other
```