diff --git a/enum.h b/enum.h index eeb3cba..5d534eb 100644 --- a/enum.h +++ b/enum.h @@ -624,12 +624,12 @@ class Enum { \ \ BETTER_ENUMS_CONSTEXPR_ std::size_t _to_index() const; \ BETTER_ENUMS_IF_EXCEPTIONS( \ - BETTER_ENUMS_CONSTEXPR_ static Enum _from_index(_integral value); \ + BETTER_ENUMS_CONSTEXPR_ static Enum _from_index(std::size_t value); \ ) \ BETTER_ENUMS_CONSTEXPR_ static Enum \ - _from_index_unchecked(_integral value); \ + _from_index_unchecked(std::size_t value); \ BETTER_ENUMS_CONSTEXPR_ static _optional \ - _from_index_nothrow(_integral value); \ + _from_index_nothrow(std::size_t value); \ \ ToStringConstexpr const char* _to_string() const; \ BETTER_ENUMS_IF_EXCEPTIONS( \ @@ -759,23 +759,23 @@ BETTER_ENUMS_CONSTEXPR_ inline std::size_t Enum::_to_index() const \ } \ \ BETTER_ENUMS_CONSTEXPR_ inline Enum \ -Enum::_from_index_unchecked(_integral value) \ +Enum::_from_index_unchecked(std::size_t index) \ { \ return \ - ::better_enums::_or_zero(_from_index_nothrow(value)); \ + ::better_enums::_or_zero(_from_index_nothrow(index)); \ } \ \ BETTER_ENUMS_CONSTEXPR_ inline Enum::_optional \ -Enum::_from_index_nothrow(_integral value) \ +Enum::_from_index_nothrow(std::size_t index) \ { \ - return _from_index_loop(value); \ + return _from_index_loop(index); \ } \ \ BETTER_ENUMS_IF_EXCEPTIONS( \ -BETTER_ENUMS_CONSTEXPR_ inline Enum Enum::_from_index(_integral value) \ +BETTER_ENUMS_CONSTEXPR_ inline Enum Enum::_from_index(std::size_t index) \ { \ return \ - ::better_enums::_or_throw(_from_index_nothrow(value), \ + ::better_enums::_or_throw(_from_index_nothrow(index), \ #Enum "::_from_index: invalid argument"); \ } \ ) \