- 07 Oct, 2001 3 commits
-
-
Tim Peters authored
+ The last index in the timing tuple is 4, not 5 (noted by Guido). + The poorly named trace_dispatch_i works with float return values too.
-
Tim Peters authored
This simplifies the rounding in _PyObject_VAR_SIZE, allows to restore the pre-rounding calling sequence, and allows some nice little simplifications in its callers. I'm still making it return a size_t, though.
-
Tim Peters authored
hasn't worked in years, docs were wrong, and they aren't interesting anymore regardless.
-
- 06 Oct, 2001 5 commits
-
-
Tim Peters authored
As Guido suggested, this makes the new subclassing code substantially simpler. But the mechanics of doing it w/ C macro semantics are a mess, and _PyObject_VAR_SIZE has a new calling sequence now. Question: The PyObject_NEW_VAR macro appears to be part of the public API. Regardless of what it expands to, the notion that it has to round up the memory it allocates is new, and extensions containing the old PyObject_NEW_VAR macro expansion (which was embedded in the PyObject_NEW_VAR expansion) won't do this rounding. But the rounding isn't actually *needed* except for new-style instances with dict pointers after a variable-length blob of embedded data. So my guess is that we do not need to bump the API version for this (as the rounding isn't needed for anything an extension can do unless it's recompiled anyway). What's your guess?
-
Tim Peters authored
pad memory to properly align the __dict__ pointer in all cases. gcmodule.c/objimpl.h, _PyObject_GC_Malloc: + Added a "padding" argument so that this flavor of malloc can allocate enough bytes for alignment padding (it can't know this is needed, but its callers do). typeobject.c, PyType_GenericAlloc: + Allocated enough bytes to align the __dict__ pointer. + Sped and simplified the round-up-to-PTRSIZE logic. + Added blank lines so I could parse the if/else blocks <0.7 wink>.
-
Tim Peters authored
+ Use the _PyObject_VAR_SIZE macro to compute object size. + Break the computation into lines convenient for debugger inspection. + Speed the round-up-to-pointer-size computation.
-
Tim Peters authored
no way to talk the debugger into showing me how many bytes were being allocated.
-
Fred Drake authored
-
- 05 Oct, 2001 24 commits
-
-
Tim Peters authored
derive Profile subclasses. This patch repairs that, restoring negative tuple indices. Yuck? You bet.
-
Tim Peters authored
-
Fred Drake authored
-
Fred Drake authored
-
Fred Drake authored
objects. This is now simply a shim to give weakref.py access to the underlying implementation.
-
Fred Drake authored
the implementation is in Objects/weakrefobject.c.
-
Fred Drake authored
-
Fred Drake authored
-
Fred Drake authored
It still needs to be here to preserve the API.
-
Fred Drake authored
-
Fred Drake authored
are moving into the core; with these changes, it will be possible for the exception to be raised without the weakref module ever being imported.
-
Guido van Rossum authored
newline from a multifile part, it should also strip a trailing \r\n.
-
Guido van Rossum authored
many types were subclassable but had a xxx_dealloc function that called PyObject_DEL(self) directly instead of deferring to self->ob_type->tp_free(self). It is permissible to set tp_free in the type object directly to _PyObject_Del, for non-GC types, or to _PyObject_GC_Del, for GC types. Still, PyObject_DEL was a tad faster, so I'm fearing that our pystone rating is going down again. I'm not sure if doing something like void xxx_dealloc(PyObject *self) { if (PyXxxCheckExact(self)) PyObject_DEL(self); else self->ob_type->tp_free(self); } is any faster than always calling the else branch, so I haven't attempted that -- however those types whose own dealloc is fancier (int, float, unicode) do use this pattern.
-
Thomas Heller authored
-
Tim Peters authored
a hard-coded type check.
-
Thomas Heller authored
in the gui. Updated to include the new exe-file.
-
Tim Peters authored
-
Tim Peters authored
foo\d when it was clearly intended to render as foo$ Fred, is this a right way to fix it? If not, the earlier place in the same paragraph that does render as foo$ is also wrong.
-
Barry Warsaw authored
so that it can be suppressed.
-
Guido van Rossum authored
-
Fred Drake authored
This closes SF patch #460737.
-
Fred Drake authored
-
Guido van Rossum authored
Give Fred his Jr.
-
Andrew M. Kuchling authored
-
- 04 Oct, 2001 8 commits
-
-
Martin v. Löwis authored
-
Martin v. Löwis authored
-
Fred Drake authored
-
Fred Drake authored
-
Guido van Rossum authored
This patch allows ConfigParser.getboolean() to interpret TRUE, FALSE, YES, NO, ON and OFF instead just '0' and '1'. While just allowing '0' and '1' sounds more correct users often demand to use more descriptive directives in configuration files. Instead of forcing every programmer do brew his own solution a system should include the batteries for this. [My modification to the patch is a slight rewording of the docstring and use of lowercase instead of uppercase templates. The code is still case sensitive. GvR.]
-
Fred Drake authored
error message. run_unittest(): Provide the testclass to run_suite() so it can construct the error message. This closes SF bug #467763.
-
Guido van Rossum authored
-
Tim Peters authored
not other control characters string.rstrip() got rid of. This caters to the \f thingies Barry likes putting in Python source files.
-