diff --git a/include/magic_enum.hpp b/include/magic_enum.hpp index 517f7fc..b638156 100644 --- a/include/magic_enum.hpp +++ b/include/magic_enum.hpp @@ -927,7 +927,7 @@ template , typename Lambda, typename ResultGetterType> -constexpr std::invoke_result_t constexpr_switch( +constexpr decltype(auto) constexpr_switch( Lambda&& lambda, typename std::decay_t::value_type searched, ResultGetterType&& def,