[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: ipairs in Lua 5.3.0-alpha
- From: Sean Conner <sean@...>
- Date: Tue, 19 Aug 2014 12:49:22 -0400
It was thus said that the Great Roberto Ierusalimschy once stated:
> > Yes, since it only worked on raw tables in Lua 5.1, I can follow you
> > here. I wonder why __ipairs was introduced in Lua 5.2 in the first
> > place then?
>
> Mainly to allow proxies and to ensure that tables with metamethods
> cannot be "raw"-accessed unless through explicit raw functions.
>
> (Unfortunately, this last goal is broken: "pairs" over a table with
> no metatable returns a raw 'next' function that can be used over
> any table.)
Not any more than C is broken for allowing raw pointer access, or C++ for
allowing unbridled operator overloading, or Perl for executing line noise,
or ...
-spc (Protect the programmer too much and you end up with Ada ... )
- References:
- Re: ipairs in Lua 5.3.0-alpha, Dirk Laurie
- Re: ipairs in Lua 5.3.0-alpha, Jan Behrens
- Re: ipairs in Lua 5.3.0-alpha, Jan Behrens
- Re: ipairs in Lua 5.3.0-alpha, Dirk Laurie
- Re: ipairs in Lua 5.3.0-alpha, Jan Behrens
- Re: ipairs in Lua 5.3.0-alpha, Dirk Laurie
- Re: ipairs in Lua 5.3.0-alpha, Jan Behrens
- Re: ipairs in Lua 5.3.0-alpha, Roberto Ierusalimschy
- Re: ipairs in Lua 5.3.0-alpha, Jan Behrens
- Re: ipairs in Lua 5.3.0-alpha, Roberto Ierusalimschy