[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: [ANN] Lua 5.2.0 (beta-rc1) now available
- From: HyperHacker <hyperhacker@...>
- Date: Wed, 15 Jun 2011 19:33:42 -0600
On Wed, Jun 15, 2011 at 19:03, David Manura <dm.lua@math2.org> wrote:
> On Wed, Jun 15, 2011 at 6:35 PM, Tony Finch <dot@dotat.at> wrote:
>> Given the constraints of the parser I prefer @label or ::label without
>> trailing punctuation. (If you want a terminator you can add one or more
>> semicolons.)
>
> Moreover, this misleadingly resembles a method call:
>
> @y: f()
>
> Note that 5.2.0-beta-rc1 ignores spaces inside the label, and labels
> are statements, so these are both identical:
>
> @y:; f()
> @ y : f()
>
> My thought is to omit the colon and and use a space:
>
> @ y
>
> When you read that, you can think of it or verbalize it as
>
> at y
>
> Here, "@" is not a sigil modifying the identifier y, but rather it *is
> a keyword*. Coding style guidelines often recommend spaces around
> keywords, even if the syntax doesn't always require it ("if(x)then
> g()end").
>
> As further argument that "@" is not a sigil, we write "goto y" not "goto @y".
>
>
That was why I suggested double colons, to distinguish it from method calls.
--
Sent from my toaster.
- References:
- [ANN] Lua 5.2.0 (beta-rc1) now available, Luiz Henrique de Figueiredo
- Re: [ANN] Lua 5.2.0 (beta-rc1) now available, Alexandre Erwin Ittner
- Re: [ANN] Lua 5.2.0 (beta-rc1) now available, Frank Meier-Dörnberg
- Re: [ANN] Lua 5.2.0 (beta-rc1) now available, David Kastrup
- Re: [ANN] Lua 5.2.0 (beta-rc1) now available, Frank Meier-Dörnberg
- Re: [ANN] Lua 5.2.0 (beta-rc1) now available, Eduardo Ochs
- Re: [ANN] Lua 5.2.0 (beta-rc1) now available, Frank Meier-Dörnberg
- Re: [ANN] Lua 5.2.0 (beta-rc1) now available, David Given
- Re: [ANN] Lua 5.2.0 (beta-rc1) now available, Roberto Ierusalimschy
- Re: [ANN] Lua 5.2.0 (beta-rc1) now available, phlnc8
- Re: [ANN] Lua 5.2.0 (beta-rc1) now available, HyperHacker
- Re: [ANN] Lua 5.2.0 (beta-rc1) now available, Tony Finch
- Re: [ANN] Lua 5.2.0 (beta-rc1) now available, David Manura