Skip to content

extend meta_enum: add a members_of<Enum>() function to get a range over all declared values

Gerhard Raven requested to merge extend-meta-enum into master

For enums declared with the meta_enum macro, e.g

meta_enum_class( MyEnum,int, Unknown = 0, Case1, Case2, Case1000  = 1000 )

it is now possible to write a loop over all declared values, e.g.

  for (MyEnum i : members_of<MyEnum>() ) ...

Merge request reports

Loading