Primitive predicate QlBuiltins::BigInt::bitLength
Returns the number of bits in the minimal two’s complement representation of the receiver, excluding a sign bit. This means that the receiver is minimally representable as a bitLength()+1
-bit signed integer. For positive BigInt
s, this is equivalent to the number of bits in the ordinary binary representation. For negative BigInt
s, this gives the same result as it does for the bitwise NOT of the BigInt
. For zero and -1, this method returns 0. (Computes ceil(log2(if this < 0 then -this else this+1))
.)