Next: , Previous: , Up: syslib flonums   [Index]


12.6.2 Binary representation inspection

Unsafe Operation: $flonum-u8-ref fl fx

Return the octet at index fx in the data area of fl.

Notice that the fx offset is positive, but it represents an offset from the end of the data area; on a 32-bit platform, the indexes of the bytes are:

   1st word    2nd word    3rd word    4th word
|-----------|-----------|-----------|-----------|
                        |--|--|--|--|--|--|--|--| bytes
                          7  6  5  4  3  2  1  0  offsets
                        |.......................|
                             IEEE 754 flonum
Unsafe Operation: $flonum-set! fl fx-index fx-value

Store the byte or octet represented by fx-value at index fx-index in the data area of fl.

Unsafe Operation: $flonum-sbe fl

Return a fixnum… Still undocumented, read the code look at the format of IEEE double precision flonums.