[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Metatable check helper API proposal
- From: Andrew Gierth <andrew@...>
- Date: Wed, 19 Aug 2020 14:37:25 +0100
>>>>> "Roberto" == Roberto Ierusalimschy <roberto@inf.puc-rio.br> writes:
Roberto> Another idea would be to write 'luaL_testudata' inside the
Roberto> kernel, to avoid all stack manipulation and other API
Roberto> overheads. We would need to test first to know how much could
Roberto> we gain with that.
If you do this, consider also providing an equivalent API that uses
lightuserdata keys rather than strings. I personally never use strings
as registry identifiers because of the risk of name collisions.
--
Andrew.