[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: syntax sugar for functions
- From: eugeny gladkih <john@...>
- Date: Thu, 7 Oct 2021 12:55:47 +0300
hi,
what about funny syntax sugar for functions definition, lazy people are welcome to upvote
function( a ) return a + 2 end -> (a){{ a + 2 }}
function() do-something end -> (){{ do-something }}
{{ do-something }}
good for small functions passing as parameter. the idea is that list in {{ }} returns the last calculated expression (or the list)
--
Yours sincerely, Eugeny.
+33 6 38 52 27 93