diff options
| author | Jan Tuomi <jans.tuomi@gmail.com> | 2022-12-06 15:40:52 +0200 |
|---|---|---|
| committer | Jan Tuomi <jans.tuomi@gmail.com> | 2022-12-06 15:40:52 +0200 |
| commit | e73ad00f44479e3065ccf12d07ca3ae22ca1f3f0 (patch) | |
| tree | 628c4957a9e53815d1ccf49f87a1002ccc059ac6 /examples/records-concept.milch | |
| parent | 21ee11d3df3000a77d5b36d3c7e0a18d9a07d599 (diff) | |
Remove ! from end of builtin top-level functions
Diffstat (limited to 'examples/records-concept.milch')
| -rw-r--r-- | examples/records-concept.milch | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/examples/records-concept.milch b/examples/records-concept.milch index 420fa9f..1686d75 100644 --- a/examples/records-concept.milch +++ b/examples/records-concept.milch @@ -1,16 +1,16 @@ -; Records are named tuples with an identifier. `record!` is a builtin function +; Records are named tuples with an identifier. `record` is a builtin function ; that generates functions for creating, reading and modifying a record. ; In type system terms, records are intersections. -; `record!` can only be called in the top-level context. +; `record` can only be called in the top-level context. -(record! Ns/User +(record Ns/User name phone-number) ; Generates the following functions: -(let! user +(let user (Ns/User/create "John" "010-123-456")) ; user ~> (Ns/User name:"John" phone-number:"010-123-456") @@ -36,8 +36,8 @@ ; Generates the following functions: -(let! m1 (Ns/Maybe/just 10)) ; m1 ~> (Ns/Maybe/Just value:10) -(let! m2 (Ns/Maybe/nothing)) ; m2 ~> (Ns/Maybe/Nothing) +(let m1 (Ns/Maybe/just 10)) ; m1 ~> (Ns/Maybe/Just value:10) +(let m2 (Ns/Maybe/nothing)) ; m2 ~> (Ns/Maybe/Nothing) (Ns/Maybe/Just/get-value m1) ; => 10 |
