In place of (s/both long (s/pred odd?)) you can do (s/conditional odd? long), but (s/constrained long odd?) probably provides better error messages (since it validates long before odd?). I think there are some examples in the readme.
If this isn't what you're looking for, can you please provide some more details of your use case? Thanks, Jason On Sunday, March 6, 2016 at 5:38:35 AM UTC+5:30, JvJ wrote: > > > I've noticed that there is the function "both" in Schema. > > Both says that it can be replaced by conditional, but I'm not sure exactly > how to go about doing this. > > Can someone provide an example? > > Thanks > -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email to [email protected] Note that posts from new members are moderated - please be patient with your first post. To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/clojure?hl=en --- You received this message because you are subscribed to the Google Groups "Clojure" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
