[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: tables with __index metamethods and next()
- From: Ben Kelly <ranavin@...>
- Date: Mon, 11 Aug 2008 10:15:34 -0400
Mark Hamburg wrote:
> On Aug 8, 2008, at 5:01 AM, Luiz Henrique de Figueiredo wrote:
>
>>> So what do you guys think about adding a __next metamethod for
>>> example?
>>
>> See http://lua-users.org/lists/lua-l/2008-02/msg00720.html
>
> Of course, that just teases the community with the question: When?
>
> I well understand schedules, however.
>
> Mark
>
In the meantime you can always define your own, by replacing pairs,
ipairs and next with custom versions that respect __next, __pairs and
__ipairs.
Ben