[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: any plan about luajit2 support 5.2!
- From: David Manura <dm.lua@...>
- Date: Thu, 18 Nov 2010 13:25:52 -0500
On Thu, Nov 18, 2010 at 5:11 AM, Mike Pall <mikelu-1011@mike.de> wrote:
> David Manura wrote:
>> One thing that concerns me here is that in 5.2, "C
>> functions do not have environments any more"--is that a problem when
>> backporting lightweight C functions to 5.1/LuaJIT?
>
> Yes. I can't add anything similar to LuaJIT, because C functions
> still _do_ have an environment in 5.1.
Maybe LuaJIT2, as well as a compatibility patch to Lua 5.1, could
implement a non-standard "lua52_pushcfunction" that behaves like the
5.2 version? Then the user may alias lua_pushcfunction and
lua52_pushcfunction via compiler defines to allow a single piece of
code to target different Lua versions (i.e. 5.1 + compatibility
patches, 5.2, and LuaJIT2).