Re: Lua 5.2 Keywords - In
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
- Subject: Re: Lua 5.2 Keywords - In
- From: Olivier Hamel <evilpineapple@...>
- Date: 2010年1月12日 22:31:10 -0500
Cosmin Apreutesei wrote:
Guess "with" is reserved for RAII (I wouldn't like it, but see [1][2])
:) Otherwise `in` feels more "immersive" :)
[1] http://lua-users.org/lists/lua-l/2009-01/msg00333.html
[2] http://lua-users.org/lists/lua-l/2009-05/msg00539.html
That leaves 'using', which would seem a logical keyword to choose. The
downside would be that it would add a new keyword, the upside would be
that it eliminates a keyword overload. Or am I the only one that feels
that 'in' isn't quite right? 'Using' just has a better ring in my opinion.
Olivier
PS: Personally I always felt comfortable using a :Release()/:Delete()
explicit system for releasing resources deterministically, I wouldn't
see why we'd clutter up Lua with explicit RAII keywords. I like the fact
that Lua has such a small vocabulary but is so expressive.