lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


-- Pierre-Yves



On Sat, Nov 27, 2010 at 02:36, Mark Hamburg <mark@grubmah.com> wrote:
> On Nov 26, 2010, at 2:49 PM, Doug Lua wrote:
>
>> If the form is to be limited to an expression, I think LHF's syntax is the best I've seen so far - even with the '\' being in two different places on two keyboards in my house!
>>
>>  \x,y,z(x*y+z)    --> function(x,y,z) return x*y+z end
>>
>> It's concise and seems to have the fewest (zero?) ambiguities.
>
> My issues with this syntax:
>
> 1. It looks weird if I like to use a little more whitespace:
>
>        \ x, y, z ( x * y + z )

You could drop the comas without ambiguities.
    \ x y z ( x * y + z )


> But then win here over traditional syntax seems small and we probably need examples of why statement support is worth it.

See my other post http://article.gmane.org/gmane.comp.lang.lua.general/71179.