[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: Lua and backwards compatibility - was Re: [ANN] Lua 5.3.4 (rc2) now available,
- From: Daurnimator <quae@...>
- Date: Fri, 13 Jan 2017 20:52:42 +1100
On 13 January 2017 at 20:01, steve donovan <steve.j.donovan@gmail.com> wrote:
> On Fri, Jan 13, 2017 at 9:43 AM, Dirk Laurie <dirk.laurie@gmail.com> wrote:
>> Isn't it possible to mimic setfenv and getfenv (inefficiently) in
>> "pure" Lua 5.3 via the debug library?
>
> Well, naturally but the documentation also warns that the debug
> library can be very slow.
>
> _ENV never freaked me out because I never use it ;) And never missed
> setfenv either.
_ENV can be a bit weird to get used to, but once you start using it
you start to come up with nice new patterns/idioms.
However the reason I don't use _ENV more often is I often have to end
up writing code with lua 5.1 compatibility.
- References:
- Lua and backwards compatibility - was Re: [ANN] Lua 5.3.4 (rc2) now available,, Dibyendu Majumdar
- Re: Lua and backwards compatibility - was Re: [ANN] Lua 5.3.4 (rc2) now available,, William Ahern
- Re: Lua and backwards compatibility - was Re: [ANN] Lua 5.3.4 (rc2) now available,, Dibyendu Majumdar
- Re: Lua and backwards compatibility - was Re: [ANN] Lua 5.3.4 (rc2) now available,, William Ahern
- Re: Lua and backwards compatibility - was Re: [ANN] Lua 5.3.4 (rc2) now available,, Dirk Laurie
- Re: Lua and backwards compatibility - was Re: [ANN] Lua 5.3.4 (rc2) now available,, steve donovan