aantron / better-enums

C++ compile-time enum to string, iteration, in a single header file
http://aantron.github.io/better-enums
BSD 2-Clause "Simplified" License
1.67k stars 173 forks source link

Unable to create the enum from the vector of strings. #87

Closed rahul233343 closed 4 years ago

rahul233343 commented 4 years ago

Do current version has support of adding enum values from the vector of strings?

If yes? How to use that?

aantron commented 4 years ago

You may be able to do it in C++20. At least, as I understand it, operator [] on std::vector is now constexpr. The string would also have to be a compile-time value.