@dnolen implementing graaljs support via :target-fn
showed the need to allow outputting bootstrap files. would a change like this be acceptable? https://github.com/nextjournal/clojurescript/commit/a75b90c1eb67e5130549fda88e4495c5ee9c23b5
@kommen it's ok, it's a little subtle so maybe a comment in that code would be helpful for later readers
@kommen how do you use the graal stuff? do you use the Java API directly or via ScriptEngine
or just a regular command line script?
@thheller https://nextjournal.com/kommen/clojure-berlin-prosemirror-transforms-with-graalvm-and-clojure
@thheller I just noticed that since that post we also adopted the a shared Engine
api which allows graalvm cache jit compiler state between multiple execution Context
s. will update the post soon
all your CLJS code is basically sync and you just call it from CLJ? or do you have async handling somewhere?
we just do sync stuff with graal and leave the async parts to jvm clojure
@dnolen just found this still hardcoded for nashorn/graaljs: https://github.com/clojure/clojurescript/blob/master/src/main/cljs/cljs/core.cljs#L11708-L11709
but not sure how best to separate this out
@mfikes that the 0 arity get-js-index
calls through to arity 1 of get-options
looks odd. is this intended? https://github.com/clojure/clojurescript/commit/0f6d24669c95966d781f905d168f20bce9105bbe#diff-3f5db04e51ac4262a2042aa4d80010a2R73
Good catch @kommen, that code is incorrect.
(It should be calling get-js-index
)
I'll write up a JIRA and take care of it.
WooHoo awesome, GraalJS support for ClojureScript nice!