1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-05-30 00:40:20 +02:00

* r4rs.scm (OPEN_READ, OPEN_WRITE, OPEN_BOTH): Don't bother

testing software-type here.  That's the least of our Windows
porting issues, and it's done wrong anyway.
This commit is contained in:
Jim Blandy 1998-10-12 20:08:31 +00:00
parent 81aef0ba59
commit 670600bd66

View file

@ -40,19 +40,17 @@
;;; "internally" in a few places. ;;; "internally" in a few places.
;; OPEN_READ, OPEN_WRITE, and OPEN_BOTH are used to request the proper ;;; OPEN_READ, OPEN_WRITE, and OPEN_BOTH are used to request the
;; mode to open files in. MSDOS does carraige return - newline ;;; proper mode to open files in.
;; translation if not opened in `b' mode. ;;;
;; ;;; If we want to support systems that do CRLF->LF translation, like
(define OPEN_READ (case (software-type) ;;; Windows, then we should have a symbol in scmconfig.h made visible
((MS-DOS WINDOWS ATARIST) "rb") ;;; to the Scheme level that we can test here, and autoconf magic to
(else "r"))) ;;; #define it when appropriate. Windows will probably just have a
(define OPEN_WRITE (case (software-type) ;;; hand-generated scmconfig.h file.
((MS-DOS WINDOWS ATARIST) "wb") (define OPEN_READ "r")
(else "w"))) (define OPEN_WRITE "w")
(define OPEN_BOTH (case (software-type) (define OPEN_BOTH "r+")
((MS-DOS WINDOWS ATARIST) "r+b")
(else "r+")))
(define *null-device* "/dev/null") (define *null-device* "/dev/null")