Licence
MIT
Version
0.0.2
Deps
0
Size
10 kB
Vulns
0
Weekly
0
EnumSet
A specialized Set implementation for use with numerical enum types. All state is packed into a single 32-bit integer bitfield.
Caveats
- All enum values must be integers in the interval [0,32). This is enforced through TypeScript.
- Iteration order breaks the Set
contract. The methods
forEach,keys,valuesand[Symbol.iterator]iterate in the ascending order of the enum values and not in insertion order.