[Python-checkins] python/dist/src/Lib UserDict.py,1.24,1.24.10.1

theller at users.sourceforge.net theller at users.sourceforge.net
Thu Dec 4 16:07:59 EST 2003


Update of /cvsroot/python/python/dist/src/Lib
In directory sc8-pr-cvs1:/tmp/cvs-serv10333

Modified Files:
      Tag: release23-maint
	UserDict.py 
Log Message:
Backported from the trunk, on Raymond's request:

SF bug #849662.  Dramatically, improve comparison speed for "if shl == None".


Index: UserDict.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/UserDict.py,v
retrieving revision 1.24
retrieving revision 1.24.10.1
diff -C2 -d -r1.24 -r1.24.10.1
*** UserDict.py	6 Mar 2003 23:54:27 -0000	1.24
--- UserDict.py	4 Dec 2003 21:07:57 -0000	1.24.10.1
***************
*** 156,159 ****
--- 156,161 ----
          return repr(dict(self.iteritems()))
      def __cmp__(self, other):
+         if other is None:
+             return 1
          if isinstance(other, DictMixin):
              other = dict(other.iteritems())





More information about the Python-checkins mailing list