Skip to content

Additional features for flags enums #240

@RobertRiojaAlpa

Description

@RobertRiojaAlpa

Hello,

I have some suggestions for features I've come across so far that'd be nice to have.

  1. For flags enums, a MyEnumExtensions.All field that resolves to a bitwise OR of every value would be very useful, no longer requiring the user to define one for many situations. This also prevents the Length field from being inaccurate in such a case.
  2. Also related, adding an ExcludeFromLength boolean field to the EnumMemberAttribute could be useful. All occurrences of it would be counted and subtracted from Length.
  3. For all enums, myEnum.Next() and myEnum.Previous() are commonly implemented and could instead be generated. To be more thorough, an ExcludeFromPreviousNext field could be added to EnumMemberAttribute as well.

Thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions