Re: ipairs and metamethods in 5.3
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
- Subject: Re: ipairs and metamethods in 5.3
- From: steve donovan <steve.j.donovan@...>
- Date: 2017年7月27日 15:35:30 +0200
On Thu, Jul 27, 2017 at 2:05 PM, Dirk Laurie <dirk.laurie@gmail.com> wrote:
> 3. Redefine the global 'ipairs' (pl.pretty does not cache it locally)
I have mixed feelings about this - on the one hand, it's flexible, and
on the other, it's a recipe for chaos. I know that we are not so
tolerant of monkey patching as the Rubyists! But the problem here is
more of consistency, because I _do_ cache common calls in most other
places. A reasonably elegant compromise is to always cache, and
therefore modification must take place before any PL module is loaded.