Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | Fix tabs. | Georg Brandl | 2008-03-25 | 1 | -1/+1 |
| | |||||
* | Make Py3k warnings consistent w.r.t. punctuation; also respect the | Georg Brandl | 2008-03-25 | 1 | -3/+6 |
| | | | | EOL 80 limit and supply more alternatives in warning messages. | ||||
* | Add py3k warnings for object, type, cell and dict comparisons. This should ↵ | Steven Bethard | 2008-03-18 | 1 | -1/+7 |
| | | | | resolve issue2342 and partly resolve issue2373. | ||||
* | Use PY_FORMAT_SIZE_T instead of z for string formatting. Thanks Neal. | Christian Heimes | 2008-02-24 | 1 | -2/+4 |
| | |||||
* | dict.copy() rises from the ashes. Revert r60687. | Raymond Hettinger | 2008-02-12 | 1 | -4/+0 |
| | |||||
* | Add -3 warnings that set.copy(), dict.copy(), and defaultdict.copy() will go ↵ | Raymond Hettinger | 2008-02-09 | 1 | -0/+4 |
| | | | | away in Py3.x | ||||
* | Use prefix decrement | Christian Heimes | 2008-02-08 | 1 | -2/+2 |
| | |||||
* | Deallocate content of the dict free list on interpreter shutdown | Christian Heimes | 2008-02-08 | 1 | -0/+12 |
| | |||||
* | Added some statistics code to dict and list object code. I wanted to test ↵ | Christian Heimes | 2008-02-07 | 1 | -0/+25 |
| | | | | how a larger freelist affects the reusage of freed objects. Contrary to my gut feelings 80 objects is more than fine for small apps. I haven't profiled a large app yet. | ||||
* | Unified naming convention for free lists and their limits. All free lists | Christian Heimes | 2008-02-06 | 1 | -7/+9 |
| | | | | | | | | in Object/ are named ``free_list``, the counter ``numfree`` and the upper limit is a macro ``PyName_MAXFREELIST`` inside an #ifndef block. The chances should make it easier to adjust Python for platforms with less memory, e.g. mobile phones. | ||||
* | Changes 54857 and 54840 broke code and were reverted in Py2.5 just before | Raymond Hettinger | 2008-01-25 | 1 | -1/+1 |
| | | | | it was released, but that reversion never made it to the Py2.6 head. | ||||
* | #1629: Renamed Py_Size, Py_Type and Py_Refcnt to Py_SIZE, Py_TYPE and ↵ | Christian Heimes | 2007-12-19 | 1 | -4/+4 |
| | | | | Py_REFCNT. Macros for b/w compatibility are available. | ||||
* | Give meaning to the oparg for BUILD_MAP: estimated size of the dictionary. | Raymond Hettinger | 2007-12-18 | 1 | -0/+17 |
| | | | | | | | | | | | Allows dictionaries to be pre-sized (upto 255 elements) saving time lost to re-sizes with their attendant mallocs and re-insertions. Has zero effect on small dictionaries (5 elements or fewer), a slight benefit for dicts upto 22 elements (because they had to resize once anyway), and more benefit for dicts upto 255 elements (saving multiple resizes during the build-up and reducing the number of collisions on the first insertions). Beyond 255 elements, there is no addional benefit. | ||||
* | Spaces vs. Tabs. | Georg Brandl | 2007-11-29 | 1 | -4/+4 |
| | |||||
* | Fix bug #1517, a segfault in lookdict(). | Guido van Rossum | 2007-11-29 | 1 | -0/+4 |
| | |||||
* | Backport of _abccoll.py by Benjamin Arangueren, issue 1383. | Guido van Rossum | 2007-11-22 | 1 | -8/+1 |
| | | | | With some changes of my own thrown in (e.g. backport of r58107). | ||||
* | Optimize common case for dict.fromkeys(). | Raymond Hettinger | 2007-11-09 | 1 | -10/+15 |
| | |||||
* | Optimize dict.fromkeys() with dict inputs. Useful for resetting bag/muliset ↵ | Raymond Hettinger | 2007-11-07 | 1 | -0/+19 |
| | | | | counts for example. | ||||
* | Remove file-level typedefs that were inconsistently used throughout the file. | Brett Cannon | 2007-10-10 | 1 | -105/+103 |
| | | | | | | Just move over to the public API names. Closes issue1238. | ||||
* | Add a bunch of GIL release/acquire points in tp_print implementations and for | Brett Cannon | 2007-09-17 | 1 | -1/+12 |
| | | | | | | PyObject_Print(). Closes issue #1164. | ||||
* | PEP 3123: Provide forward compatibility with Python 3.0, while keeping | Martin v. Löwis | 2007-07-21 | 1 | -12/+8 |
| | | | | | backwards compatibility. Add Py_Refcnt, Py_Type, Py_Size, and PyVarObject_HEAD_INIT. | ||||
* | Whitespace cleanup | Neal Norwitz | 2007-05-23 | 1 | -1/+1 |
| | |||||
* | Add -3 option to the interpreter to warn about features that are | Neal Norwitz | 2007-05-23 | 1 | -2/+12 |
| | | | | | | | deprecated and will be changed/removed in Python 3.0. This patch is mostly from Anthony. I tweaked some format and added a little doc. | ||||
* | Add test and fix for fromkeys() optional argument. | Raymond Hettinger | 2007-03-21 | 1 | -2/+2 |
| | |||||
* | Extend work on rev 52962 and 53829 eliminating redundant PyObject_Hash() ↵ | Raymond Hettinger | 2007-03-20 | 1 | -0/+18 |
| | | | | calls and fixing set/dict interoperability. | ||||
* | Variation of patch # 1624059 to speed up checking if an object is a subclass | Neal Norwitz | 2007-02-25 | 1 | -1/+1 |
| | | | | | | | | | | | | | | | | | | of some of the common builtin types. Use a bit in tp_flags for each common builtin type. Check the bit to determine if any instance is a subclass of these common types. The check avoids a function call and O(n) search of the base classes. The check is done in the various Py*_Check macros rather than calling PyType_IsSubtype(). All the bits are set in tp_flags when the type is declared in the Objects/*object.c files because PyType_Ready() is not called for all the types. Should PyType_Ready() be called for all types? If so and the change is made, the changes to the Objects/*object.c files can be reverted (remove setting the tp_flags). Objects/typeobject.c would also have to be modified to add conditions for Py*_CheckExact() in addition to each the PyType_IsSubtype check. | ||||
* | Extend work on revision 52962: Eliminate redundant calls to PyObject_Hash(). | Raymond Hettinger | 2007-02-19 | 1 | -0/+39 |
| | |||||
* | SF #1615701: make d.update(m) honor __getitem__() and keys() in dict subclasses | Raymond Hettinger | 2007-02-07 | 1 | -1/+1 |
| | |||||
* | Fix refleak | Neal Norwitz | 2006-10-29 | 1 | -0/+1 |
| | |||||
* | Bug #1576657: when setting a KeyError for a tuple key, make sure that | Georg Brandl | 2006-10-29 | 1 | -3/+16 |
| | | | | the tuple isn't used as the "exception arguments tuple". | ||||
* | Fix warnings with HP's C compiler. It doesn't recognize that infinite | Neal Norwitz | 2006-10-28 | 1 | -0/+4 |
| | | | | | | loops are, um, infinite. These conditions should not be able to happen. Will backport. | ||||
* | Fix SF bug #1546288, crash in dict_equal. | Neal Norwitz | 2006-09-05 | 1 | -0/+3 |
| | |||||
* | Typo fixes | Andrew M. Kuchling | 2006-08-04 | 1 | -1/+1 |
| | |||||
* | Add some asserts that we got good params passed | Neal Norwitz | 2006-07-21 | 1 | -0/+3 |
| | |||||
* | SF bug #1503294. | Armin Rigo | 2006-06-10 | 1 | -1/+1 |
| | | | | PyThreadState_GET() complains if the tstate is NULL, but only in debug mode. | ||||
* | Armin committed his patch while I was reviewing it (I'm sure | Tim Peters | 2006-06-01 | 1 | -28/+40 |
| | | | | | | | | he didn't know this), so merged in some changes I made during review. Nothing material apart from changing a new `mask` local from int to Py_ssize_t. Mostly this is repairing comments that were made incorrect, and adding new comments. Also a few minor code rewrites for clarity or helpful succinctness. | ||||
* | [ 1497053 ] Let dicts propagate the exceptions in user __eq__(). | Armin Rigo | 2006-06-01 | 1 | -50/+107 |
| | | | | [ 1456209 ] dictresize() vulnerability ( <- backport candidate ). | ||||
* | dict_print(): So that Neal & I don't spend the rest of | Tim Peters | 2006-05-30 | 1 | -4/+5 |
| | | | | | | our lives taking turns rewriting code that works ;-), get rid of casting illusions by declaring a new variable with the obvious type. | ||||
* | dict_print(): Explicitly narrow the return value | Tim Peters | 2006-05-30 | 1 | -1/+1 |
| | | | | from a (possibly) wider variable. | ||||
* | No DOWNCAST is required since sizeof(Py_ssize_t) >= sizeof(int) and ↵ | Neal Norwitz | 2006-05-30 | 1 | -1/+1 |
| | | | | Py_ReprEntr returns an int | ||||
* | Use Py_SAFE_DOWNCAST for safety. Fix format strings. Remove 2 more stray | ↵ | Neal Norwitz | 2006-05-30 | 1 | -6/+6 |
| | | | | in comment | ||||
* | Remove stray | in comment | Neal Norwitz | 2006-05-30 | 1 | -1/+1 |
| | |||||
* | Convert relevant dict internals to Py_ssize_t. | Tim Peters | 2006-05-30 | 1 | -43/+55 |
| | | | | | | I don't have a box with nearly enough RAM, or an OS, that could get close to tickling this, though (requires a dict w/ at least 2**31 entries). | ||||
* | Use Py_VISIT in all tp_traverse methods, instead of traversing manually or | Thomas Wouters | 2006-04-15 | 1 | -7/+2 |
| | | | | | | | | using a custom, nearly-identical macro. This probably changes how some of these functions are compiled, which may result in fractionally slower (or faster) execution. Considering the nature of traversal, visiting much of the address space in unpredictable patterns, I'd argue the code readability and maintainability is well worth it ;P | ||||
* | Ignore the references to the dummy objects used as deleted keys | Armin Rigo | 2006-04-12 | 1 | -0/+8 |
| | | | | in dicts and sets when computing the total number of references. | ||||
* | Remove unnecessary casts in type object initializers. | Georg Brandl | 2006-03-30 | 1 | -13/+13 |
| | |||||
* | Oops. Fix syntax for C89 compilers. | Guido van Rossum | 2006-02-25 | 1 | -2/+2 |
| | |||||
* | - Patch 1433928: | Guido van Rossum | 2006-02-25 | 1 | -1/+15 |
| | | | | | | | | - The copy module now "copies" function objects (as atomic objects). - dict.__getitem__ now looks for a __missing__ hook before raising KeyError. - Added a new type, defaultdict, to the collections module. This uses the new __missing__ hook behavior added to dict (see above). | ||||
* | Revert 42400. | Martin v. Löwis | 2006-02-16 | 1 | -1/+1 |
| | |||||
* | Support %zd in PyErr_Format and PyString_FromFormat. | Martin v. Löwis | 2006-02-16 | 1 | -1/+1 |
| |