alibaba/wax

How can I get the error message which returned from lua?

luohui8891 opened this issue · 2 comments

Yo,
How can I get any error message from lua level when I wax_runLuaString a lua script (like missing end)?

wax_start(nil, nil);
int i = wax_runLuaString("print('hello wax)");
if(i){
    NSLog(@"error=%s", lua_tostring(wax_currentLuaState(), -1));
}

Got it. Thanks.
BTW, why there are many debug log like NSLog(@"data->waxRetain = YES instance=%@", data->instance); in the source code, just asking.