I think in my case here the easiest thing will be to remove the cycles, but still I'd like to understand a couple things...
On Sunday, July 23, 2017 at 10:12:46 PM UTC-4, Didier wrote: > > I'm not sure I can fully help without you explaining more what you're > doing. It sounds like you've got a collection or container type which has > an implementation of print that loops over its elements, and calls print on > them. So if you have a cycle, the print will go on forever until memory > runs out. > My container type (the tree node) is simply the standard clojure map. If you're using a standard type, you might be able to limit *print-level* > <https://clojuredocs.org/clojure.core/*print-level*>. Most Clojure > collections will limit how deep they print based on the value of this > global dynamic Var. > Okay, *print-level* works but it looks like I have to call print myself. I can't rely on the REPL to print it. (binding [*print-level* 2] (println (find-route "/reports"))) ; okay Why does `alter-var-root` here seem to succeed, but have no effect? (alter-var-root #'*print-level* (constantly 2)) => 2 *print-level* => nil (find-route "/reports") stack overflow -- 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.