On Sun, Nov 30, 2008 at 8:26 PM, Joel L <[EMAIL PROTECTED]> wrote: > > Thanks! This is actually kinda close to a solution that I've just > managed to come up with, though mine is somehow twice as long :). > Correct me if I'm wrong, but this could eat up the stack when parsing > a large document? I'm totally fine with it for my current needs, > though I'm curious to see a solution that doesn't.
Yes, "deep" documents could overflow the stack. In general as long as the stack depth mimics the actual depth of something else (like the document) vs. translating iterations into stack depth, you'll be okay. That's no promise, of course, but building a nested structure like this using only tail recursion sounds messier than I'd like to deal with at the moment. :-) --Chouser --~--~---------~--~----~------------~-------~--~----~ 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 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 -~----------~----~----~----~------~----~------~--~---