[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: 'table' as fallback for tables
- From: Sean Conner <sean@...>
- Date: Sat, 25 Jun 2016 23:41:46 -0400
It was thus said that the Great Tim Hill once stated:
>
> That is, unless you *define* a sparse array as a table having an “n” key
> (and hope no-one uses this perfectly normal key for something else…).
I wonder why Roberto didn't use _N for this? Section 3.1:
As a convention, programs should avoid creating names that start
with an underscore followed by one or more uppercase letters (such
as _VERSION).
and section 4.5:
As with variable names, string keys starting with an underscore
followed by uppercase letters are reserved for Lua.
Makes it clear it's a Lua-specific variable and it shouldn't clash with
any user code.
-spc