diff --git a/sol/stack.hpp b/sol/stack.hpp index 42d62601..09ffe32b 100644 --- a/sol/stack.hpp +++ b/sol/stack.hpp @@ -27,6 +27,12 @@ #include namespace sol { +template +using EnableIf = typename std::enable_if::type; + +template +using DisableIf = typename std::enable_if::type; + namespace stack { namespace detail { template @@ -116,7 +122,7 @@ inline T pop(lua_State* L) { } template -inline typename std::enable_if::value>::type push(lua_State* L, T arithmetic) { +inline EnableIf> push(lua_State* L, T arithmetic) { detail::push_arithmetic(L, arithmetic, std::is_integral{}); }