3 ms·
> But if the official spec doesn’t restrict get, Spec will let people redefine the spec for get for themselves. > They can choose whatever subset of the type t
by al2o3cr 8y ago
> But if the official spec doesn’t restrict get, Spec will let people redefine the spec for get for themselves.
> They can choose whatever subset of the type they want.
Total clojure-spec noob question: is this type scoped somehow, or does using your own type mean chasing down bugs in libraries that assume a looser version?
- puredanger 8y agoIt's scoped in that you choose what gets loaded. I think it's generally a good idea for a library to provide specs as an optional namespace and let you choose whether and when to load it.
- ajss 8y agoSpecs are not scoped. There's a global registry. You may end up chasing other people's bugs.