lua-users home
lua-l archive

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


Internally, Lua adds an extra zero byte at the end of any string (so
also for  the empty string), but this is only to simplify interfacing
with C host code. Lua by itself never use that zero terminating byte
nor count it in the length ; it stores the length of a string together
with the pointer and the hash value.

I was more or less insinuating that even without data, an empty string
isn't really weird at all.