On Dec 3, 4:15 am, lazy1 <miki.teb...@gmail.com> wrote:
> Hello,
> What is the right way to do this?

As people have mentioned, new is a special form which evaluates it's
arguments at
compile time and cannot be used with a dynamic class name.

Fortunately you can use the reflection API and create instance of your
class
 using the newInstance method.

(defn new-container
  [type]
  (.newInstance (*containers* type)))


- sean

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