You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As a random thought, defn-spec being a superset of defn would open some interesting doors.
One could refactor codebases to bulk-rename defn to defn-spec, resulting in a more homogeneous codebase (seeing interspersed defn/defn-spec calls is ugly), and inviting one to spec more stuff (assuming a warning approach as outlined above).
Brief
defn-spec
could be a superset ofdefn
, but it isn't, and also not in a very informative manner:IOW,
find not supported on type: clojure.lang.Keyword
is not the best message one can find when writing a defn-spec using "muscle memory" from defn.Fix
I'd suggest at least one of the following:
any?
, possibly emitting a warning. All of this could be configurable behavior.No :ret spec supplied. Did you forget to add a spec after the function name?
No :args spec supplied for the last parameter. Did you forget to add a spec after the last parameter?
WDYT?
Cheers - Victor
The text was updated successfully, but these errors were encountered: