Guido van Rossum [Sat, 21 Feb 1998 20:02:09 +0000 (20:02 +0000)]
Major overhaul. Don't use global variable (e.g. verbose); use
instance variables. Make all global functions methods, for easy
overriding. Restructure getpage() for easy overriding. Add
save_pickle() method and load_pickle() global function to make it
easier for other programs to emulate the toplevel interface.
Jack Jansen [Fri, 20 Feb 1998 16:02:09 +0000 (16:02 +0000)]
Regenerated from Universal Headers 3.0.1. Some new calls are
blacklisted, because they are not available in classic 68k programs,
and bgen doesn't have a way to put #ifdef/#endif in the generated
code. For now we only implement calls that work on all three models.
Guido van Rossum [Thu, 19 Feb 1998 21:28:49 +0000 (21:28 +0000)]
Delete the 'exit' command from the Tcl interpreter -- it would allow
users to exit Python without the normal precautions. (The can do this
using os._exit() anyway, but at least that's documented.)
Guido van Rossum [Thu, 19 Feb 1998 21:17:42 +0000 (21:17 +0000)]
Fixed a bug in the gauss() function. The bug was reported by Mike
Miller, who complained that its kurtosis was bad, and then fixed by
Lambert Meertens (author of the original algorithm) who discovered
that the mathematical analysis leading to his solution was wrong, and
provided a corrected version. Mike then tested the fix and reported
that the kurtosis was now good.
Guido van Rossum [Thu, 19 Feb 1998 21:02:32 +0000 (21:02 +0000)]
Jeff Kunce writes (and he is right):
Also, I just ran across a [possible] minor glitch
in the library documentation for site.py. It says:
"For example, suppose sys.prefix and
sys.exec_prefix are set to `/usr/local'. The
Python 1.5 library is then installed in
`/usr/local/lib/python1.5'. Suppose this has a
subdirectory `/usr/local/python1.5/site-packages'
with three subsubdirectories, `foo', `bar' and
`spam'..."
I think it should be:
"...Suppose this has a subdirectory
`/usr/local/lib/python1.5/site-packages' with..."
^^^^
Guido van Rossum [Thu, 19 Feb 1998 21:00:45 +0000 (21:00 +0000)]
Fix some outdated comments (mostly by removing a large comment block
that was only causing confusing). Add free(userpath) and
free(machinepath) statements to prevent some leaks.
Guido van Rossum [Thu, 19 Feb 1998 20:58:44 +0000 (20:58 +0000)]
Moved clear_carefully() to _PyModule_Clear() in moduleobject.c
(modified) and use that.
Some differences in the cleanup algorithm:
- Clear __main__ before the other modules.
- Delete more sys variables: including ps1, ps2, exitfunc, argv, and
even path -- this will prevent new imports!
- Restore stdin, stdout, stderr from __stdin__, __stdout__,
__stderr__, effectively deleting hooks that the user might have
installed -- so their (the hooks') destructors will run.
Guido van Rossum [Thu, 19 Feb 1998 20:51:52 +0000 (20:51 +0000)]
Add internal routine _PyModule_Clear(), which does approximately what
clear_carefully() used to do in import.c. Differences: leave only
__builtins__ alone in the 2nd pass; and don't clear the dictionary (on
the theory that as long as there are references left to the
dictionary, those might be destructors that might expect __builtins__
to be alive when they run; and __builtins__ can't normally be part of
a cycle).
Fred Drake [Wed, 18 Feb 1998 22:45:53 +0000 (22:45 +0000)]
&do_cmd_url,
&do_cmd_email: Adjust to use a font similar to that used in the printed
representation.
&my_module_index_helper: Change to be only used for defining markup. Don't
prepend an <A NAME=...> to the result; use the containing page as
the module target for the index.
&ref_module_index_helper: New function. Used only for references to modules
described elsewhere. Generate the right target.
&init_myformat: Set the anchor_mark to an empty string; this avoids junky
" "'s in the text, which could really screw up vertical spacing
when that's all that's in a paragraph.
&do_cmd_seemodule: Insert markup to jump right to the referred-to module.
Fred Drake [Wed, 18 Feb 1998 16:02:14 +0000 (16:02 +0000)]
Added libsymbol.tex, libtoken.tex to dependencies for the libref.
New targets: ???-all, for each document. This creates all formats of the
named document (DVI, HTML, PDF, PS).
l2hlib: Added commands to translate node*.html to use the \label{} stuff,
as supported by Jeremy's node2html.pl. This gives us mostly
bookmarkable nodes.
Guido van Rossum [Wed, 18 Feb 1998 14:00:05 +0000 (14:00 +0000)]
Add normpath(). Clarify normcase(). (Note -- this doc section
probably needs more work, describing new functions and the differences
between unix/mac/win.
Guido van Rossum [Wed, 18 Feb 1998 13:48:31 +0000 (13:48 +0000)]
(1) Change normpath() to *not* also call normcase().
(2) Fix normcase() to use string.lower() and string.replace() -- it
turns out that the table constructed for translate() didn't work in
locales that have a different number of lowercase and uppercase
letters.