By watching (println) the experiment we influence the outcome. Is the Schrodinger's cat present in Clojure?
This example program that shows how printing a value can change the value under specific circumstances. It seems the case that it has to do with the lazy evaluation that happen in Clojure. Basically I map a pr-str over a list. When I print the list before realization it seems that println is modifies the value. Doing a doall or turning the lazy-list into a vector makes the circumvents the issue. The code showing this behavior is is attached. Loading the file will show the issue. I've tested it in Clojure 1.5.1, Clojure 1.6.0. I also tested it in Clojure-clr 1.5.0, and observed the same issue. Please let me know whether this is expected behavior, a known issue, or a new one. Cees. -- 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.
issue.clj
Description: Binary data