[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: ideas for lambda syntax
- From: Dirk Laurie <dirk.laurie@...>
- Date: Tue, 9 Apr 2013 12:33:08 +0200
2013/4/9 oliver <oliver.schoenborn@gmail.com>:
> There is not much that I really miss in Lua, but the lack of
> a short lambda syntax is one that keeps coming back time
> and again.
Lua's existing syntax _is_ lambda syntax, but for the sake of
portability the three symbols required are spelt out with keywords.
f = λ(a,b)↦a+b∎
f = \lambda(a,b) \to a+b \endlambda
f = function(a,b) return a+b end