Is there an easy way to convert bitmasks to array index?
T. If I have enum
a = 0x01,
b = 0x02,
c = 0x04,
d = 0x08,
e = 0x10,
etc
and I want to store the released data in an array, is there an easy way so that I can convert a to 0, b to 1, c to 2, etc.?
Many thanks
source
share