diff --git a/sol/function_types.hpp b/sol/function_types.hpp index 4ce3242e..702959e2 100644 --- a/sol/function_types.hpp +++ b/sol/function_types.hpp @@ -313,14 +313,16 @@ namespace sol { template struct pusher> { static int push(lua_State* L, overload_set&& set) { + // TODO: yielding typedef function_detail::overloaded_function<0, Functions...> F; - pusher>{}.set_fx(L, std::move(set.functions)); + pusher>{}.set_fx(L, std::move(set.functions)); return 1; } static int push(lua_State* L, const overload_set& set) { + // TODO: yielding typedef function_detail::overloaded_function<0, Functions...> F; - pusher>{}.set_fx(L, set.functions); + pusher>{}.set_fx(L, set.functions); return 1; } }; diff --git a/sol/function_types_stateful.hpp b/sol/function_types_stateful.hpp index dc1e2eb6..2e54636f 100644 --- a/sol/function_types_stateful.hpp +++ b/sol/function_types_stateful.hpp @@ -104,10 +104,13 @@ namespace function_detail { switch (lua_gettop(L)) { case 0: nr = call_detail::call_wrapped(L, var, mem); + break; case 1: nr = call_detail::call_wrapped(L, var, mem); + break; default: nr = luaL_error(L, "sol: incorrect number of arguments to member variable function"); + break; } } if (is_yielding) {