Compiler Exception on Clojure 1.11.1 - No matching clause: :static-field
AdamFrey opened this issue · 2 comments
AdamFrey commented
Hi,
I'm running into a compiler exception from missionary / cloroutine when upgrading an application from Clojure 1.10.3 to Clojure 1.11.1. I've pared down the code I'm working with to a minimal reproduction case.
;; missionary b.26
;; clojure 1.11.1
(m/ap
(let [{:keys [id]} (m/?= (m/seed [{:id 123} {:id 234}]))]
id))
;; Unhandled clojure.lang.Compiler$CompilerException
;; Caused by java.lang.IllegalArgumentException
;; No matching clause: :static-field
;; cloroutine.impl 472
on clojure 1.10.3 this code compiles and the code seems to work as I hope.
ognen commented
I am experiencing the same with the following code:
(defn- run-resolutions [resolutions]
(m/ap
(let [{:keys [thunk] :as resolution} (m/?= (m/seed resolutions))]
(assoc resolution :result (m/? thunk)))))
Also Clojure 1.11.1
Noticing that, compilation passes if I remove the map destructuring in the let clause:
(defn- run-resolutions2 [resolutions]
(m/ap
(let [res (m/?= (m/seed resolutions))]
(assoc res :result (m/? ((:thunk res)))))))
leonoel commented
Fixed in b.27