1. 13 Nis, 2006 3 kayıt (commit)
  2. 12 Nis, 2006 31 kayıt (commit)
  3. 11 Nis, 2006 6 kayıt (commit)
    • Thomas Wouters's avatar
      Fix int() and long() to repr() their argument when formatting the exception, · 9cb28bea
      Thomas Wouters yazdı
      to avoid confusing situations like:
      
      >>> int("")
      ValueError: invalid literal for int():
      >>> int("2\n\n2")
      ValueError: invalid literal for int(): 2
      
      2
      
      Also report the base used, to avoid:
      
      ValueError: invalid literal for int(): 2
      
      They now report:
      
      >>> int("")
      ValueError: invalid literal for int() with base 10: ''
      >>> int("2\n\n2")
      ValueError: invalid literal for int() with base 10: '2\n\n2'
      >>> int("2", 2)
      ValueError: invalid literal for int() with base 2: '2'
      
      (Reporting the base could be avoided when base is 10, which is the default,
      but hrm.) Another effect of these changes is that the errormessage can be
      longer; before, it was cut off at about 250 characters. Now, it can be up to
      four times as long, as the unrepr'ed string is cut off at 200 characters,
      instead.
      
      No tests were added or changed, since testing for exact errormsgs is (pardon
      the pun) somewhat errorprone, and I consider not testing the exact text
      preferable. The actually changed code is tested frequent enough in the
      test_builtin test as it is (120 runs for each of ints and longs.)
      9cb28bea
    • Vinay Sajip's avatar
      StreamHandler now checks explicitly for None before using sys.stderr as the… · 502348d0
      Vinay Sajip yazdı
      StreamHandler now checks explicitly for None before using sys.stderr as the stream (see SF bug #1463840).
      502348d0
    • Tim Peters's avatar
      _Py_PrintReferenceAddresses,_Py_PrintReferences: · cbd6f189
      Tim Peters yazdı
      interpolate PY_FORMAT_SIZE_T for refcount display
      instead of casting refcounts to long.
      
      I understand that gcc on some boxes delivers
      nuisance warnings about this, but if any new ones
      appear because of this they'll get fixed by magic
      when the others get fixed.
      cbd6f189
    • Andrew M. Kuchling's avatar
      Complete the ElementTree section · 075e0231
      Andrew M. Kuchling yazdı
      075e0231
    • Anthony Baxter's avatar
    • Anthony Baxter's avatar
      more low-hanging fruit to make code compile under a C++ compiler. Not · 7b782b61
      Anthony Baxter yazdı
      entirely happy with the two new VISIT macros in compile.c, but I
      couldn't see a better approach.
      7b782b61