Warning: This is the manual of the legacy Guile 2.0 series. You may want to read the manual of the current stable series instead.
Next: rnrs syntax-case, Previous: rnrs arithmetic flonums, Up: R6RS Standard Libraries [Contents][Index]
The (rnrs arithmetic bitwise (6))
library provides procedures for
performing bitwise arithmetic operations on the two’s complement
representations of fixnums.
This library and the procedures it exports share functionality with SRFI-60, which provides support for bitwise manipulation of integers (see SRFI-60).
These procedures are identical to the lognot
, logand
,
logior
, and logxor
procedures provided by Guile’s core
library. See Bitwise Operations, for documentation.
Returns the bitwise “if” of its arguments. The bit at position
i
in the return value will be the i
th bit from ei2
if the i
th bit of ei1 is 1, the i
th bit from
ei3.
Returns the number of 1 bits in the two’s complement representation of ei.
Returns the number of bits necessary to represent ei.
Returns the index of the least significant 1 bit in the two’s complement representation of ei.
Returns #t
if the ei2th bit in the two’s complement
representation of ei1 is 1, #f
otherwise.
Returns the result of setting the ei2th bit of ei1 to the ei2th bit of ei3.
Returns the integer representation of the contiguous sequence of bits in ei1 that starts at position ei2 (inclusive) and ends at position ei3 (exclusive).
Returns the result of replacing the bit field in ei1 with start and end positions ei2 and ei3 with the corresponding bit field from ei4.
Returns the result of shifting the bits of ei1 right or left by
the ei2 positions. bitwise-arithmetic-shift
is identical
to bitwise-arithmetic-shift-left
.
Returns the result of cyclically permuting the bit field in ei1 with start and end positions ei2 and ei3 by ei4 bits in the direction of more significant bits.
Returns the result of reversing the order of the bits of ei1 between position ei2 (inclusive) and position ei3 (exclusive).
Next: rnrs syntax-case, Previous: rnrs arithmetic flonums, Up: R6RS Standard Libraries [Contents][Index]