- changed status to resolved
read-line should handle carriage return as an end of line
Issue #33
resolved
R7RS says;
For the purpose of this procedure, an end of line consists of either a
linefeed character, a carriage return character, or a sequence of a carriage
return character followed by a linefeed character
So this should read string without carriage return.
(import (scheme base) (scheme file))
(let* ((p (open-input-string "okokok\r\nblerg\r\n"))
(line0 (read-line p))
(line1 (read-line p)))
(write line0) (newline)
(write line1) (newline))
Comments (1)
-
reporter - Log in to comment
Implemented own read-line instead of using get-line in (scheme base) (Fixes
#33)→ <<cset 806cade9bfcd>>