[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: Re: LUA_REGISTRYINDEX is a valid index?
- From: Dirk Laurie <dirk.laurie@...>
- Date: Wed, 11 Feb 2015 06:15:50 +0200
2015-02-11 5:59 GMT+02:00 张睿 <email@example.com>:
> Section 4.5 of Lua 5.3 document says:
> The registry table is always located at pseudo-index LUA_REGISTRYINDEX, which is a valid index.
> Is it correct?
Saying that LUA_REGISTRYINDEX is a pseudo-index means
that most API functions that requires an index into the stack
will work with a pseudo-index too, e.g.
A few functions must not be used with a pseudo-index.
Each such case is documented specifically, e.g. lua_insert.