On Dec 11, 2012, at 11:40 AM, Marshall Bockrath-Vandegrift wrote:
> 
>> Or have I missed a currently-available work-around among the many
>> suggestions?
> 
> You can specialize your application to avoid megamodal call sites in
> tight loops.  If you are working with `Cons`-order sequences, just use
> `cons` instead of `conj`.  If you are working with vectors, create your
> own private implementation of `conj` which you *only* call on vectors.
> If you are depending on operations which may/do use `conj` in tight
> loops, create your own private re-implementations which don’t, such as
> with any of the faster versions of `reverse` earlier in this thread.
> 
> This is suboptimal, but it’s totally possible to work around the issue
> with a little bit of analysis and profiling.

Very informative. Thanks and thanks also to Gary.

If the application does lots of "list processing" but does so with a mix of 
Clojure list and sequence manipulation functions, then one would have to write 
private, list/cons-only versions of all of these things? That is -- overstating 
it a bit, to be sure, but perhaps not entirely unfairly -- re-implement 
Clojure's Lisp? 

 -Lee

-- 
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

Reply via email to