Fork me on GitHub

can macro spec checking (for core macros) be disabled from the REPL instead of with a Java property?

Alex Miller (Clojure team)14:04:40

not currently. such a thing could be done by just setting the clojure.lang.RT/CHECK_SPECS flag, but that's not public currently


Is there any reason why the clojure.spec.skip-macros isn't re-loaded dynamically in Compiler every time it's needed? Performance?

Alex Miller (Clojure team)16:04:25

Didn’t seem necessary

👍 4
Alex Miller (Clojure team)14:04:02

you could remove those specs from the registry

Alex Miller (Clojure team)14:04:21

s/def with nil will remove


I tried (clojure.spec.alpha/def clojure.core/for nil) already, but that didn’t do it


oh it does work, sorry


I was testing if for supported beginning with a let but it doesn’t 🙂

(for [:let [x 1] y (range x)] y)


and I wanted to make sure I wasn’t getting an error from the spec. thanks


I dunno if nit picking on spec-alpha2 is useful feedback yet, but is checking if an object implements the interface behind the Schema protocol instead of checking for satisfying the Schema protocol (the namespace imports the interface behind the Spec and the Schema protocols, but is careful to use the Spec protocol everywhere and not the interface)

Alex Miller (Clojure team)21:04:34

Yeah, that’s actually intentional for perf, same in spec 1


ah, I see, I missed the use of the interface there. and it looks like spec? will return true if you implement the interface, or if you have metadata with the conform* function(satisfy the protocol via metadata), but will return false if you extend the protocol to some type, which seems idiosyncratic


I guess I'll stay tuned

Alex Miller (Clojure team)22:04:56

In any case, I’m aware :)