[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: Do strings move around?
- From: Andrew Gierth <andrew@...>
- Date: Thu, 27 Aug 2020 13:41:13 +0100
>>>>> "Roberto" == Roberto Ierusalimschy <email@example.com> writes:
>> What about strings accessed via upvalue pseudo-indexes?
Roberto> They should be valid while the corresponding call is active.
Roberto> Documenting it is in my "todo" list.
So here's a more tricky case: what if you do lua_tostring on some stack
index, and then move that stack item while keeping it on the stack (i.e.
with lua_rotate or one of its many derivatives such as lua_remove)?