[[project @ 2001-01-06 22:49:07 by ghouston] ghouston**20010106224907 Ignore-this: 95e9d2c6ee8b90f1a958cd830bd1324d * rw.scm (generic-read-string!/partial, read-string!/partial): removed, since this version wasn't correct but it's now in guile-core. * README: "upgraded" the guile-core dependency to tomorrows CVS version. ] hunk ./ChangeLog 1 +2001-01-06 Gary Houston + + * rw.scm (generic-read-string!/partial, read-string!/partial): + removed, since this version wasn't correct but it's now in + guile-core. + * README: "upgraded" the guile-core dependency to tomorrows + CVS version. + hunk ./README 11 -1) guile-core dated 27 November 2000 or later. Version 1.4 is too old. +1) guile-core dated 07 January 2001 or later for best results. Version 1.4 +is too old. hunk ./USAGE 110 -(bogus-substring-spec? read-string!/partial read-string/partial read-string! read-string write-string write-string/partial) +(bogus-substring-spec? read-string/partial read-string! read-string write-string write-string/partial) hunk ./rw.scm 10 -(export bogus-substring-spec? read-string!/partial read-string/partial +(export bogus-substring-spec? read-string/partial hunk ./rw.scm 23 -(define (generic-read-string!/partial s start end reader source) - (if (bogus-substring-spec? s start end) - (error "Bad substring indices" reader source s start end)) - - (if (= start end) 0 ; Vacuous request. - (let loop () - (catch 'system-error - (lambda () - (let ((nread (reader s source start end))) - (and (not (zero? nread)) nread))) - (lambda args - (let ((err (car (list-ref args 4)))) - (cond ;; ((= err errno/intr) (loop)) ; handled by primitive. - ((or (= err errno/wouldblock); No forward-progess here. - (= err errno/again)) - 0) - (else (apply scm-error args))))))))) - -(define (read-string!/partial s . args) - (let-optionals args ((fd/port (current-input-port)) - (start 0) - (end (string-length s))) - (generic-read-string!/partial s start end - uniform-array-read! - fd/port))) -