4 ms·
I've always considered magic_enum pretty useless because if your enum is large enough to need such automated features, it's too large for magic_enum's template
by gary_0 3y ago
I've always considered magic_enum pretty useless because if your enum is large enough to need such automated features, it's too large for magic_enum's template hacks so it fails, crashes the compiler, or makes your build times go insane. It only works for toy enums with a few small values.
So instead, I've resigned myself to scripted code generation at build time, and it's one of the things about C++ that makes me feel kind of grossed out.
- senkora 3y agoI really like better_enums instead of magic_enums. There’s no limit on enum size with it: http://aantron.github.io/better-enums/ http://aantron.github.io/better-enums/ It was heavily used at a former employer of mine, so definitely a solid production-ready solution.