Skip to content

v3.1.0

Choose a tag to compare

@yaroslavche yaroslavche released this 28 Aug 13:53
· 5 commits to main since this release
d6d2c31

Key Changes

  • Automatic int-backed Enum Support: The EnumBitMask constructor now automatically detects int-backed enums and uses their values instead of their position. This allows for non-sequential bitmask values (e.g., 1, 4, 8), solving a major limitation of the previous version (see #33).
  • Value Validation: Added a validation step to ensure that all int-backed enum values are single-bit values (powers of two). An InvalidEnumException is thrown for invalid values (e.g., 3, 5).

This is a breaking change that requires updating any int-backed enums to use single-bit values.