On Wed, Oct 27, 2010 at 9:17 AM, Hanno Schlichting <ha...@hannosch.eu> wrote: > On Mon, Oct 25, 2010 at 11:51 PM, Jim Fulton <j...@zope.com> wrote: >> I'm inclined to treat the use of the comparison operator inherited >> from object in BTrees to be a bug. I plan to fix this on the >> trunk. > > Did you mean to throw warnings for simple built-in types?
No. > I'm now getting warnings for simple strings and ints, I'd expect > tuples as well. That's odd. I'm not. What platform and Python version? Can you give some examples? > All of these do inherit from object and use the > default __cmp__. I'm not sure what you mean by "these", but strings, int, and tuples certainly don't use the default comparison. If they did, sorting on them would be useless. > But their hash implementation used in the default > __cmp__ should be safe to use. Strings, ints and tuples don't use hash for comparison. Jim -- Jim Fulton _______________________________________________ For more information about ZODB, see the ZODB Wiki: http://www.zope.org/Wikis/ZODB/ ZODB-Dev mailing list - ZODB-Dev@zope.org https://mail.zope.org/mailman/listinfo/zodb-dev