testBit method

bool testBit(
  1. int index
)

Tests if the bit at index is set (1).

Implementation

bool testBit(int index) {
  if (index < 0 || index >= 64) {
    throw RangeError.range(index, 0, 63, 'index');
  }
  return (_converter.bits & (1 << index)) != 0;
}