That's right. This happens is because collection classes' toString implementations currently delegate to RT.printString, which in turn is affected by the value of *print-readably*.
Filed https://dev.clojure.org/jira/browse/CLJ-2248 with a fix. Cheers, Michał On 18 September 2017 at 03:08, Justin Smith <noisesm...@gmail.com> wrote: > my simplified reproduction of the issue: > > +user=> (let [mk-str (fn [] (lazy-seq [(str ["ZiZi"])])) > a (mk-str) > b (mk-str)] > (print-str a) > (pr-str b) > [a b]) > [("[ZiZi]") ("[\"ZiZi\"]")] > > isn't *print-readably* the difference between pr-str and print-str? > > On Sun, Sep 17, 2017 at 5:59 PM Didier <didi...@gmail.com> wrote: > >> Lazy sequences cache their values after the first time they are >> evaluated. Since print alters the output of str by binding *print-readably* >> to false, and also forces the sequence to realize itself, the values in >> your sequence are now cached the the result of str without >> *print-readably*. In subsequent calls to the sequence, you get the cache >> results, so even if you change the setting of *print-readably* it doesn't >> do anything. >> >> Either make sure that when you first access elements of the sequence, the >> bindings are the way you want str to be configured, or have the bindings >> set inside the lazy-seq. >> >> -- >> You received this message because you are subscribed to the Google >> Groups "Clojure" group. >> To post to this group, send email to clojure@googlegroups.com >> Note that posts from new members are moderated - please be patient with >> your first post. >> To unsubscribe from this group, send email to >> clojure+unsubscr...@googlegroups.com >> 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 clojure+unsubscr...@googlegroups.com. >> For more options, visit https://groups.google.com/d/optout. >> > -- > You received this message because you are subscribed to the Google > Groups "Clojure" group. > To post to this group, send email to clojure@googlegroups.com > Note that posts from new members are moderated - please be patient with > your first post. > To unsubscribe from this group, send email to > clojure+unsubscr...@googlegroups.com > 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 clojure+unsubscr...@googlegroups.com. > For more options, visit https://groups.google.com/d/optout. > -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to clojure@googlegroups.com Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to clojure+unsubscr...@googlegroups.com 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 clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/d/optout.