[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Lambdas
- From: Tim Hill <drtimhill@...>
- Date: Sun, 18 Nov 2018 16:17:42 -0800
> On Nov 18, 2018, at 3:45 PM, Muh Muhten <firstname.lastname@example.org> wrote:
> On 11/18/18, Philippe Verdy <email@example.com> wrote:
>> As well the given examples are not pure lambda:
>> or its transformation into
>> function(x,y,z) return x+(x-2)*g(x,y,z-2*(x+y))-y*z end
>> is bound in a closure referencing "g", which is not an upvalue (an input
>> parameter) of that function.
> This is the first I've heard of a notion of a "pure" lambda which
> forbids closures.
> It would seem to be a rather *unusual* idea, since the name "lambda"
> itself refers to lambda calculus, which is not nearly as interesting
> without closed-over variables.
+1 .. it seems to me that this isn’t lambda at all … its just a discussion of pure functions. To the best of my knowledge (others jump in here!) the only difference between a Lua (anonymous) function and a lambda is syntax. That is, any “lambda” extension to Lua would just be syntactic sugar.