[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: General questions.
- From: Ben Sunshine-Hill <sneftel@...>
- Date: Tue, 6 Jul 2004 10:24:40 -0700
Yep, more likely you'll want to box the pointer into a full userdata
and make sure that the metamethods know to dereference it.
On Tue, 06 Jul 2004 17:59:44 +0100, Daniel Silverstone
<dsilvers@digital-scurf.org> wrote:
> Peter Bradshaw wrote:
> > (I've only been a lua user for about a month, so I may be about to get
> > rudely slapped for inaccuracy).
> >
> > Light userdata sounds like exactly what you want. You just push a
> > pointer into lua and that's what you get back.
> >
> > Setting the metatable from C and then checking it seems to be the way
> > to ensure type safety.
>
> Erm, Light userdatas can't have metatables.
>
> D.
>
> --
> Daniel Silverstone http://www.digital-scurf.org/
> PGP mail accepted and encouraged. Key Id: 2BC8 4016 2068 7895
>