packBitMask

convert array of values to bit fields

packBitMask
(
T
)
()

Examples

1 assert( packBitMask!uint() == 0 );
2 auto a = 0b0001;
3 assert( packBitMask(a) == a );
4 auto b = 0b0010;
5 assert( packBitMask(b) == b );
6 auto c = 0b0011;
7 assert( packBitMask(a,b) == c );

Meta