numberOfTrailingZeros method Null safety

  1. @override
int numberOfTrailingZeros()
override

Returns the number of trailing zeros in this Int64 as an int between 0 and 64.

Implementation

@override
int numberOfTrailingZeros() {
  int zeros = Int32._numberOfTrailingZeros(_l);
  if (zeros < 32) {
    return zeros;
  }

  zeros = Int32._numberOfTrailingZeros(_m);
  if (zeros < 32) {
    return _BITS + zeros;
  }

  zeros = Int32._numberOfTrailingZeros(_h);
  if (zeros < 32) {
    return _BITS01 + zeros;
  }
  // All zeros
  return 64;
}