[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Lambda (was Re: special forms, take two (was Re: A lua version of "amb"))
- From: Mark Hamburg <mark@...>
- Date: Fri, 2 Mar 2012 07:50:21 -0800
On Mar 2, 2012, at 2:43 AM, Luiz Henrique de Figueiredo wrote:
>> Given Lua's indulgence to all those Fortran programmers out
>> there, what about good old "arithmetic statement functions" for
>> a lightweight syntax? In this case:
>>
>> foo(x) = x.foo
>
> I've toyed with
> function f(x,y,z) = expression
>
> which saves "return" and "end" but keeps "function" (and can be used with
> "local as well).
Unfortunately, that would have precedence issues around commas, but otherwise I can imagine cases where it would help.
Mark
- References:
- Re: special forms, take two (was Re: A lua version of "amb"), Mark Hamburg
- Lambda (was Re: special forms, take two (was Re: A lua version of "amb")), Mark Hamburg
- Re: Lambda (was Re: special forms, take two (was Re: A lua version of "amb")), Roberto Ierusalimschy
- Re: Lambda (was Re: special forms, take two (was Re: A lua version of "amb")), Mark Hamburg
- Re: Lambda (was Re: special forms, take two (was Re: A lua version of "amb")), steve donovan
- Re: Lambda (was Re: special forms, take two (was Re: A lua version of "amb")), Dirk Laurie
- Re: Lambda (was Re: special forms, take two (was Re: A lua version of "amb")), Luiz Henrique de Figueiredo