[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: setmetatable vs debug.setmetatable?
- From: Tony Finch <dot@...>
- Date: Fri, 3 Aug 2007 13:32:22 +0100
On Fri, 3 Aug 2007, PA wrote:
>
> With setmetatable, one can assign a metatable per table instance. One the
> other hand, debug.setmetatable seems to assign a metatable per object type,
> not object instance, e.g.:
See paragraph 5 of section 2.8 of the reference manual. Only tables and
userdata have per-value metatables. The other metatables are per-type.
Tony.
--
f.a.n.finch <dot@dotat.at> http://dotat.at/
IRISH SEA: SOUTHERLY, BACKING NORTHEASTERLY FOR A TIME, 3 OR 4. SLIGHT OR
MODERATE. SHOWERS. MODERATE OR GOOD, OCCASIONALLY POOR.