I have a value and a string. The string contains valid Clojure code and it 
mentions a variable. I'd like to let-bind that variable to the value and 
then evaluate the string. Can this be done?

As a small example, I thought this would work: (let [a 0] (eval 'a)))

Or maybe this: 
user> (let [a 0] (eval 'user/a))

My initial attempt was this: (let [a 0] (eval (read-string "a")))

These all result in an exception...

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