Open frenchy64 opened 2 years ago
Another idea, but unfortunately it doesn't work:
user=> (letfn* [f ^:a (fn f [])] (meta f))
CompilerException java.lang.ClassCastException: class clojure.lang.Compiler$MetaExpr cannot be cast to class clojure.lang.Compiler$ObjExpr (clojure.lang.Compiler$MetaExpr and clojure.lang.Compiler$ObjExpr are in unnamed module of loader 'app'), compiling:(/private/var/folders/s5/309818k92r92zn9c_nzvmnzc0000gn/T/form-init5989770558247704827.clj:1:1)
https://github.com/plumatic/schema/pull/430 revealed a faster way to support
s/fn-schema
via metadata. We should look into the performance improvements of using the same strategy fors/letfn
and then perhaps deprecateschematize-fn
.Idea: