24.  Input  

(read)
(read input-port)

See R^4RS.

(read-char)
(read-char input-port)

See R^4RS.

(read-string)
(read-string input-port)

If the argument is omitted, it defaults to the current input port.
Returns the rest of the current input line as a string (not including the terminating newline).

(unread-char char)
(unread-char char input-port)

If the second argument is omitted, it defaults to the current input port.
Pushes char back on the stream of input characters. It is not an error for char not to be the last character read from the port. It is undefined whether more than one character can be pushed back without an intermittent read operation, and whether a character can be pushed back before something has been read from the port. The procedure returns char.

(peek-char)
(peek-char input-port)

See R^4RS.

peek-char uses unread-char to push back the character.

(eof-object? obj)

See R^4RS.

(char-ready? input-port)

See R^4RS.

char-ready cannot be implemented correctly based on C FILE pointers. In the current version, char-ready can return #f although a call to read-char would not block.


Markup created by unroff 1.0,    September 24, 1996,    net@informatik.uni-bremen.de