1. 03 May, 2000 1 kayıt (commit)
    • Guido van Rossum's avatar
      Vladimir Marangozov's long-awaited malloc restructuring. · b18618da
      Guido van Rossum yazdı
      For more comments, read the patches@python.org archives.
      For documentation read the comments in mymalloc.h and objimpl.h.
      
      (This is not exactly what Vladimir posted to the patches list; I've
      made a few changes, and Vladimir sent me a fix in private email for a
      problem that only occurs in debug mode.  I'm also holding back on his
      change to main.c, which seems unnecessary to me.)
      b18618da
  2. 10 Nis, 2000 1 kayıt (commit)
  3. 05 Nis, 2000 1 kayıt (commit)
    • Guido van Rossum's avatar
      Marc-Andre's third try at this bulk patch seems to work (except that · 9e896b37
      Guido van Rossum yazdı
      his copy of test_contains.py seems to be broken -- the lines he
      deleted were already absent).  Checkin messages:
      
      
      New Unicode support for int(), float(), complex() and long().
      
      - new APIs PyInt_FromUnicode() and PyLong_FromUnicode()
      - added support for Unicode to PyFloat_FromString()
      - new encoding API PyUnicode_EncodeDecimal() which converts
        Unicode to a decimal char* string (used in the above new
        APIs)
      - shortcuts for calls like int(<int object>) and float(<float obj>)
      - tests for all of the above
      
      Unicode compares and contains checks:
      - comparing Unicode and non-string types now works; TypeErrors
        are masked, all other errors such as ValueError during
        Unicode coercion are passed through (note that PyUnicode_Compare
        does not implement the masking -- PyObject_Compare does this)
      - contains now works for non-string types too; TypeErrors are
        masked and 0 returned; all other errors are passed through
      
      Better testing support for the standard codecs.
      
      Misc minor enhancements, such as an alias dbcs for the mbcs codec.
      
      Changes:
      - PyLong_FromString() now applies the same error checks as
        does PyInt_FromString(): trailing garbage is reported
        as error and not longer silently ignored. The only characters
        which may be trailing the digits are 'L' and 'l' -- these
        are still silently ignored.
      - string.ato?() now directly interface to int(), long() and
        float(). The error strings are now a little different, but
        the type still remains the same. These functions are now
        ready to get declared obsolete ;-)
      - PyNumber_Int() now also does a check for embedded NULL chars
        in the input string; PyNumber_Long() already did this (and
        still does)
      
      Followed by:
      
      Looks like I've gone a step too far there... (and test_contains.py
      seem to have a bug too).
      
      I've changed back to reporting all errors in PyUnicode_Contains()
      and added a few more test cases to test_contains.py (plus corrected
      the join() NameError).
      9e896b37
  4. 23 Ara, 1999 1 kayıt (commit)
    • Fred Drake's avatar
      long_format(): Now takes a third parameter, addL; iff true, a · 121ee272
      Fred Drake yazdı
                      trailing 'L' is appended to the representation,
                      otherwise not.
      
                      All existing call sites are modified to pass true for
                      addL.
      
                      Remove incorrect statement about external use of this
                      function from elsewhere; it's static!
      
      long_str():     Handler for the tp_str slot in the type object.
                      Identical to long_repr(), but passes false as the addL
                      parameter of long_format().
      121ee272
  5. 11 Eki, 1999 1 kayıt (commit)
  6. 27 Eyl, 1999 1 kayıt (commit)
  7. 27 Ock, 1999 1 kayıt (commit)
  8. 06 Ock, 1999 1 kayıt (commit)
  9. 09 Eki, 1998 1 kayıt (commit)
  10. 18 Eyl, 1998 1 kayıt (commit)
  11. 13 Eyl, 1998 1 kayıt (commit)
  12. 25 Agu, 1998 1 kayıt (commit)
  13. 11 Agu, 1998 1 kayıt (commit)
    • Guido van Rossum's avatar
      Two patches by Jason Harper: · bd3a527f
      Guido van Rossum yazdı
      - Faster conversion to string for binary bases: linear instead of quadratic!
      
      - Allocate smaller result for certain masking ops, e.g. (1L<<30000) & 1.
      bd3a527f
  14. 04 Agu, 1998 2 kayıt (commit)
  15. 22 Haz, 1998 1 kayıt (commit)
  16. 26 May, 1998 1 kayıt (commit)
    • Guido van Rossum's avatar
      Subject: Buglet in PyLong_AsLong · f7531812
      Guido van Rossum yazdı
      From: "Tim Peters" <tim_one@email.msn.com>
      To: "Guido van Rossum" <guido@CNRI.Reston.VA.US>
      Date: Sat, 23 May 1998 21:45:53 -0400
      
      Guido, the overflow checking in PyLong_AsLong is off a little:
      
      1) If the C in use sign-extends right shifts on signed longs, there's a
      spurious overflow error when converting the most-negative int:
      
      Python 1.5.1 (#0, Apr 13 1998, 20:22:04) [MSC 32 bit (Intel)] on win32
      Copyright 1991-1995 Stichting Mathematisch Centrum, Amsterdam
      >>> x = -1L << 31
      >>> x
      -2147483648L
      >>> int(x)
      Traceback (innermost last):
        File "<stdin>", line 1, in ?
      OverflowError: long int too long to convert
      >
      > 2) If C does not sign-extend, some genuine overflows won't be caught.
      >
      > The attached should repair both, and, because I installed a new disk and a C
      > compiler today, it's even been compiled this time <wink>.
      >
      > Python 1.5.1 (#0, May 23 1998, 20:24:58) [MSC 32 bit (Intel)] on win32
      > Copyright 1991-1995 Stichting Mathematisch Centrum, Amsterdam
      > >>> x = -1L << 31
      > >>> x
      > -2147483648L
      > >>> int(x)
      > -2147483648
      > >>> int(-x)
      > Traceback (innermost last):
      >   File "<stdin>", line 1, in ?
      > OverflowError: long int too long to convert
      > >>> int(-x-1)
      > 2147483647
      > >>> int(x-1)
      > Traceback (innermost last):
      >   File "<stdin>", line 1, in ?
      > OverflowError: long int too long to convert
      
      end-casing-ly y'rs  - tim
      f7531812
  17. 10 Nis, 1998 1 kayıt (commit)
  18. 02 May, 1997 1 kayıt (commit)
  19. 09 Nis, 1997 1 kayıt (commit)
  20. 16 Mar, 1997 1 kayıt (commit)
  21. 14 Mar, 1997 1 kayıt (commit)
  22. 14 Şub, 1997 1 kayıt (commit)
  23. 03 Ock, 1997 1 kayıt (commit)
  24. 05 Ara, 1996 1 kayıt (commit)
  25. 25 Eki, 1996 1 kayıt (commit)
  26. 04 Mar, 1995 1 kayıt (commit)
  27. 10 Şub, 1995 1 kayıt (commit)
  28. 17 Ock, 1995 1 kayıt (commit)
  29. 10 Ock, 1995 1 kayıt (commit)
  30. 04 Ock, 1995 1 kayıt (commit)
  31. 02 Ock, 1995 1 kayıt (commit)
  32. 28 Eyl, 1994 1 kayıt (commit)
    • Guido van Rossum's avatar
      * Include/classobject.h, Objects/classobject.c, Python/ceval.c: · 03093a24
      Guido van Rossum yazdı
      	entirely redone operator overloading.  The rules for class
      	instances are now much more relaxed than for other built-in types
      	(whose coerce must still return two objects of the same type)
      
      	* Objects/floatobject.c: add overflow check when converting float
      	to int and implement truncation towards zero using ceil/float
      
      	* Objects/longobject.c: change ValueError to OverflowError when
      	converting to int
      
      	* Objects/rangeobject.c: modernized
      
      	* Objects/stringobject.c: use HAVE_LIMITS instead of __STDC__
      
      	* Objects/xxobject.c: changed to use new style (not finished?)
      03093a24
  33. 29 Agu, 1994 1 kayıt (commit)
  34. 01 Kas, 1993 1 kayıt (commit)
  35. 17 Haz, 1993 1 kayıt (commit)
    • Guido van Rossum's avatar
      * Added gmtime/localtime/mktime and SYSV timezone globals to timemodule.c. · 234f942a
      Guido van Rossum yazdı
        Added $(SYSDEF) to its build rule in Makefile.
      * cgensupport.[ch], modsupport.[ch]: removed some old stuff.  Also
        changed files that still used it...  And made several things static
        that weren't but should have been...  And other minor cleanups...
      * listobject.[ch]: add external interfaces {set,get}listslice
      * socketmodule.c: fix bugs in new send() argument parsing.
      * sunaudiodevmodule.c: added flush() and close().
      234f942a
  36. 29 Mar, 1993 1 kayıt (commit)
    • Guido van Rossum's avatar
      * Changed all copyright messages to include 1993. · 9bfef44d
      Guido van Rossum yazdı
      * Stubs for faster implementation of local variables (not yet finished)
      * Added function name to code object.  Print it for code and function
        objects.  THIS MAKES THE .PYC FILE FORMAT INCOMPATIBLE (the version
        number has changed accordingly)
      * Print address of self for built-in methods
      * New internal functions getattro and setattro (getattr/setattr with
        string object arg)
      * Replaced "dictobject" with more powerful "mappingobject"
      * New per-type functio tp_hash to implement arbitrary object hashing,
        and hashobject() to interface to it
      * Added built-in functions hash(v) and hasattr(v, 'name')
      * classobject: made some functions static that accidentally weren't;
        added __hash__ special instance method to implement hash()
      * Added proper comparison for built-in methods and functions
      9bfef44d
  37. 16 Mar, 1993 1 kayıt (commit)
    • Guido van Rossum's avatar
      * Changed many files to use mkvalue() instead of newtupleobject(). · e537240c
      Guido van Rossum yazdı
      * Fixcprt.py: added [-y file] option, do only files younger than file.
      * modsupport.[ch]: added vmkvalue().
      * intobject.c: use mkvalue().
      * stringobject.c: added "formatstring"; renamed string* to string_*;
        ceval.c: call formatstring for string % value.
      * longobject.c: close memory leak in divmod.
      * parsetok.c: set result node to NULL when returning an error.
      e537240c
  38. 26 Ock, 1993 1 kayıt (commit)
    • Guido van Rossum's avatar
      * Added Fixcprt.py: script to fix copyright message. · 34679b76
      Guido van Rossum yazdı
      * various modules: added 1993 to copyright.
      * thread.c: added copyright notice.
      * ceval.c: minor change to error message for "+"
      * stdwinmodule.c: check for error from wfetchcolor
      * config.c: MS-DOS fixes (define PYTHONPATH, use DELIM, use osdefs.h)
      * Add declaration of inittab to import.h
      * sysmodule.c: added sys.builtin_module_names
      * xxmodule.c, xxobject.c: fix minor errors
      34679b76
  39. 21 Ock, 1993 1 kayıt (commit)
    • Guido van Rossum's avatar
      Added separate main program for the Mac: macmain.c · 0b0db8e3
      Guido van Rossum yazdı
      stdwinmodule.c: wsetfont can now return an error
      Makefile: add CL_USE and CL_LIB*S; config.c: move CL part around
      New things in imgfile; also in Makefile.
      longobject.c: fix comparison of negative long ints...  [REAL BUG!]
      marshal.c: add dumps() and loads() to read/write strings
      timemodule.c: make sure there's always a floatsleep()
      posixmodule.c: rationalize struct returned by times()
      Makefile: add test target, disable imgfile by default
      thread.c: Improved coexistance with dl module (sjoerd)
      stdwinmodule.c: Change include stdwin.h if macintosh
      rotormodule.c: added missing last argument to RTR_?_region calls
      confic.c: merged with configmac.c, added 1993 to copyright message
      fileobject.c: int compared to NULL in writestring(); change fopenRF ifdef
      timemodule.c: simplify times() using mkvalue; include myselect.h
        earlier (for sequent).
      posixmodule: for sequent, include unistd.h instead of explicit
        extern definitions and don't define rename()
      Makefile: change misleading/wrong MD5 comments
      0b0db8e3