InternalReturns the bitwise AND of a and b.
First operand.
Second operand.
a & b as a signed 32-bit integer.
Returns the bitwise AND of a and ~b.
Same as combinator.and(a, combinator.not(b))
First operand.
Second operand.
a & ~b as a signed 32-bit integer.
Returns the bitwise NOT of a (one's complement inversion).
Value to invert.
~a as a signed 32-bit integer.
Returns the bitwise OR of a and b.
First operand.
Second operand.
a | b as a signed 32-bit integer.
Counts the number of set bits (population count) in a.
Reinterprets a as an unsigned 32-bit integer via >>> 0 before
counting, so negative inputs are treated as their unsigned equivalent.
Value whose set bits are counted.
The count of bits set to 1 in the 32-bit unsigned representation of a.
Shifts value left by shift bit positions.
Value to shift.
Number of positions to shift left (valid range: 0–31).
value << shift as a signed 32-bit integer.
Returns the bitwise XOR of a and b.
First operand.
Second operand.
a ^ b as a signed 32-bit integer.
Implements Combinator for JavaScript's built-in
numbertype using native 32-bit bitwise operators.Every operation delegates directly to JavaScript's
|,&,^,~and<<operators, which coerce their operands to a 32-bit signed integer (Int32) before computing the result. The effective flag space is therefore 32 bits (positions 0–31), and results are always returned as signed values.