I still find this confusing, but thanks for the quick response.

> In general, you should use uniform types for hash keys.

I thought I was using all ints, but it turns out that a java API
returned a long when I thought it returned an int. So then my map had
some keys that were ints and some that were long, and some lookups
failed, based on whether the keys were in the code path that returned
ints vs. the code path that returned longs.

What if ints and longs had different literal syntax, i.e. 42 vs. 42L?
In my example above, if you take that map, write it to a string and
then read it back, the behavior would be different. In the original,
the key is a long, and in the reconstituted version, it would be an
int, right?

Allen


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

Reply via email to