[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Problem with truncated string ports - more info
From: |
Mike Gran |
Subject: |
Re: Problem with truncated string ports - more info |
Date: |
Fri, 21 Jun 2013 08:25:53 -0700 (PDT) |
>However, if I make the input string 4095 bytes long,
> then I do not get the expected 4097 long output string.
> Instead, I get a resulting string truncted to 4096 bytes.
>
> (define s (make-string 4095 #\x))
> (string-length (with-output-to-string (lambda () (write s))))
>; answer 4096 - WRONG.
Weird. There are some 4k blocks in the R6RS port code, so
it might be there.
If you do the following string dump, does it say that the string's
stringbuf-length is also 4096?
(define s (make-string 4095 #\x))
(%string-dump (with-output-to-string (lambda () (write s))))
-Mike