Barry Warsaw [Thu, 28 Jan 1999 04:54:33 +0000 (04:54 +0000)]
Slight reworking of this test. If nis.maps() gives a nis.error, then
raise an ImportError if not running verbose. This signals to the
regression framework that this test isn't applicable.
Barry Warsaw [Wed, 27 Jan 1999 23:13:59 +0000 (23:13 +0000)]
builtin_complex(): Nailed memory leak. This one's in the instance
test for classes with a __complex__() method. The attribute is pulled
out of the instance with PyObject_GetAttr() but this transfers
ownership and the function object was never DECREF'd.
Barry Warsaw [Wed, 27 Jan 1999 18:04:05 +0000 (18:04 +0000)]
initerrno(): Nailed a not-so-tiny memory leak. The de dictionary is
put into the module dict, but is never DECREF'd in this function, so
it and all its contents leak.
Barry Warsaw [Wed, 27 Jan 1999 17:48:27 +0000 (17:48 +0000)]
PyLong_FromString(): Nailed a small memory leak. In the str==start
test, we forgot that z is still pointing to a real live object.
DECREF() it before returning.
Fred Drake [Wed, 27 Jan 1999 17:37:36 +0000 (17:37 +0000)]
\py@linkToName: New macro to consolidate support for most internal
hyperlinking in the PDF version. This also allows many of the
macros that do this stuff to be a good bit more readable.
Takes the target name and link content as parameters.
Barry Warsaw [Wed, 27 Jan 1999 16:39:40 +0000 (16:39 +0000)]
err_input(): Nailed a small memory leak. If the error is E_INTR, the
v temporary variable was never decref'd. Test this by starting up the
interpreter, hitting C-c, then immediately exiting.
Same potential leak can occur if error is E_NOMEM, since the return is
done in the case block. Added Py_XDECREF(v); to both blocks, just
before the return.
Guido van Rossum [Tue, 26 Jan 1999 19:29:25 +0000 (19:29 +0000)]
Patch by Chris Petrilli (not really tested since I don't know this
module myself) to accept an option keyword argument (vars) that is
substituted on top of the defaults that were setup in __init__. The
patch also fixes the problem where you can't have recusive references
inside your configuration file.
Fred Drake [Tue, 26 Jan 1999 19:23:09 +0000 (19:23 +0000)]
\py@modindex: Format the index entry for the module index more like
that used in the "normal" index. No visual difference, but
more easily processed by helper scripts.
Guido van Rossum [Mon, 25 Jan 1999 22:36:24 +0000 (22:36 +0000)]
A gift from Fredrik Lundh: fast C implementation of expandtabs().
I've reformatted it, added a few comments, a test for tabsize <= 0,
and used the AS_STRING macro.
Fred Drake [Mon, 25 Jan 1999 21:57:07 +0000 (21:57 +0000)]
Allow recognition of attributes even if they don't have space in front
of them. I.e., '<a name="foo"href="bar.html">' will now have two
attributes recognized.
Guido van Rossum [Mon, 25 Jan 1999 21:38:29 +0000 (21:38 +0000)]
Rearrange the -I flags for compiling _tkinter.c so that
/usr/local/include comes before /usr/X11R1/include. On some Linux
distributions the latter apparently contains (standard!) a bad tcl.h
or tk.h.
Guido van Rossum [Mon, 25 Jan 1999 21:36:13 +0000 (21:36 +0000)]
There's a macro PycString_IMPORT which the documentation listed as
PycStringIO_IMPORT. While arguably the name used in the documentation
is more consistent, I think it's probably safer not to change the
macro definition and instead fix the doco.
Guido van Rossum [Mon, 25 Jan 1999 20:51:34 +0000 (20:51 +0000)]
Change clear_break() to the old signature clear_break(file, line).
Add new clear_bpbynumber() with single bpno argument. (Adapted from
a patch by Richard Wolff.)
Also some cleanup in error messages and moved some comments into a
docstring.
Jack Jansen [Fri, 22 Jan 1999 13:23:12 +0000 (13:23 +0000)]
In unpackevent, get the direct object (----) before asking for missed parameters.
The documentation is unclear on this, but the old implementation caused problems
with Default Folder.
Fred Drake [Wed, 20 Jan 1999 20:35:05 +0000 (20:35 +0000)]
convert(): Added parameter "autoclose", which should be a sequence of
general identifiers for which closing tags will be omitted
when SGML is generated. This can be used to tell the markup
generator to drop stuff like </para>. Note that it needs to
be possible for the closing tag to *always* be omitted for it
to be included in "autoclose".
main(): Added command-line option "-a" / "--autoclose" to set the
list of general identifiers passed to the convert() function
as the "autoclose" parameter. The list may only be specified
once (not additive) and GIs should be comma-separated. The
default list includes only "para".
Fred Drake [Wed, 20 Jan 1999 17:26:56 +0000 (17:26 +0000)]
Modified the "sgml" and "xml" targets to stop if the sub-makes fail in
any subdirectory; don't continue with remaining subdirs.
Added "api", "ext", "lib", "mac", "ref", and "tut" targets to only do
submakes in those directories. This is just a lot easier to use than
to cd into the subdir and use make.rules directly.
Fred Drake [Tue, 19 Jan 1999 21:46:48 +0000 (21:46 +0000)]
handle_labels(): Fix problem for document fragments containing more
than one "root" that prevented all the <label id=...> items
from being promoted to id attributes on the enclosing chapter/
section/... properly.
Fred Drake [Tue, 19 Jan 1999 16:30:10 +0000 (16:30 +0000)]
add_module_idx(), add_idx_hook():
Change the message printed before running buildindex.py;
"Doing the index..." wasn't clear and could be misinterpreted
with an inappropriate mindset. ;-)
Barry Warsaw [Tue, 19 Jan 1999 13:26:56 +0000 (13:26 +0000)]
(py-mode-map): Removed special bindings for C-m and C-j to
py-newline-and-indent. These ought to get picked up by the mapcar
that follows; any existing binding to newline-and-indent gets shadowed
to py-newline-and-indent.
This will break some people who, e.g. bind C-m or C-j to newline but
still want these bound to py-newline-and-indent in Python mode. On
the other hand, the forced binding pisses off Emacs diehards. So
consider this experimental and see if any tall Dutch guys complain :-)
Barry Warsaw [Mon, 18 Jan 1999 21:49:39 +0000 (21:49 +0000)]
(py-narrow-to-defun): New command (bound to C-x n d) which mimics the
standard narrow-to-defun but works with Python classes and methods.
With no arg, narrows to most enclosing def/method. With C-u arg,
narrows to most enclosing class.