lua-users home
lua-l archive

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


Hello.

I'm using the latest 5.4 sources from github. lua_rawgetp appears to pop an 
extra value from the stack, and fails an API check if that value isn't a 
table. E.g. lua_rawgetp(L, -1, foo) effectively replaces the table with the 
retrieved value in the stack. I haven't tested it too thoroughly, but I 
believe that in the following situation

	push_some_nonempty_table(L);
	lua_newtable(L);
	lua_rawgetp(L, -2, foo);

it would pop the empty table but correctly retrieve the value from the one 
before it... which is just plain weird. lua_rawgeti is not affected by this 
and works as you'd expect: nothing is popped, 1 value is pushed.

Attachment: signature.asc
Description: This is a digitally signed message part.