summaryrefslogtreecommitdiff
path: root/Modules/_collectionsmodule.c
Commit message (Collapse)AuthorAgeFilesLines
* Add a reverse() method to collections.deque().Raymond Hettinger2009-12-101-0/+44
|
* Fix variants of deque.extend: d.extend(d) d+=d d.extendleft(d)Raymond Hettinger2009-12-101-0/+40
|
* Issue 6637: defaultdict.copy() failed with an empty factory.Raymond Hettinger2009-08-041-1/+4
|
* For collections.deque() objects, expose the maxlen parameter as a read-only ↵Raymond Hettinger2009-03-101-1/+15
| | | | attribute.
* Small optimization for corner case where maxlen==0.Raymond Hettinger2009-03-101-0/+23
|
* #4801 _collections module fails to build on cygwin.Amaury Forgeot d'Arc2009-01-021-2/+2
| | | | | _PyObject_GC_TRACK is the macro version of PyObject_GC_Track, and according to documentation it should not be used for extension modules.
* Issue #3680: Reference cycles created through a dict, set or deque iterator ↵Antoine Pitrou2009-01-011-7/+16
| | | | did not get collected.
* #3743: PY_FORMAT_SIZE_T is designed for the OS "printf" functions, not forAmaury Forgeot d'Arc2008-09-101-1/+1
| | | | | | | | | PyString_FromFormat which has an independent implementation, and uses "%zd". This makes a difference on win64, where printf needs "%Id" to display 64bit values. For example, queue.__repr__ was incorrect. Reviewed by Martin von Loewis.
* d is the correct format stringChristian Heimes2008-08-221-1/+1
|
* Fixed two format strings in the _collections module. For exampleChristian Heimes2008-08-221-2/+2
| | | | | Modules/_collectionsmodule.c:674: warning: format '%i' expects type 'int', but argument 2 has type 'Py_ssize_t' Reviewed by Benjamin Peterson
* Parse to the correct datatype.Raymond Hettinger2008-07-241-1/+1
|
* Finish-up the partial conversion from int to Py_ssize_t for deque indices ↵Raymond Hettinger2008-07-241-23/+24
| | | | and length.
* Issue 2235: __hash__ is once again inherited by default, but inheritance can ↵Nick Coghlan2008-07-151-8/+1
| | | | be blocked explicitly so that collections.Hashable remains meaningful
* Make more symbols static.Martin v. Löwis2008-06-131-5/+5
|
* This reverts r63675 based on the discussion in this thread:Gregory P. Smith2008-06-091-9/+9
| | | | | | | http://mail.python.org/pipermail/python-dev/2008-June/079988.html Python 2.6 should stick with PyString_* in its codebase. The PyBytes_* names in the spirit of 3.0 are available via a #define only. See the email thread.
* Renamed PyString to PyBytesChristian Heimes2008-05-261-9/+9
|
* dict.copy() rises from the ashes. Revert r60687.Raymond Hettinger2008-02-121-12/+2
|
* Add -3 warnings that set.copy(), dict.copy(), and defaultdict.copy() will go ↵Raymond Hettinger2008-02-091-2/+12
| | | | away in Py3.x
* issue 2045: Infinite recursion when printing a subclass of defaultdict,Amaury Forgeot d'Arc2008-02-081-1/+11
| | | | | | if default_factory is set to a bound method. Will backport.
* #1629: Renamed Py_Size, Py_Type and Py_Refcnt to Py_SIZE, Py_TYPE and ↵Christian Heimes2007-12-191-10/+10
| | | | Py_REFCNT. Macros for b/w compatibility are available.
* Fix bug 1604. deque.__init__() did not clear existing contents like ↵Raymond Hettinger2007-12-131-0/+1
| | | | list.__init__. Not a backport candidate.
* Use a freelist to speed-up block allocation and deallocation in ↵Raymond Hettinger2007-11-101-7/+27
| | | | collections.deque().
* Accept Jim Jewett's api suggestion to use None instead of -1 to indicate ↵Raymond Hettinger2007-10-101-10/+26
| | | | unbounded deques.
* Restore BEGIN/END THREADS macros which were squashed in the previous checkinRaymond Hettinger2007-10-051-5/+21
|
* dict could be NULL, so we need to XDECREF.Neal Norwitz2007-10-051-2/+2
| | | | Fix a compiler warning about passing a PyTypeObject* instead of PyObject*.
* Add __asdict__() to NamedTuple and refine the docs.Raymond Hettinger2007-10-051-85/+101
| | | | | | Add maxlen support to deque() and fixup docs. Partially fix __reduce__(). The None as a third arg was no longer supported. Still needs work on __reduce__() to handle recursive inputs.
* Add a bunch of GIL release/acquire points in tp_print implementations and forBrett Cannon2007-09-171-1/+18
| | | | | | PyObject_Print(). Closes issue #1164.
* PEP 3123: Provide forward compatibility with Python 3.0, while keepingMartin v. Löwis2007-07-211-14/+10
| | | | | backwards compatibility. Add Py_Refcnt, Py_Type, Py_Size, and PyVarObject_HEAD_INIT.
* Fix another reincarnation of bug #1576657 in defaultdict.Georg Brandl2007-03-061-2/+6
|
* Prepare collections module for pure python code entries.Raymond Hettinger2007-02-281-0/+1366