Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- (s/def ::foo (s/cat :f #{'foo} :arg number?))
- ;; gen/generate produces something like '(foo 42), like expected
- ;; nonetheless, s/valid? says true if ['foo 42], which isn't a list expressing a call to 'foo, what we want
- ;; unfortunately (s/and seq? ...) in the definition kills the automatic generation
- ;; (s/and ... seq?) doesn't work for validation because s/and conforms the value and pass it to the next predicate
- ;; any solution ?
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement