Hi,everyone! I'm a newbie here.When I'm reading Mark Volkmann's Tutorial,i make a mistake by binding a non-dynamic var 'x' to new value.Then I def 'x' with ^:dynamic again,but in this line (binding [x 9] (foo)), the function 'foo' ignore the binding.Why? Thanks for reply!!!
uer=> (def x 0) #'user/x user=> (defn foo [] (println x)) #'user/foo user=> (foo) 0 nil user=> (def ^:dynamic x 1) #'user/x user=> (foo) 1 nil user=> (binding [x 9] (println x)) 9 nil user=> (binding [x 9] (foo)) 1 nil -- 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