buffer.tostring return _G.tostring on Lua 5.1
moteus opened this issue · 0 comments
moteus commented
In alien_buffer_new we do not set lua_setuservalue (lua_setfenv on lua5.1)
In alien_buffer_get we call lua_getuservalue(L, 1); that return _G
And we lookup functions in global.
so call
buf:tostring(3,2) become to _G.tostring(buf, 3, 2)