Andrew MacIntyre [Fri, 26 Dec 2003 00:00:29 +0000 (00:00 +0000)]
backport of concrete.tex v1.35:
The semantics of PyList_Check() and PyDict_Check() changed at 2.2, along
with most other concrete object checks, but the docs weren't brought into
line.
PyList_CheckExact() was added at 2.2 but never documented.
[Bug #811681] The asynchat documentation would also apply to the 2.2 version of the module, but the docs aren't included. This adds a copy of libasynchat.tex.
Barry Warsaw [Wed, 3 Sep 2003 04:14:01 +0000 (04:14 +0000)]
A fix for parsing parameters when there are semicolons inside the
quotes. Fixes SF bug #794466, with the essential patch provided by
Stuart D. Gathman. Specifically,
_parseparam(), _get_params_preserve(): Use the parsing function that
takes quotes into account, as given (essentially) in the bug report's
test program.
Anthony Baxter [Sun, 13 Jul 2003 13:54:34 +0000 (13:54 +0000)]
Backport of rhettinger's funcobject.c 2.63, bugfix for SF bug 753451
Check the argument of classmethod is callable. (prevents
classmethod(classmethod(func)) from bombing out.
Fred Drake [Fri, 27 Jun 2003 18:27:21 +0000 (18:27 +0000)]
Don't assume the name of the table of contents will be contents.html;
that won't be right when mkhowto is called with --numeric (as it is
for the Python Tutorial). Save the actual name we use when we build
the table of contents, then use that in the page head metadata. The
node2label.pl script will munge this properly when --numeric isn't
given, so this works in both cases.
Closes SF bug #761830.
Barry Warsaw [Thu, 29 May 2003 20:09:31 +0000 (20:09 +0000)]
Backport from 2.3 trunk:
_make_boundary(): Fix for SF bug #745478, broken boundary calculation
in some locales. This code simplifies the boundary algorithm to use
randint() which is what we wanted anyway.
Tim Peters [Thu, 29 May 2003 18:50:45 +0000 (18:50 +0000)]
Give the Windows socket wrapper function default values for its 'family'
and 'type' arguments. This improves x-platform compatibility (e.g., on
Unix systems socket() already supported these default arguments).
No need to do anything here for 2.3 -- it already fixed this glitch in a
different way.
Barry Warsaw [Thu, 29 May 2003 15:13:18 +0000 (15:13 +0000)]
Backport patch 2.206:
----------------------------
revision 2.206
date: 2003/02/11 16:25:43; author: gvanrossum; state: Exp; lines: +9 -0
Add basic arg sanity checking to wrap_descr_get(). This is called
when Python code calls a descriptor's __get__ method. It should
translate None to NULL in both argument positions, and insist that at
least one of the argument positions is not NULL after this
transformation.
----------------------------
which fixes SF bug # 736892, forcing function to act like an unbound
method dumps core.
Barry Warsaw [Wed, 28 May 2003 23:03:30 +0000 (23:03 +0000)]
The backport gets Fred's seal of approval:
SF 742860: WeakKeyDictionary __delitem__ uses iterkeys
Someone review this, please! Final releases are getting close, Fred
(the weakref guy) won't be around until Tuesday, and the pre-patch
code can indeed raise spurious RuntimeErrors in the presence of
threads or mutating comparison functions.
See the bug report for my confusions: I can't see any reason for why
__delitem__ iterated over the keys. The new one-liner implementation
is much faster, can't raise RuntimeError, and should be better-behaved
in all respects wrt threads.
New tests test_weak_keyed_bad_delitem and
test_weak_keyed_cascading_deletes fail before this patch.
Jeremy Hylton [Thu, 22 May 2003 18:11:20 +0000 (18:11 +0000)]
Backport fix for SF bug 692776.
Add a tp_new slot to function objects that handles the case of a
function requiring a closure. Put the function type in the new
module, rather than having a function new.function(). Add tests.
Barry Warsaw [Thu, 22 May 2003 17:36:54 +0000 (17:36 +0000)]
Link the dbm module against gdbm if it exists and if no earlier
library match was found. This fixes dbm on RedHat 9 and doesn't
appear (so far <wink>) to have any regressions on other *nixes.