On Sat, Oct 27, 2012 at 8:19 AM, Tim <tram...@gmail.com> wrote:

> While playing around with a little test website I came across what, I
> believe to be a bug in the CLJS compiler.  It seems like the generation of
> symbols for use in macros (e.g. var#) is broken when compiled into certain
> JavaScript forms.
>
> This is a bit of a contrived example but it illustrates the point.
>
> This is my-website.macros file:
>
> (ns my-website.macros)
>
> (defmacro defalert [name n]
>   `(let [i# ~n]
>      (defn ~name []
>        (js/alert i#))))
>

Top level lets are currently problematic. There's a already a ticket for
this issue in JIRA - http://dev.clojure.org/jira/browse/CLJS-401

David

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