Comment made by: jcr
Please use sumtypes instead of "magic" values to indicate failure or success. For example,
(s/conform any? ::s/invalid) ;=> [:ok ::s/invalid]
(s/conform int? ::s/invalid) ;=> [:failure #::s{:problems ... :spec ... :value ...}]
Note that the return value should be an instance of clojure.lang.MapEntry, in order for {{key}} and {{val}} to work on it. However, if it's not desirable to return the explain-map on failure then returning vectors {{[:ok value]}} and {{[:failure]}} (no second element) would work as well.
Since spec is explicitly in alpha, it's not too late yet to fix the api.
Related: CLJ-2115