Hi Graham 2009/11/20 Graham Fawcett <graham.fawc...@gmail.com>: > Hi folks, > > This is somewhat a Java question, but it's in the context of Clojure, > so here goes. Playing with Leiningen got me thinking about bundling a > Clojure application as a JAR, which might include a host of classes > that are loaded but never used. Is it possible to "tree-shake" such a > jarfile, and eliminate any classes that are not required for the > main-class' operation? (Assuming the program doesn't need 'eval' with > access to all of those classes at runtime.) > > This might not save a lot of startup time, but where startup time > matters, maybe it might shave off a meaningful fraction. I'm just > curious whether there is enough dependency information in a set of > class files to calculate a tree-shaking plan; and whether there are > existing tools to do the job.
I might have misunderstood, but isn't the problem the same as in Java; you can't know from a static analysis which classes are going to be loaded? Best regards, jim -- 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