On May 1, 9:53 am, Christophe Grand <christo...@cgrand.net> wrote:
> Julien a écrit :
>
> > Here is a quick newbie question.
>
> >    (def test1 "test1")
> >    (let [test2 "test2"]
> >            (eval (read-string "(println test1)"))
> >            (eval (read-string "(println test2)"))
> >    )
>
> > -output
> >    test1
> >    1:1 user=> java.lang.Exception: Unable to resolve symbol: test2 in
> > this context (testLet.clj:0)
>
> > How could (read-string "") access to a binding local to a form?
>
> read-string doesn't care about the context, it reads a string and
> returns the data structure represented by this string, it knows nothing
> about which vars are interned in which namespace, which symbols denote
> locals etc.
>

That's not completely true - the reader is context-aware for syntax-
quote and ::

Rich

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