Bitwise operations on integers #
Possibly only of archaeological significance.
Recursors #
Int.bitCasesOn
: Parity disjunction. Something is true/defined onℤ
if it's true/defined for even and for odd values.
Int.bitwise
applies the function f
to pairs of bits in the same position in
the binary representations of its inputs.
Equations
Instances For
m <<< n
produces an integer whose binary representation
is obtained by left-shifting the binary representation of m
by n
places
Equations
m >>> n
produces an integer whose binary representation
is obtained by right-shifting the binary representation of m
by n
places
Equations
bitwise ops #
@[deprecated Int.shiftLeft_natCast (since := "2025-03-10")]
Alias of Int.shiftLeft_natCast
.
@[deprecated Int.shiftRight_natCast (since := "2025-03-10")]
Alias of Int.shiftRight_natCast
.
@[simp]
Compare with Int.shiftRight_add
, which doesn't have the coercions ℕ → ℤ
.
bitwise ops #
@[simp]
Compare with Int.zero_shiftRight
, which has n : ℕ
.