google-code-export / lua-alchemy

Automatically exported from code.google.com/p/lua-alchemy
0 stars 1 forks source link

Async mode is broken if invoked from Lua #154

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
    public function testDoStringAsyncReentrant():void
    {
      myLuaAlchemy.setGlobal("_ALCHEMY", myLuaAlchemy);

      var script:String = ( <![CDATA[
        _ALCHEMY.doStringAsync(
            [[
              return 42
            ]],
            as3.class.Function.new()
          )

        as3.trace("CRASHES HERE")

        return 24

      ]]> ).toString();

      doStringAsync(1, script, [ true, [ true, 42 ] ]);
    }

Crashes with

#0   this = [Object 4669067025, 
class='cmodule.lua_wrapper::FSM_luaV_execute'].FSM_luaV_execute/work() at 
<null>:0
#1   this = [Object 4678689393, 
class='cmodule.lua_wrapper::CRunner'].CRunner/work() at <null>:0
#2   this = [Object 4523004129, 
class='global'].Function/<anonymous>(_arg1=[Object 4532202225, 
class='flash.events::TimerEvent']) at <null>:0
#3   Timer/_timerDispatch() at <null>:0
#4   this = [Object 4666036105, class='flash.utils::Timer'].Timer/tick() at 
<null>:0

Original issue reported on code.google.com by aglad...@gmail.com on 25 Feb 2012 at 6:14

GoogleCodeExporter commented 9 years ago
Same behavior if this is run on a separate Lua state, created inside the first 
one.

Original comment by aglad...@gmail.com on 25 Feb 2012 at 7:58