lua-users home
lua-l archive

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


On Tue, Jun 14, 2011 at 04:43:26PM +0200, Patrick Rapin wrote:
> Now `string` seems to have a metatable, but which doesn't support
> indexing of unknown metamethods.
> 
The metatable of `string` is itself.  It has a method __index.
You can override __index if you don't like what it does.  E.g.:

> string.__index = rawindex
> return getmetatable(string).__call
nil

So it seems to be a feature, not a bug. :-)

Dirk