|
From: | Nicholas Papadonis |
Subject: | using open-i/o-file function |
Date: | Sat, 3 Apr 2021 20:23:35 -0400 |
open-i/o-file
is not working as I expected. Does anyone know what the issue is?(define l "~/tmp0")
(define x ''(a b (c d) e f))
(let ((p (open-i/o-file l)))
(begin (write x p)
(flush-output p)
(let ((r (read p)))
(close-port p)
r)))
;Value: #!eof
when I was expecting:
;Value: (quote (a b (c d) e f))
When usingopen-input-file
oropen-output-file
the results are expected:
(let ((p (open-output-file l)))
(write x p)
(close-port p))
(let ((p (open-input-file l)))
(let ((r (read p)))
(close-port p)
r))
;Value: (quote (a b (c d) e f))
[Prev in Thread] | Current Thread | [Next in Thread] |