summaryrefslogtreecommitdiffstats
path: root/Objects
Commit message (Collapse)AuthorAgeFilesLines
* Issue #4910 (1st patch of a series): fix int() and the correspondingMark Dickinson2009-01-121-13/+1
| | | | | | | | | PyNumber_Int/PyNumber_Long API function so that it no longer attempts to call the __long__ method for conversion. Only the __int__ and __trunc__ methods are used. (This removes a major remaining use of the nb_long slot from the Python 3.x core.) Thanks Benjamin for review.
* Issue #4916: fix little-endian UTF-16 decoding bug on big-endian UCS-4 ↵Antoine Pitrou2009-01-111-8/+16
| | | | builds, introduced by r68483.
* Merged revisions 68381 via svnmerge fromBenjamin Peterson2009-01-113-11/+16
| | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r68381 | martin.v.loewis | 2009-01-07 12:40:40 -0600 (Wed, 07 Jan 2009) | 2 lines Issue #4850: Change COUNT_ALLOCS variables to Py_ssize_t. ........
* Issue #4910: replace "long" with "int" in docstring for __long__ slot andMark Dickinson2009-01-101-1/+1
| | | | in documentation for PyNumber_Long.
* Issue #4868: utf-8, utf-16 and latin1 decoding are now 2x to 4x faster. TheAntoine Pitrou2009-01-101-24/+207
| | | | | | | | common cases are optimized thanks to a dedicated fast path and a moderate amount of loop unrolling. This will especially help text I/O (we already register a 30% speedup on large reads on the io-c branch).
* Reduce the size of the _PyLong_DigitValue table.Raymond Hettinger2009-01-091-3/+3
|
* Issue #4822: fix messy indentation in memoryobject.c/.h, before we may ↵Antoine Pitrou2009-01-031-432/+431
| | | | | | backport it to trunk. Reviewed on IRC by Georg Brandl, with assistance by Benjamin Peterson.
* Issue #4580: slicing of memoryviews when itemsize != 1 is wrong.Antoine Pitrou2009-01-032-69/+64
| | | | | | | | Also fix len() to return number of items rather than length in bytes. I'm sorry it was not possible for me to work on this without reindenting a bit some stuff around. The indentation in memoryobject.c is a mess, I'll open a separate bug for it.
* Remove traces of Py_InitModule*.Georg Brandl2009-01-021-2/+2
|
* Merged revisions 68128 via svnmerge fromAntoine Pitrou2009-01-012-20/+45
| | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r68128 | antoine.pitrou | 2009-01-01 15:11:22 +0100 (jeu., 01 janv. 2009) | 3 lines Issue #3680: Reference cycles created through a dict, set or deque iterator did not get collected. ........
* Recorded merge of revisions 68051 via svnmerge fromNick Coghlan2008-12-301-0/+11
| | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r68051 | nick.coghlan | 2008-12-30 11:18:48 +1000 (Tue, 30 Dec 2008) | 1 line Issue #4701: implicitly call PyType_Ready from PyObject_Hash ........
* #4759: allow None as first argument of bytearray.translate(), for ↵Georg Brandl2008-12-281-16/+25
| | | | | | consistency with bytes.translate(). Also fix segfault for bytearray.translate(x, None) -- will backport this part to 3.0 and 2.6.
* Remove confusing error message in bytes.translate.Georg Brandl2008-12-271-5/+0
|
* Revert unwanted function name change introduced by r67939.Alexandre Vassalotti2008-12-271-1/+1
|
* Fixed incompatible pointer warning.Hirokazu Yamamoto2008-12-271-1/+1
|
* Fix bogus assertion.Alexandre Vassalotti2008-12-271-1/+1
|
* Optimize built-in unicode codecs by avoiding unnecessary copying.Alexandre Vassalotti2008-12-271-50/+58
| | | | | | The approach used is similiar to what is currently used in the version of unicodeobject.c in Python 2.x. The only difference is we use _PyBytes_Resize instead of _PyString_Resize.
* Fix wrong bytes type conversion in PyUnicode_AsUnicodeEscapeString.Alexandre Vassalotti2008-12-271-15/+4
| | | | Fix wrong bytes type conversion in PyUnicode_AsUnicodeDecodeString.
* Merged revisions 67932 via svnmerge fromAlexandre Vassalotti2008-12-271-28/+30
| | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r67932 | alexandre.vassalotti | 2008-12-27 01:36:10 -0500 (Sat, 27 Dec 2008) | 5 lines Remove unnecessary casts related to unicode_decode_call_errorhandler. Make the _PyUnicode_Resize macro a static function. These changes are needed to avoid breaking strict aliasing rules. ........
* Merged revisions ↵Benjamin Peterson2008-12-211-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 67654,67676-67677,67681,67692,67725,67761,67784-67785,67787-67788,67802,67848-67850,67862-67864,67880,67882 via svnmerge from svn+ssh://pythondev@svn.python.org/python/trunk ........ r67654 | georg.brandl | 2008-12-07 16:42:09 -0600 (Sun, 07 Dec 2008) | 2 lines #4457: rewrite __import__() documentation. ........ r67676 | benjamin.peterson | 2008-12-08 20:03:03 -0600 (Mon, 08 Dec 2008) | 1 line specify how things are copied ........ r67677 | benjamin.peterson | 2008-12-08 20:05:11 -0600 (Mon, 08 Dec 2008) | 1 line revert unrelated change to installer script ........ r67681 | jeremy.hylton | 2008-12-09 15:03:10 -0600 (Tue, 09 Dec 2008) | 2 lines Add simple unittests for Request ........ r67692 | amaury.forgeotdarc | 2008-12-10 18:03:42 -0600 (Wed, 10 Dec 2008) | 2 lines #1030250: correctly pass the dry_run option to the mkpath() function. ........ r67725 | benjamin.peterson | 2008-12-12 22:02:20 -0600 (Fri, 12 Dec 2008) | 1 line fix incorrect example ........ r67761 | benjamin.peterson | 2008-12-14 11:26:04 -0600 (Sun, 14 Dec 2008) | 1 line fix missing bracket ........ r67784 | georg.brandl | 2008-12-15 02:33:58 -0600 (Mon, 15 Dec 2008) | 2 lines #4446: document "platforms" argument for setup(). ........ r67785 | georg.brandl | 2008-12-15 02:36:11 -0600 (Mon, 15 Dec 2008) | 2 lines #4611: fix typo. ........ r67787 | georg.brandl | 2008-12-15 02:58:59 -0600 (Mon, 15 Dec 2008) | 2 lines #4578: fix has_key() usage in compiler package. ........ r67788 | georg.brandl | 2008-12-15 03:07:39 -0600 (Mon, 15 Dec 2008) | 2 lines #4568: remove limitation in varargs callback example. ........ r67802 | amaury.forgeotdarc | 2008-12-15 16:29:14 -0600 (Mon, 15 Dec 2008) | 4 lines #3632: the "pyo" macro from gdbinit can now run when the GIL is released. Patch by haypo. ........ r67848 | benjamin.peterson | 2008-12-18 20:28:56 -0600 (Thu, 18 Dec 2008) | 1 line fix typo ........ r67849 | benjamin.peterson | 2008-12-18 20:31:35 -0600 (Thu, 18 Dec 2008) | 1 line _call_method -> _callmethod and _get_value to _getvalue ........ r67850 | raymond.hettinger | 2008-12-19 03:06:07 -0600 (Fri, 19 Dec 2008) | 9 lines Fix-up and clean-up docs for int.bit_length(). * Replace dramatic footnote with in-line comment about possible round-off errors in logarithms of large numbers. * Add comments to the pure python code equivalent. * replace floor() with int() in the mathematical equivalent so the type is correct (should be an int, not a float). * add abs() to the mathematical equivalent so that it matches the previous line that it is supposed to be equivalent to. * make one combined example with a negative input. ........ r67862 | benjamin.peterson | 2008-12-19 20:48:02 -0600 (Fri, 19 Dec 2008) | 1 line copy sentence from docstring ........ r67863 | benjamin.peterson | 2008-12-19 20:51:26 -0600 (Fri, 19 Dec 2008) | 1 line add headings ........ r67864 | benjamin.peterson | 2008-12-19 20:57:19 -0600 (Fri, 19 Dec 2008) | 1 line beef up docstring ........ r67880 | benjamin.peterson | 2008-12-20 16:49:24 -0600 (Sat, 20 Dec 2008) | 1 line remove redundant sentence ........ r67882 | benjamin.peterson | 2008-12-20 16:59:49 -0600 (Sat, 20 Dec 2008) | 1 line add some recent releases to the list ........
* Issue #3106: Speedup some comparisons. This also removes the last callAntoine Pitrou2008-12-202-73/+88
| | | | to Py_CmpToRich from the codebase (in longobject.c).
* Add missing Py_CHARMASK when calling isspace().Kristján Valur Jónsson2008-12-181-2/+2
| | | | Found by enabling runtime tests on windows, by disabling the _set_invalid_parameter_handler() fiddling.
* Forward merge of r67822 to py3k: add bit_length method to int.Mark Dickinson2008-12-171-0/+71
|
* Issue #4569: Interpreter crash when mutating a memoryview with an item size ↵Antoine Pitrou2008-12-071-93/+105
| | | | | | larger than 1. (together with a bit of reindenting)
* Issue #4509: bugs in bytearray with exports (buffer protocol)Antoine Pitrou2008-12-061-11/+31
|
* Issue #4445: save 3 bytes of memory (on average) per bytes allocation.Mark Dickinson2008-12-061-10/+18
| | | | (This is a forward port of r67601).
* Issue 4497: silence compiler warnings on Windows.Mark Dickinson2008-12-051-4/+4
|
* Issue 3689: list_reverseiterator should support __length_hint__ instead of ↵Raymond Hettinger2008-12-021-8/+9
| | | | __len__.
* Update copyright for recent changes.Raymond Hettinger2008-11-301-1/+1
|
* Merged revisions ↵Benjamin Peterson2008-11-301-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 67348,67355,67359,67362,67364-67365,67367-67368,67398,67423-67424,67432,67440-67441,67444-67445,67454-67455,67457-67458 via svnmerge from svn+ssh://pythondev@svn.python.org/python/trunk ........ r67348 | benjamin.peterson | 2008-11-22 20:09:41 -0600 (Sat, 22 Nov 2008) | 1 line raise a better error ........ r67355 | georg.brandl | 2008-11-23 13:17:25 -0600 (Sun, 23 Nov 2008) | 2 lines #4392: fix parameter name. ........ r67359 | georg.brandl | 2008-11-23 15:57:30 -0600 (Sun, 23 Nov 2008) | 2 lines #4399: fix typo. ........ r67362 | gregory.p.smith | 2008-11-23 18:41:43 -0600 (Sun, 23 Nov 2008) | 2 lines Document PY_SSIZE_T_CLEAN for PyArg_ParseTuple. ........ r67364 | benjamin.peterson | 2008-11-23 19:16:29 -0600 (Sun, 23 Nov 2008) | 2 lines replace reference to debugger-hooks ........ r67365 | benjamin.peterson | 2008-11-23 22:09:03 -0600 (Sun, 23 Nov 2008) | 1 line #4396 make the parser module correctly validate the with syntax ........ r67367 | georg.brandl | 2008-11-24 10:16:07 -0600 (Mon, 24 Nov 2008) | 2 lines Fix typo. ........ r67368 | georg.brandl | 2008-11-24 13:56:47 -0600 (Mon, 24 Nov 2008) | 2 lines #4404: make clear what "path" is. ........ r67398 | benjamin.peterson | 2008-11-26 11:39:17 -0600 (Wed, 26 Nov 2008) | 1 line fix typo in sqlite3 docs ........ r67423 | jesse.noller | 2008-11-28 12:59:35 -0600 (Fri, 28 Nov 2008) | 2 lines issue4238: bsd support for cpu_count ........ r67424 | christian.heimes | 2008-11-28 13:33:33 -0600 (Fri, 28 Nov 2008) | 1 line Retain copyright of processing examples. This was requested by a Debian maintainer during packaging of the multiprocessing package for 2.4/2.5 ........ r67432 | benjamin.peterson | 2008-11-28 17:18:46 -0600 (Fri, 28 Nov 2008) | 1 line SVN format 9 is the same it seems ........ r67440 | jeremy.hylton | 2008-11-28 17:42:59 -0600 (Fri, 28 Nov 2008) | 4 lines Move definition int sval into branch of ifdef where it is used. Otherwise, you get a warning about an undefined variable. ........ r67441 | jeremy.hylton | 2008-11-28 18:09:16 -0600 (Fri, 28 Nov 2008) | 2 lines Reflow long lines. ........ r67444 | amaury.forgeotdarc | 2008-11-28 20:03:32 -0600 (Fri, 28 Nov 2008) | 2 lines Fix a small typo in docstring ........ r67445 | benjamin.peterson | 2008-11-29 21:07:33 -0600 (Sat, 29 Nov 2008) | 1 line StringIO.close() stops you from using the buffer, too ........ r67454 | benjamin.peterson | 2008-11-30 08:43:23 -0600 (Sun, 30 Nov 2008) | 1 line note the version that works ........ r67455 | martin.v.loewis | 2008-11-30 13:28:27 -0600 (Sun, 30 Nov 2008) | 1 line Issue #4365: Add crtassem.h constants to the msvcrt module. ........ r67457 | christian.heimes | 2008-11-30 15:16:28 -0600 (Sun, 30 Nov 2008) | 1 line w# requires Py_ssize_t ........ r67458 | benjamin.peterson | 2008-11-30 15:46:16 -0600 (Sun, 30 Nov 2008) | 1 line fix pyspecific extensions that were broken by Sphinx's grand renaming ........
* Fix for bug 4360 "SystemError when method has both super() & closure". PatchBarry Warsaw2008-11-201-2/+3
| | | | | | by amaury.forgeotdarc and reviewed by brett.cannon. Also add release notes about the known problems with the email package.
* Merged revisions 67291 via svnmerge fromBenjamin Peterson2008-11-191-17/+3
| | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r67291 | benjamin.peterson | 2008-11-19 15:49:09 -0600 (Wed, 19 Nov 2008) | 5 lines make sure that bytearray methods return a new bytearray even if there is no change Fixes #4348 Reviewed by Brett ........
* Merged revisions 67246 via svnmerge fromBenjamin Peterson2008-11-171-3/+36
| | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r67246 | benjamin.peterson | 2008-11-17 16:39:09 -0600 (Mon, 17 Nov 2008) | 5 lines when __getattr__ is a descriptor, call it correctly; fixes #4230 patch from Ziga Seilnacht ........
* Issue #1721812: Binary operations and copy operations on set/frozensetRaymond Hettinger2008-11-161-5/+17
| | | | subclasses need to return the base type, not the subclass itself.
* Issue #4296: Fix PyObject_RichCompareBool so that "x in [x]" evaluates toMark Dickinson2008-11-121-0/+9
| | | | | | | True, even when x doesn't compare equal to itself. This was a regression from 2.6. Reviewed by R. Hettinger and C. Heimes.
* Issue 3723: Fixed initialization of subinterpretersChristian Heimes2008-10-301-0/+13
| | | | | The patch fixes several issues with Py_NewInterpreter as well as the demo for multiple subinterpreters. Most of the patch was written by MvL with help from Benjamin, Amaury and me. Graham Dumpleton has verified that this patch fixes an issue with mod_wsgi.
* STINNER Victor (haypo)'s patch for bug 3988, Byte warning mode and b'' != ''Barry Warsaw2008-10-172-2/+2
| | | | Also, his patch to runtests.sh to pass the -bb option (issue 4125).
* remove some more references to __cmp__ #1717Benjamin Peterson2008-10-161-85/+0
|
* merge from trunkBenjamin Peterson2008-10-116-19/+30
|
* Issue #3740: Null-initialize module state.Martin v. Löwis2008-10-071-0/+1
| | | | Reviewed by Benjamin Peterson.
* Merged revisions 66748 via svnmerge fromChristian Heimes2008-10-022-16/+16
| | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r66748 | christian.heimes | 2008-10-02 21:47:50 +0200 (Thu, 02 Oct 2008) | 1 line Fixed a couple more C99 comments and one occurence of inline. ........ + another // comment in bytesobject
* Merged revisions 66739 via svnmerge fromChristian Heimes2008-10-021-1/+1
| | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r66739 | christian.heimes | 2008-10-02 20:33:41 +0200 (Thu, 02 Oct 2008) | 1 line Fixed a comment to C89 style as of http://drj11.wordpress.com/2008/10/02/python-and-bragging-about-c89/ ........
* remove a trace of the cmp argument for list.sortBenjamin Peterson2008-09-301-2/+1
|
* Merged revisions 66631 via svnmerge fromAmaury Forgeot d'Arc2008-09-262-8/+6
| | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r66631 | amaury.forgeotdarc | 2008-09-27 00:34:08 +0200 (sam., 27 sept. 2008) | 7 lines #3967: Correct a crash in count() and find() methods of string-like objects. For example: "".count("xxxx", sys.maxint, 0) Reviewed by Benjamin Peterson. Will port to 2.5 and 3.0. ........
* #3946 fix PyObject_CheckBuffer on a memoryview objectBenjamin Peterson2008-09-261-3/+3
| | | | reviewed by Antoine
* Merged revisions 66616 via svnmerge fromMartin v. Löwis2008-09-251-1/+1
| | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r66616 | martin.v.loewis | 2008-09-25 06:12:50 +0200 (Do, 25 Sep 2008) | 2 lines Bug #3951: Py_USING_MEMORY_DEBUGGER should not be enabled by default. ........
* Merged revisions 66552-66553 via svnmerge fromAndrew MacIntyre2008-09-221-3/+3
| | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r66552 | andrew.macintyre | 2008-09-23 00:10:54 +1000 (Tue, 23 Sep 2008) | 5 lines should use macro'ed symbols not direct Part of source_os2emx.patch in issue 3868 Reviewed by Amaury Forgeot d'Arc ........ r66553 | andrew.macintyre | 2008-09-23 00:11:41 +1000 (Tue, 23 Sep 2008) | 5 lines any platform without HAVE_LOG1P should have DBL_EPSILON in <float.h> Part of source_os2emx.patch in issue 3868 Reviewed by Amaury Forgeot d'Arc ........
* Merged revisions 66383 via svnmerge fromMartin v. Löwis2008-09-111-1/+3
| | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r66383 | martin.v.loewis | 2008-09-11 08:53:30 +0200 (Do, 11 Sep 2008) | 3 lines Issue #3642: Suppress warning in obmalloc when size_t is larger than uint. Reverts r65975. Reviewed by Brett Cannon. ........
* Merged revisions 66337,66347,66350,66352,66358 via svnmerge fromBenjamin Peterson2008-09-102-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | svn+ssh://pythondev@svn.python.org/python/trunk ........ r66337 | vinay.sajip | 2008-09-09 08:42:08 -0500 (Tue, 09 Sep 2008) | 1 line Issue #3809: Fixed spurious 'test.blah' file left behind by test_logging. ........ r66347 | georg.brandl | 2008-09-09 14:26:00 -0500 (Tue, 09 Sep 2008) | 2 lines Fix varname in docstring. #3822. ........ r66350 | georg.brandl | 2008-09-09 15:28:31 -0500 (Tue, 09 Sep 2008) | 2 lines #3472: update Mac-bundled Python version info. ........ r66352 | benjamin.peterson | 2008-09-09 15:55:01 -0500 (Tue, 09 Sep 2008) | 4 lines Fix #3634 invalid return value from _weakref.ref(Exception).__init__ Reviewers: Amaury, Antoine, Benjamin ........ r66358 | benjamin.peterson | 2008-09-09 18:16:48 -0500 (Tue, 09 Sep 2008) | 1 line use the latest pygments version ........
* kill memoryview.size in favor of len(view)Benjamin Peterson2008-09-101-7/+0
| | | | Reviewer: Antoine Pitrou #3827