lua-users home
lua-l archive

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



On Nov 19, 2010, at 16:33, Leo Razoumov <slonik.az@gmail.com> wrote:

> On Fri, Nov 19, 2010 at 16:28, Petite Abeille <petite_abeille@mac.com> wrote:
>> 
>> On Nov 19, 2010, at 10:22 PM, Patrick Rapin wrote:
>> 
>>> Maybe bit32._and, bit32._or would be better looking ?
>> 
>> well, at that point you could as well call then 'and' and 'or' :P
>> 
>> bit32['and']
>> bit32['or']
>> 
>> If the brackets are a bother, make bit32 a function, so you can use a bit of sugar:
>> 
>> bit32'or'
>> 
> 
> bit32['and'] is exactly the same as bit32.and
> 
> What is the point of using extra [''] symbols that are not needed here?
> Am I missing something?

Lua doesn't currently allow dot syntax to use keywords like and. It could be done but I'm not sure such a change is suitable for Lua.