hasBitOps

Evaluates to true if either:

  • isScalarType!T, or
  • isCheckedInt!T

And bitwise operators such as << and ~ are available for T.

Members

Manifest constants

hasBitOps
enum hasBitOps;
Undocumented in source.
hasBitOps
enum hasBitOps;
Undocumented in source.

Examples

import checkedint.throws : SmartInt, SafeInt; // use IntFlagPolicy.throws

assert( hasBitOps!(SafeInt!(int, Yes.bitOps)));
assert( hasBitOps!(SmartInt!(int, Yes.bitOps)));
assert( hasBitOps!int);
assert( hasBitOps!bool);
assert( hasBitOps!dchar);

assert(!hasBitOps!(SafeInt!(int, No.bitOps)));
assert(!hasBitOps!(SmartInt!(int, No.bitOps)));
assert(!hasBitOps!float);

Meta