2024-07-10 19:17:15 +03:00
|
|
|
``` ucm
|
2024-06-07 08:17:44 +03:00
|
|
|
test-ls/main> builtins.merge
|
|
|
|
|
|
|
|
Done.
|
|
|
|
|
|
|
|
```
|
2024-07-10 17:46:18 +03:00
|
|
|
``` unison
|
2024-06-07 08:17:44 +03:00
|
|
|
foo.bar.add x y = x Int.+ y
|
|
|
|
|
|
|
|
foo.bar.subtract x y = x Int.- y
|
|
|
|
```
|
|
|
|
|
2024-07-10 19:17:15 +03:00
|
|
|
``` ucm
|
2024-06-07 08:17:44 +03:00
|
|
|
|
|
|
|
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`:
|
|
|
|
|
|
|
|
foo.bar.add : Int -> Int -> Int
|
|
|
|
foo.bar.subtract : Int -> Int -> Int
|
|
|
|
|
|
|
|
```
|
2024-07-10 19:17:15 +03:00
|
|
|
``` ucm
|
2024-06-07 08:17:44 +03:00
|
|
|
test-ls/main> add
|
|
|
|
|
|
|
|
⍟ I've added these definitions:
|
|
|
|
|
|
|
|
foo.bar.add : Int -> Int -> Int
|
|
|
|
foo.bar.subtract : Int -> Int -> Int
|
|
|
|
|
|
|
|
test-ls/main> ls foo
|
|
|
|
|
|
|
|
1. bar/ (2 terms)
|
|
|
|
|
|
|
|
test-ls/main> ls 1
|
|
|
|
|
2024-06-07 08:40:16 +03:00
|
|
|
1. add (Int -> Int -> Int)
|
|
|
|
2. subtract (Int -> Int -> Int)
|
2024-06-07 08:17:44 +03:00
|
|
|
|
2024-06-07 08:40:16 +03:00
|
|
|
```
|