Hello,

I noticed the following:

> (hash 0)
0
> (hash nil)
0

Which is fair enough I suppose. It seems to have the following side-effect 
though:

> (hash [1 2 3 0])
955327
> (hash [1 2 3 nil])
955327

Is that the intended behaviour? I suppose it's OK for two things to hash to 
the same value, but IMHO, it would make the hash function more useful to 
avoid this simple case. The implementation seems to check for nil 
specifically and to return 0.

Thanks,

Stathis

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

Reply via email to