Previous: Modification of Bit Strings, Up: Bit Strings [Contents][Index]
Both length and integer must be exact non-negative integers.
Converts integer into a newly allocated bit string of length
bits. Signals an error of type condition-type:bad-range-argument
if integer is too large to be represented in length bits.
Length must be an exact non-negative integer, and integer
may be any exact integer. Converts integer into a newly allocated
bit string of length bits, using two’s complement encoding for
negative numbers. Signals an error of type
condition-type:bad-range-argument
if integer is too large
to be represented in length bits.
Converts bit-string into an exact integer.
bit-string->signed-integer
regards bit-string as a two’s
complement representation of a signed integer, and produces an integer
of like sign and absolute value. bit-string->unsigned-integer
regards bit-string as an unsigned quantity and converts to an
integer accordingly.