Static reflection for enums (to string, from string, iteration) for modern C++, work with any enum type without any macro or boilerplate code
Release v0.9.4
include/magic_enum
directoryRelease v0.9.3
enum_next_value
and enum_prev_value
in <magic_enum_utility.hpp>
(https://github.com/Neargye/magic_enum/issues/280)enum_for_each
to <magic_enum_utility.hpp>
<magic_enum_all.hpp>
MAGIC_ENUM_NO_ASSERT
MAGIC_ENUM_NO_EXCEPTION
MAGIC_ENUM_ENABLE_HASH_SWITCH
_ITERATOR_DEBUG_LEVEL
on msvcRelease v0.9.2
enum_flags_test
and enum_flags_test_any
functions for flagsenum_flags_*
to <enum_flags.hpp>
Release v0.9.1
Release v0.9.0
enum_range::is_flags
. Need to explicitly set enum_range::is_flags
, or add define MAGIC_ENUM_AUTO_IS_FLAGS
for old behavior.iostream_operators
to magic_enum_iostream.hpp
enum_range
. (https://github.com/Neargye/magic_enum/pull/268)-fno-pretty-templates
. (https://github.com/Neargye/magic_enum/pull/258)<functional>
. (https://github.com/Neargye/magic_enum/pull/252)Release v0.8.2
MAGIC_ENUM_ENABLE_HASH
to generate a hash switch, this need more memory and compile-time but functions like 'enum_name', 'enum_switch', etc will have O(1) complexityenum_switch
enum_switch
(https://github.com/Neargye/magic_enum/issues/199)Release v0.8.0
Release v0.8.0
[breaking changes] New enum-flags API. Added is_flags option in enum_range.
[breaking changes] New customize. (#166)
Add enum_fuse - fusing function in separate header.
Add support for non-ASCII characters (UNIX/Linux) (#95)
Add enum_switch and enum_for_each.
Add istream operators.
Add compile-time enum_index and enum_value.
Add support gcc8 with defined MAGIC_ENUM_NO_CHECK_SUPPORT. (#137)
Many small fixes underflow in out of range check, bool enum, etc.
Release v0.7.3