[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Behaviour of table.remove()
- From: "Matthew P. Del Buono" <delbu9c1@...>
- Date: Thu, 29 Oct 2009 15:41:34 -0400
Duncan Cross wrote:
> the # length operator require that the table be
> "array-like", or they have undefined, inconsistent behaviour.
>
> -Duncan
I'm not sure saying it has "undefined" behavior is appropriate. Its
behavior is perfectly defined. It is guaranteed that t[#t] will be
non-nil and t[#t+1] will be nil, except in the special case of #t == 0.
Thus, the table {1, nil, 3} has only two possible results of #t: 1 and 3.
Inconsistent, however, I will take.
Regards,
Matthew P. Del Buono