Exercises
- Implement another function in
LuaExecutor
to call a Lua function with two parameters and two return values. Try to use different Lua data types. - In
LuaExecutor
, we are usingstd::cerr
to print error messages to the console. So far, the callers cannot get the error state. Design an interface to notify failures. You can pass an implementation of this interface in theLuaExecutor
constructor.