Please file a jira enhancement. Changes could include updating the doc 
string, or adding a new arity to read-line that takes a size and passes it 
through to the buffered reader.

On Tuesday, September 26, 2017 at 6:28:26 AM UTC-5, 
[email protected] wrote:
>
> Hello there, 
>
> I was using read-line to read a large line and found it limits its input 
> to 4095 chars. I tested this on both Clojure 1.8.0 and 1.9.0-beta1. 
>
> Steps to reproduce: 
>
> $ lein new foo 
> $ cd foo 
> $ lein repl 
> ... 
> => (count (read-line)) 
>
> Then enter a line that’s longer than 4095 characters; I used 8000 a's. 
>
> Expected output: 
>
> 8000 
>
> Actual output: 
>
> 4095 
>
> No matter the real length of your input, it’ll always be truncated to 4095 
> chars if it’s longer. 
>
> This is not in the documentation so I assume it’s either an implementation 
> bug or a documentation miss. I wanted to know which one it is before trying 
> to fix it. 
>
> I’ve done some research and it appears to be a limitation of the 
> BufferedReader’s readLine method that uses a buffer of either 4k or 8k 
> depending on the implementation. Should we (1) work around this limit in 
> the code so that read-line does actually read a whole line or (2) just 
> update the documentation to note this limit?
>
> Thanks,
>
> -- Baptiste Fontaine
>

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to [email protected]
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
--- 
You received this message because you are subscribed to the Google Groups 
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to