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

0 votes
in Clojure by

When spec'ing some things, I've used any? in a few cases where it is overly permissive. In particular, sometimes I need to specify a value must be printable/readable, such as when a value may wind up in an edn file. Similarly, I've needed to spec something must have non-generative value-identity, ie. ban closures, etc. Printable/readable or simply edn? would be a much better approximation than any?.

3 Answers

0 votes
by

Comment made by: bbloom

I realize that an edn? predicate would have O(N) runtime, vs an edn spec that could take advantage of every/every-kv etc for sampling conformance.

0 votes
by

Comment made by: bendlas

Related: CLJ-1527

0 votes
by
Reference: https://clojure.atlassian.net/browse/CLJ-2083 (reported by bbloom)
...