Welcome! Please see the About page for a little more info on how this works.

0 votes
in Clojure by

The clojure.spec.test.alpha namespace in clojure.spec 0.3.214 namepace is still AOT-compiled using the locking macro from clojure 1.10.1:

<clojure.version>1.10.1</clojure.version>

https://github.com/clojure/spec.alpha/blob/a924efab53b0465f7d2a589d4ae3c79a3826403b/pom.xml#L39

https://github.com/clojure/spec.alpha/blob/a924efab53b0465f7d2a589d4ae3c79a3826403b/src/main/clojure/clojure/spec/test/alpha.clj#L363

This old locking macro is troublesome with GraalVM native image. See CLJ-1472.

I think if you compile clojure.spec with clojure 1.10.3 then you can just keep using locking and the old locking2 workaround can be removed over here:

https://github.com/clojure/spec.alpha/blob/a924efab53b0465f7d2a589d4ae3c79a3826403b/src/main/clojure/clojure/spec/gen/alpha.clj#L17

An alternative solution would be to also use the locking2 macro in clojure.spec.test.alpha.

1 Answer

0 votes
by

Released spec.alpha 0.3.218

by
Thank you! <3 <3
by
Can we also get a clojure bump for this version of spec to make sure it's not forgotten for the next alpha release?
by
That probably won’t happen until the next alpha
...