home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #16 / NN_1992_16.iso / spool / comp / lang / scheme / 1985 < prev    next >
Encoding:
Internet Message Format  |  1992-07-29  |  910 b 

  1. Path: sparky!uunet!zaphod.mps.ohio-state.edu!uakari.primate.wisc.edu!ames!agate!anarres.CS.Berkeley.EDU!bh
  2. From: bh@anarres.CS.Berkeley.EDU (Brian Harvey)
  3. Newsgroups: comp.lang.scheme
  4. Subject: with-input-from-file
  5. Message-ID: <157f4qINNmi@agate.berkeley.edu>
  6. Date: 30 Jul 92 01:03:22 GMT
  7. Distribution: world
  8. Organization: University of California, Berkeley
  9. Lines: 11
  10. NNTP-Posting-Host: anarres.cs.berkeley.edu
  11.  
  12. How come with-input-from-file and with-output-to-file are neither
  13. essential nor simulatable with essential procedures?
  14.  
  15. I mean, if there were set-current-input-port! and set-current-output-port!
  16. then with-XXX-file could be written in terms of call-with-XXX-file.  But
  17. the current ports can only be read, not set.
  18.  
  19. With-XXX-file are useful so that a procedure written with screen and/or
  20. keyboard in mind can be redirected without having to be rewritten.
  21.  
  22. Thank you for any insight anyone can supply.
  23.