On Feb 28, 2013, at 17:17 , AtKaaZ <atk...@gmail.com> wrote:

> According to this, can a vector have keys that are not numbers? like :a , if 
> not, then wouldn't it make more sense that
> (contains? [:a :b :c] :a)  would throw ? It's probably just me.

This is a reasonable point, and one I haven't seen made before. The only 
problem I can see with throwing an exception is that one might sometimes wish 
to deal with associative containers in a generic fashion, and thus end up 
asking a vector if it contains a keyword or a string without doing so 
explicitly. In that case you'd not want it to throw an exception any more than 
the other associative collection types would.

-- 
-- 
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