Ummm... Jean, I don't understand. Recapitulation. As Herwig showed, the symbol has its metadata WITHOUT evaluation:
user=> (meta (second (read-string "(def ^{:key (+ 1 1)} foo)"))) {:key (+ 1 1)} "second", in the above expression, retrieves the symbol "foo", and reader already set its metadata WITHOUT evaluation. AFAIK, def is an special form (a built-in one? not a defined macro?), so, it receives the symbol, foo, as is, without evaluating it, nor its metadata, nothing more. No lisp evaluator yet. Something inside def work, ACTIVELY get the symbol metadata, AND EVALUATES it, and assign it to the var the def is defining. AFAIK, getting the metadata of something, doesn't imply automatically its evaluation, as Herwig example shows us. This interpretation is aligned with: http://clojure.org/special_forms Any metadata on the symbol will be evaluated, and become metadata on the var itself that explicitly asserts that some evaluation will be conducted. Am I right? Angel "defandmetadata" Lopez :-) On Tue, Mar 19, 2013 at 12:16 PM, Jean Niklas L'orange < jeann...@hypirion.com> wrote: > > > On Tuesday, March 19, 2013 11:49:45 AM UTC+1, ajlopez wrote: >> >> Thanks Jean! >> >> Yes, I did that test before my email. >> >> But my doubt is: >> >> What part is in charge of metadata evaluation? >> > > As Herwig commented: The part which evaluates metadata is without doubt > the lisp evaluator's work, the def macro does nothing magical here. > > A simple test to ensure that follows: > (meta ^{:a (+ 1 1)} [:a :b]) > ;=> {:a 2} > > -- > -- > 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 > --- > You received this message because you are subscribed to the Google Groups > "Clojure" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to clojure+unsubscr...@googlegroups.com. > For more options, visit https://groups.google.com/groups/opt_out. > > > -- -- 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 --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to clojure+unsubscr...@googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.