chickadee » honu » read-honu

read-honu #!key port line-numbers lnwrap flavorprocedure

Reads a single honu expression from PORT, which defaults to the value of (current-input-port) . If SHOW-LINE-NUMBERS is given and true, then parsing errors will report the offending line-number (as obtained by port-position. The optional argument WRAP may be given to wrap each read item into a user-definable structure, or to perform user-specific conversion. WRAP is called for each H-expression with the expression and the current line number as arguments replacing the H-expression with the result.

FLAVOR should be a symbol and adds additional special handling:

default behaviour.
allows the characters #\\ and #\@ as operator characters, allows % ... as single-line comments (but not // ...), reads '...' as symbol.
reads '...' as string.

Previously to version 2.1 of this egg, read-honu had the following signature: