diff options
author | Eduardo Julian | 2022-06-16 00:48:19 -0400 |
---|---|---|
committer | Eduardo Julian | 2022-06-16 00:48:19 -0400 |
commit | 9e2f1e76f2c8df01ed7687d934c3210fcf676bd6 (patch) | |
tree | 115fab5bd8a5f53dc0d13ce5453095324a83496f /documentation/book/the_lux_programming_language/appendix_c.md | |
parent | f92c806ee8da63f04bbefbf558f6249bacdb47ea (diff) |
De-sigil-ification: suffix : [Part 13]
Diffstat (limited to 'documentation/book/the_lux_programming_language/appendix_c.md')
-rw-r--r-- | documentation/book/the_lux_programming_language/appendix_c.md | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/documentation/book/the_lux_programming_language/appendix_c.md b/documentation/book/the_lux_programming_language/appendix_c.md index 38580fee8..a2c0953cb 100644 --- a/documentation/book/the_lux_programming_language/appendix_c.md +++ b/documentation/book/the_lux_programming_language/appendix_c.md @@ -62,7 +62,7 @@ The possibilities are endless when it comes to the refinement you can do, and wh ```clojure ... Allows you to simultaneously bind and de-structure a value. -(def: (hash (^@ set [element_hash _])) +(def (hash (^@ set [element_hash _])) (list#mix (function (_ elem acc) (n.+ (# element_hash hash elem) acc)) 0 @@ -74,7 +74,7 @@ The possibilities are endless when it comes to the refinement you can do, and wh ```clojure ... Same as the "open" macro, but meant to be used as a pattern-matching macro for generating local bindings. ... Can optionally take an aliasing text for the generated local bindings. -(def: .public (range (^open "[0]") from to) +(def .public (range (^open "[0]") from to) (All (_ a) (-> (Enum a) a a (List a))) (range' <= succ from to)) ``` @@ -95,7 +95,7 @@ It's excellent when taking structures as function arguments, or when opening str {#Friday} {#Saturday})) -(def: (weekend? day) +(def (weekend? day) (-> Day Bit) (case day (^or {#Saturday} {#Sunday}) @@ -111,7 +111,7 @@ It's a real time-saver. ```clojure ... It's similar to do-template, but meant to be used during pattern-matching. -(def: (beta_reduce env type) +(def (beta_reduce env type) (-> (List Type) Type Type) (case type {.#Primitive name params} |