While most of the functions and macros in Clojure core with a ? at the end
take 1 arg, there are several that take two:

contains? every? extends? identical? instance? not-any? not-every?
satisfies?

That list might not be complete.  But you would not be breaking any
traditions I know of to have multi-argument predicate functions.

Andy


On Fri, Jan 31, 2014 at 8:44 AM, Ryan <arekand...@gmail.com> wrote:

> Hello,
>
> I am wondering if all my predicates should be one argument functions
> because I run into a couple of cases where I needed more than one.
>
> For example, I have a function called valid-params? which takes two
> parameters; the validator to use and a maps parameter.
> Is this approach wrong/not the clojure way?
>
> What are my alternatives? Should I just use a different function name
> which does not have a question mark at the end that implies that is a
> predicate?
>
> Cheers,
>
> Ryan
>
> --
> You received this message because you are subscribed to the Google
> Groups "Clojure" group.
> To post to this group, send email to clojure@googlegroups.com
> Note that posts from new members are moderated - please be patient with
> your first post.
> To unsubscribe from this group, send email to
> clojure+unsubscr...@googlegroups.com
> 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 clojure+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/groups/opt_out.
>

-- 
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to clojure@googlegroups.com
Note that posts from new members are moderated - please be patient with your 
first post.
To unsubscribe from this group, send email to
clojure+unsubscr...@googlegroups.com
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 clojure+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to