-
Notifications
You must be signed in to change notification settings - Fork 790
Bootstrapping the Compiler
DEPRECATION NOTICE: Please do not edit this wiki. Instead submit pull requests to https://github.com/clojure/clojurescript-site
The up to date version of this page can be found at https://clojurescript.org/reference/bootstrapping
See https://github.com/swannodette/cljs-bootstrap
Current status:
-
ClojureScript can now compile both its analyzer & compiler w/o errors. Can eval non-trivial ClojureScript exprs from within the JS host.
-
Performance reading, analysis & compilation within bootstrapped ClojureScript has been optimized to be roughly within a factor of 2 of ClojureScript JVM (varying perf between engines).
-
Master is successfully being used in various contexts:
- cljs-bootstrap
- Node.js REPL
- Browser REPL
- iOS REPL: Replete
- Android REPL: Replicator
- Desktop REPL: Planck
- QuilFiddle
- SessionRepl
- Threejs playground
- Library for bootstrapped REPLs: Replumb
- A clojurescript web repl: KLIPSE
- Desktop REPL: Lumo
- Embeddable clojurescript repl: KLIPSE plugin
- Musical live coding environment: Klangmeister
The following enumerates the remaining tasks:
- Ensure perf is good.
- Ensure defects are addressed. Many have
bootstrap
label: JIRA Query - Determine if shared bootstrap REPL code will be included and implement.
* you can use the CLJS API reference to help identify imported macros and related Clojure types
As a point of reference, https://github.com/kanaka/clojurescript is a previous project to bootstrap the ClojureScript compiler. It is fairly dated since it was forked from the main tree on Nov 16th, 2012, however, it was self-hosting and allowed for a fully browser-based REPL (original version of http://clojurescript.net/). A presentation of the project from Clojure West 2013 is here: http://www.infoq.com/presentations/cljs-in-cljs
- Rationale
- Quick Start
- Differences from Clojure
- [Usage of Google Closure](Google Closure)