[jira] Commented: (LUCENE-460) hashCode improvements

2005-12-23 Thread Yonik Seeley (JIRA)
[ http://issues.apache.org/jira/browse/LUCENE-460?page=comments#action_12361200 ] Yonik Seeley commented on LUCENE-460: - Some people have asked where some of the magic constants come from in the hashCodes: python -c import random;print

[jira] Commented: (LUCENE-460) hashCode improvements

2005-10-31 Thread paul.elschot (JIRA)
[ http://issues.apache.org/jira/browse/LUCENE-460?page=comments#action_12356432 ] paul.elschot commented on LUCENE-460: - For example, TermQuery(t) and SpanTermQuery(t) will generate the exact same hash codes. I'm sorry, I misread this as an

[jira] Commented: (LUCENE-460) hashCode improvements

2005-10-30 Thread Yonik Seeley (JIRA)
[ http://issues.apache.org/jira/browse/LUCENE-460?page=comments#action_12356325 ] Yonik Seeley commented on LUCENE-460: - A couple of guidelines off the top of my head... - hash codes should strive to be unique across the Query hierarchy, not just

[jira] Commented: (LUCENE-460) hashCode improvements

2005-10-30 Thread Yonik Seeley (JIRA)
[ http://issues.apache.org/jira/browse/LUCENE-460?page=comments#action_12356326 ] Yonik Seeley commented on LUCENE-460: - Oh, and preserve entropy by using reversible integer hash functions (see the previous link). - key ^= (key a) | (key b); for

[jira] Commented: (LUCENE-460) hashCode improvements

2005-10-30 Thread paul.elschot (JIRA)
[ http://issues.apache.org/jira/browse/LUCENE-460?page=comments#action_12356384 ] paul.elschot commented on LUCENE-460: -  - hash codes should strive to be unique across the Query hierarchy, not just unique within one specific subclass. For example,