50template<
typename TEnum>
51requires std::is_enum_v<TEnum>
67 static constexpr TEnum
End;
77template <
typename TEnum>
112template<
typename TEnum,
typename TRhs=
int>
114constexpr TEnum
operator+ (TEnum element, TRhs summand)
noexcept
116 return TEnum( alib::UnderlyingIntegral(element)
117 +
static_cast<typename std::underlying_type<TEnum>::type
>(summand) );
131template<
typename TEnum,
typename TRhs=
int>
133constexpr TEnum
operator- (TEnum element,
typename std::underlying_type<TEnum>::type subtrahend)
noexcept
135 return TEnum( alib::UnderlyingIntegral(element)
136 -
static_cast<typename std::underlying_type<TEnum>::type
>(subtrahend) );
155template<
typename TEnum>
172 template<
typename TPo
inter,
typename TReference>
186 using TIntegral=
typename std::underlying_type<TEnum>::type;
236 return !(*
this == other);
411template<
typename TEnum>
412requires enumops::IsIterable<TEnum>
TRandomAccessIterator operator--(typename std::underlying_type< TEnum >::type)
TRandomAccessIterator operator++(typename std::underlying_type< TEnum >::type)
TReference reference
Implementation of std::iterator_traits.
TRandomAccessIterator & operator++()
std::ptrdiff_t difference_type
Implementation of std::iterator_traits.
TRandomAccessIterator & operator-=(TIntegral n)
typename std::underlying_type< TEnum >::type TIntegral
The underlying integer type.
TRandomAccessIterator & operator--()
TRandomAccessIterator operator-(TIntegral n) const
bool operator<=(TRandomAccessIterator other) const
constexpr TRandomAccessIterator(TEnum pp=TEnum(0))
bool operator<(TRandomAccessIterator other) const
TEnum operator[](std::ptrdiff_t n) const
std::random_access_iterator_tag iterator_category
Implementation of std::iterator_traits.
constexpr bool operator==(TRandomAccessIterator other) const
TPointer pointer
Implementation of std::iterator_traits.
TEnum value_type
Implementation of std::iterator_traits.
bool operator>(TRandomAccessIterator other) const
TRandomAccessIterator operator+(TIntegral n) const
TRandomAccessIterator & operator+=(TIntegral n)
constexpr bool operator!=(TRandomAccessIterator other) const
bool operator>=(TRandomAccessIterator other) const
constexpr TEnum operator*() const
std::ptrdiff_t operator-(TRandomAccessIterator other) const
#define ALIB_WARNINGS_RESTORE
#define ALIB_WARNINGS_IGNORE_DOCS
std::underlying_type_t< TEnum > constexpr UnderlyingIntegral(TEnum element) noexcept
constexpr int MSB(TIntegral value)
enumops::EnumIterator< TEnum > EnumIterator
Type alias in namespace alib.
ConstIterator end() const
TRandomAccessIterator< const TEnum *, const TEnum & > ConstIterator
The constant iterator exposed by this class. A Mutable version is not available.
EnumIterator()=default
Default constructor.
ConstIterator begin() const
static constexpr TEnum Begin
static constexpr TEnum End