[Scheme-reports] 6.7.1 ports
Andy Wingo 19 May 2011 19:59 UTC
I would like to second the concern about calling mixed binary and
character IO procedures on a port. Also, the spec should clarify which
ports are (typically) character ports, besides string ports.
The FILE-SPEC stuff makes me uneasy. Where does it come from? It's
certainly not the standard practice in any implementation I'm familiar
with.
Also, there are no examples of FILE-SPEC.
Also there is the /settings list/ definition, which is never used
anywhere.
Suggestion: instead of file specs, provide set-port-buffering! et al
procedures which implementations may restrict to only be called before
anything has been read or written from a port.
Suggestion: If you do keep file specs -- a bad idea IMO -- then do
provide examples.
Amusingly `call-with-output-file' makes a claim about not closing ports
after a nonlocal exit due to continuations; to me such claims make
arguments about robustly specifying the results for multiple returns
from mapping functions stronger. (I know that language is quite old.)
I would also like to argue against standard-input-port et al. It is
trivial for a user to provide, and not clear what it should be on all
systems. Leave it to WG2 to deal with IMO.
May `get-output-string' be called after a string port is closed?
Suggestion: no.
Andy
--
http://wingolog.org/
_______________________________________________
Scheme-reports mailing list
Scheme-reports@scheme-reports.org
http://lists.scheme-reports.org/cgi-bin/mailman/listinfo/scheme-reports