On Dec 18, 2007, at 10:31 PM, Bob McIsaac wrote:
(define (integer-in ) (set! *filesize* (- *filesize* 4)) (bitwise-ior (bitwise-and (arithmetic-shift (read-u8 INP) 24) #xff000000) (bitwise-and (arithmetic-shift (read-u8 INP) 16) #xff0000) (bitwise-and (arithmetic-shift (read-u8 INP) 8) #xff00) (bitwise-and (read-u8 INP) #xff)))
This code assumes that arguments to functions are evaluated left-to- right.
Do
(let* ((byte-1 (read-u8 INP)) (byte-2 (read-u8 INP))
etc.