Clone of Lua's table library that uses '.n'

$ luarocks install --server= table.n

Lua uses "sequences", i.e. tables with consecutive integer
keys and non-nil values, as arrays. But since one cannot
efficiently check whether a table is a sequence or not (and
in fact the default table library doesn't try), this leads
to some surprising bugs. Using an explicit `n` field to
denote table lengths is an alternative approach that's
(hopefully) easier to grasp and less error prone.


scm-0dev3 years ago(revision: 2)26 downloads


lua >= 5.1, < 5.5