luaL_error use replaced with c++ exceptions
This commit is contained in:
@@ -18,8 +18,7 @@ static int l_json_stringify(lua_State* L) {
|
||||
lua_pushstring(L, string.c_str());
|
||||
return 1;
|
||||
} else {
|
||||
luaL_error(L, "table expected");
|
||||
return 0;
|
||||
throw std::runtime_error("table expected");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user