table constructor and array length bug??
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
- Subject: table constructor and array length bug??
- From: Wesley Smith <wesley.hoke@...>
- Date: 2009年9月20日 12:54:32 -0700
2 identical tables, 2 different lengths:
res = {nil, "x"}
res2 = {}
res2[1] = nil
res2[2]= "x"
print(#res, #res2) ---->> 2, 0
I would expect both to have length 0, but the former has length 2.
This smells like a bug to me.
wes