magic_enum
magic_enum copied to clipboard
Provide reflection data as compile time lists rather than array
Working with arrays in a compile time context is not the easiest thing. It is much more convenient to work with integer_list. Boost describe ( https://www.boost.org/doc/libs/1_79_0/libs/describe/doc/html/describe.html ) provides also reflection on enums, but uses a slightly different structure:
«
A descriptor list is a type of the form L<D1, D2, …, Dn>, where L is of the form template<class… T> struct L {}; and Di is of the form
struct Di { static constexpr E value; static constexpr char const* name; };
»
It would be nice if we could also get this, in addition to what is currently provided, with magic_enum.
Oh, I haven't seen this library in boost yet, I'll take a look at it.