• Raymond Hettinger's avatar
    * Add short-circuit code for in-place operations with self (such as · c991db24
    Raymond Hettinger yazdı
      s|=s, s&=s, s-=s, or s^=s).  Add related tests.
    
    * Improve names for several variables and functions.
    
    * Provide alternate table access functions (next, contains, add, and discard)
      that work with an entry argument instead of just a key.  This improves
      set-vs-set operations because we already have a hash value for each key
      and can avoid unnecessary calls to PyObject_Hash().  Provides a 5% to 20%
      speed-up for quick hashing elements like strings and integers.  Provides
      much more substantial improvements for slow hashing elements like tuples
      or objects defining a custom __hash__() function.
    
    * Have difference operations resize() when 1/5 of the elements are dummies.
      Formerly, it was 1/6.  The new ratio triggers less frequently and only
      in cases that it can resize quicker and with greater benefit.  The right
      answer is probably either 1/4, 1/5, or 1/6.  Picked the middle value for
      an even trade-off between resize time and the space/time costs of dummy
      entries.
    c991db24
Adı
Son kayıt (commit)
Son güncelleme
Demo Loading commit data...
Doc Loading commit data...
Grammar Loading commit data...
Include Loading commit data...
Lib Loading commit data...
Mac Loading commit data...
Misc Loading commit data...
Modules Loading commit data...
Objects Loading commit data...
PC Loading commit data...
PCbuild Loading commit data...
Parser Loading commit data...
Python Loading commit data...
RISCOS Loading commit data...
Tools Loading commit data...
.cvsignore Loading commit data...
.hgtags Loading commit data...
LICENSE Loading commit data...
Makefile.pre.in Loading commit data...
README Loading commit data...
aclocal.m4 Loading commit data...
configure Loading commit data...
configure.in Loading commit data...
install-sh Loading commit data...
pyconfig.h.in Loading commit data...
setup.py Loading commit data...