1. 30 Agu, 2004 3 kayıt (commit)
    • Raymond Hettinger's avatar
      Teach the random module about os.urandom(). · 356a4599
      Raymond Hettinger yazdı
      * Use it for seeding when it is available.
      * Provide an alternate generator based on it.
      356a4599
    • Tim Peters's avatar
      long_pow(): Fix more instances of leaks in error cases. · cd97da3b
      Tim Peters yazdı
      Bugfix candidate -- although long_pow() is so different now I doubt a
      patch would apply to 2.3.
      cd97da3b
    • Tim Peters's avatar
      SF patch 936813: fast modular exponentiation · 47e52ee0
      Tim Peters yazdı
      This checkin is adapted from part 2 (of 3) of Trevor Perrin's patch set.
      
      BACKWARD INCOMPATIBILITY:  SHIFT must now be divisible by 5.  AFAIK,
      nobody will care.  long_pow() could be complicated to worm around that,
      if necessary.
      
      long_pow():
        - BUGFIX:  This leaked the base and power when the power was negative
          (and so the computation delegated to float pow).
        - Instead of doing right-to-left exponentiation, do left-to-right.  This
          is more efficient for small bases, which is the common case.
        - In addition, if the exponent is large (more than FIVEARY_CUTOFF
          digits), precompute [a**i % c for i in range(32)], and go left to
          right 5 bits at a time.
      l_divmod():
        - The signature changed so that callers who don't want the quotient,
          or don't want the remainder, can pass NULL in the slot they don't
          want.  This saves them from having to declare a vrbl for unwanted
          stuff, and remembering to decref it.
      long_mod(), long_div(), long_classic_div():
        - Adjust to new l_divmod() signature, and simplified as a result.
      47e52ee0
  2. 29 Agu, 2004 11 kayıt (commit)
  3. 28 Agu, 2004 3 kayıt (commit)
  4. 27 Agu, 2004 12 kayıt (commit)
  5. 26 Agu, 2004 11 kayıt (commit)