lua-users home
lua-l archive

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


> Right, I could use the registry table, I went down the route of using
> the luaL_ref function first, but they appeared to be down hash key
> lookups instead of array index lookups. For my 1000's of tables, this
> meant luaH_getstr showing up at the top of my profile runs, because it
> was iterating through keys to find the values after converting my
> carefully chosen numeric values into TValue objects.

No matter how your numeric keys are stored, Lua never uses luaH_getstr
to access them. luaH_getstr only works for string keys.

-- Roberto