pydongery / blog

MIT License
0 stars 0 forks source link

compile time enum reflection #10

Open Tsche opened 2 months ago

Tsche commented 2 months ago

The technique used by magic_enum and librepr::ctei should be explained. Since librepr::ctei outperforms magic_enum quite significantly, the optimization techniques used should also be explained.

Tsche commented 2 months ago

I implemented an experimental builtin for this in Clang a while back, not sure whether this is in scope of a post like that. It would definitely require lots of cleaning up.