Previous: SRFI-56 Bignum encodings, Up: SRFI-56


39.18.10 SRFI-56 IEEE floating-point encodings

— Scheme Procedure: default-float-endian

Return either big-endian or little-endian (a symbol).

— Scheme Procedure: read-ieee-float32 [port [endian]]

Read an IEEE single-precision float from the current input port. Optional arg port specifies a port to read from, instead. Optional second arg endian is a symbol. Return the eof object if not enough bytes are available.

— Scheme Procedure: read-ieee-float64 [port [endian]]

Read an IEEE double-precision float from the current input port. Optional arg port specifies a port to read from, instead. Optional second arg endian is a symbol. Return the eof object if not enough bytes are available.

— Scheme Procedure: write-ieee-float32 n [port [endian]]

Write number n as an IEEE single-precision float to the current output port. Optional second arg port specifies a port to write to, instead. Optional third arg endian is a symbol.

— Scheme Procedure: write-ieee-float64 n [port [endian]]

Write number n as an IEEE double-precision float to the current output port. Optional second arg port specifies a port to write to, instead. Optional third arg endian is a symbol.