On Thursday, 5 March 2015 05:31:49 UTC+10, Stuart Sierra  wrote:
Thanks to all for the replies.

Stuart, I wasn't thinking about self-hosting; merely about unifying the 
experience under Clojure and ClojureScript, wrt macros.  Some work has already 
been done towards this, and I was wondering whether it were feasible to 
integrate defmacro into the CLJS compiler.  I thought there may be subtleties 
around the fact that CLJS appears to be an essentially AoT environment.

In the event that there are no structural impediments, we might look forward to 
such a full integration of defmacro some time down the track.  I think it would 
be a boon for the wider acceptance of CLJS.

> On March 3, 2015, Peter West wrote:
> > Macros eventually all expand to CLJS-compatible code.
> > Currently, IIUC, both macro definition and expansion are
> > handled by the Clojure compiler, with the resulting code
> > (presumably CLJS compatible) being handed back to the
> > ClojureScript compiler. Was this simply a convenience to
> > get CLJS working with a minimum of fuss, or are there some
> > structural impediments?
> 
> 
> Mostly, I think, it was the quickest path to bootstrap the
> ClojureScript compiler. Clojure already had a reader and
> macro expander, so ClojureScript used them.
> 
> In Rich Hickey's original design, ClojureScript was not
> intended to be self-hosting without the JVM. The past few
> years of work have brought ClojureScript closer to the
> *possibility* of self-hosting, but it hasn't been a priority
> for most of the major contributors.
> 
> -S

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/clojurescript.

Reply via email to