lua-users home
lua-l archive

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


2012/12/16 Coda Highland <chighland@gmail.com>:
>
>> I interpret setEnabled() as "set as enabled", while being the same as
>> setEnabled(nil).
>
> Ah, and that's where we differ -- I read "setEnabled(" as "set the
> enabled property to", and thereby get an incomplete sentence if there
> isn't a parameter inside.
>

That's why one should not have hundreds of tiny routines with names
like that. `option{Enabled=true}` is unambiguous, extensible and uses
up only one name. PiL 5.3.

I've never been able to understand why people are willing to swallow
great gulps of pseudo-Java in order to avoid creating one table. Even
a well-respected member of the Lua community, in another thread,
recoiled in horror at the construction `{...}`.