home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #26 / NN_1992_26.iso / spool / comp / lang / scheme / 2540 < prev    next >
Encoding:
Text File  |  1992-11-06  |  1.6 KB  |  39 lines

  1. Newsgroups: comp.lang.scheme
  2. Path: sparky!uunet!charon.amdahl.com!pacbell.com!decwrl!sun-barr!ames!saimiri.primate.wisc.edu!zaphod.mps.ohio-state.edu!cs.utexas.edu!bcm!rice!cs.rice.edu!dorai
  3. From: dorai@cs.rice.edu (Dorai Sitaram)
  4. Subject: Re: overwriting files?
  5. Message-ID: <Bx9MHE.6MM@rice.edu>
  6. Sender: news@rice.edu (News)
  7. Organization: Rice University, Houston
  8. References: <1da7u4INN43t@agate.berkeley.edu>
  9. Date: Thu, 5 Nov 1992 22:58:25 GMT
  10. Lines: 27
  11.  
  12. In article <1da7u4INN43t@agate.berkeley.edu> bh@anarres.CS.Berkeley.EDU (Brian Harvey) writes:
  13. >R4RS doesn't seem to provide a standard way to open for writing a file
  14. >that already exists (to replace it with a new version).
  15. >
  16. >What do people do about this?  Is there a portable solution?  Is every
  17. >version of Scheme different about this?
  18.  
  19. Imho, Scheme needs to allow _some_ way to test if a file
  20. exists and to delete a file.  These need not actually be
  21. provided through new procedures file-exists? and
  22. delete-file. I think some dialects -- UMB Scheme? -- have
  23. open-input-file return #f (not error) on a nonexistent file
  24. and open-output-file destroy (if not exactly delete) an
  25. existent file. (Or maybe I'm thinking call-with-*-file.)
  26.  
  27. Since we already have file procedures in r4rs, I don't think
  28. adding these testing and deleting capabilities can be
  29. subject to the same kind of controversy that might envelop
  30. "new" issues like macros, records, eval, etc.  I'm curious
  31. that this area remains untouched in all the reports.
  32.  
  33. --d
  34.  
  35. -- 
  36.  
  37. dorai@cs.rice.edu      !    It may be that the gulfs will wash us down;
  38. dorai@owlnet.rice.edu  !      it may be we shall touch the Happy Isles.
  39.