diff --git a/include/eosio/vm/function_traits.hpp b/include/eosio/vm/function_traits.hpp index 76a88181..2355643b 100644 --- a/include/eosio/vm/function_traits.hpp +++ b/include/eosio/vm/function_traits.hpp @@ -72,12 +72,6 @@ namespace eosio { namespace vm { inline constexpr U&& make_dependent(U&& u) { return static_cast(u); } } - template - inline constexpr static bool is_callable_v = EOS_VM_HAS_MEMBER(AUTO_PARAM_WORKAROUND(FN), operator()); - - template - constexpr bool is_callable(F&& fn) { return EOS_VM_HAS_MEMBER(fn, operator()); } - namespace detail { template constexpr auto get_types(R(Args...)) -> std::tuple, Args>...>>; template constexpr auto get_types(F&& fn) { - if constexpr (is_callable_v) + if constexpr (std::is_invocable_v) return get_types(&F::operator()); else return get_types(fn); @@ -144,7 +138,7 @@ namespace eosio { namespace vm { constexpr auto parameters_from_impl(R(Cls::*)(Args...)const &&) -> pack_from_t; template constexpr auto parameters_from_impl(F&& fn) { - if constexpr (is_callable_v) + if constexpr (std::is_invocable_v) return parameters_from_impl(&F::operator()); else return parameters_from_impl(fn);