Tim Peters [Mon, 12 May 2003 19:42:04 +0000 (19:42 +0000)]
Effectively renamed tokenize_tests.py to have a txt extension instead.
This file isn't meant to be executed, it's data input for test_tokenize.py.
The problem with the .py extension is that it uses "non-standard"
indentation, and it's good to test that, but reindent.py keeps wanting
to fix it. But fixing the indentation causes the expected-output file to
change, since exact line and column numbers are part of the
tokenize.tokenize() output getting tested.
Tim Peters [Mon, 12 May 2003 19:29:36 +0000 (19:29 +0000)]
Close the file after tokenizing it. Because the open file object was
bound to a module global, the file object remained opened throughout
the test suite run.
Tim Peters [Mon, 12 May 2003 19:16:52 +0000 (19:16 +0000)]
cmp_type(): The grammar stopped allowing '=' as a comparison operator
about a decade ago. Put the code still allowing for it in cmp_type()
out of its lonely misery.
Kurt B. Kaiser [Mon, 12 May 2003 02:33:47 +0000 (02:33 +0000)]
1. RemoteDebugger now runs user code in subprocess MainThread
2. run.py: move exception printing to toplevel to allow access from main()
3. Clarification in PyShell.py: when the subprocess is restarted, the
debugger GUI is reused with a fresh instance of the subprocess
debugger.
Brett Cannon [Sun, 11 May 2003 06:23:36 +0000 (06:23 +0000)]
Beefed up timezone support. UTC and GMT are now always recognized timezones
with values of 0. Also now check time.daylight to see if time.tzname[1]
should be used in timezone checking.
Added a tool for making a rough check of LaTeX documents.
It checks for known commands, forward slashes, unbalanced or
mismatched delimters, and unbalanced or mismatched begin/end blocks.
Kurt B. Kaiser [Sat, 10 May 2003 00:09:52 +0000 (00:09 +0000)]
1. Update debugger to not trace RPC code even when calling Queue and
threading modules. Can debug user code which imports these modules,
though.
2. Re-enable debugger in PyShell.
3. Remove old code implementing previous approaches to this issue.
Jeremy Hylton [Fri, 9 May 2003 16:06:42 +0000 (16:06 +0000)]
Variant of SF patch 614770: MSVC 7 support
distutils now looks for the compiler version in sys.version, falling
back to MSVC 6 if the version isn't listed (Python 2.2 and lower).
Add helper routines for reading the registry. Refactor many
module functions into methods of the compiler to avoid passing
lots of state as arguments.
Jack Jansen [Fri, 9 May 2003 15:08:39 +0000 (15:08 +0000)]
Pass DIRMODE and FILEMODE to Mac/OSX/Makefile on framework builds (and
honor them). Use this when building the MacOSX binary installer to
get group-writeable files.
Ths fix works for directories and executables, not for files just yet,
because of bug #735274.
Just van Rossum [Fri, 9 May 2003 07:53:18 +0000 (07:53 +0000)]
[ 731644] & [ 604210 ] Release the GIL around getaddrinfo(), yet protect
access with lock on those platforms that getaddrinfo() isn't (known to be)
thread-safe. Thanks to MvL for mentoring this patch.
Kurt B. Kaiser [Thu, 8 May 2003 20:26:55 +0000 (20:26 +0000)]
1. Implement processing of user code in subprocess MainThread. Pass loop
is now interruptable on Windows.
2. Tweak signal.signal() wait parameters as called by various methods
to improve I/O response, especially on Windows.
3. Debugger is disabled at this check-in pending further development.
Tim Peters [Thu, 8 May 2003 18:13:59 +0000 (18:13 +0000)]
Leading "C:" no longer hardcoded in the default installation directory.
After removing that, two testers on machines where C: is not the system
drive reported that the installer suggested their system drive instead
of C:, and that's what they wanted it to do.
Barry Warsaw [Thu, 8 May 2003 03:33:15 +0000 (03:33 +0000)]
parsedate_tz(): Be slightly more lenient when there's no day of the
week. Patch given by Daniel Berlin in SF bug # 732761. Also closes
SF bug # 727719.
Greg Ward [Thu, 8 May 2003 01:58:05 +0000 (01:58 +0000)]
SF patch #598163 (Ville Vainio, vvainio@users.sourceforge.net):
add dedent() function, to remove indentation from multiline strings
(eg. triple-quoted strings). Differs from inspect.getdoc() by not
special-casing the first line (often a sensible approach for
non-docstring multiline strings). This should make this function more
general (symmetric 'indent' also possible), and more fitting for the
textwrap module.
SF bug #730296: Unexpected Changes in list Iterator
Reverted a Py2.3b1 change to iterator in subclasses of list and tuple.
They had been changed to use __getitem__ whenever it had been overriden
in the subclass.
This caused some usabilty and performance problems. Also, it was
inconsistent with the rest of python where many container methods
access the underlying object directly without first checking for
an overridden getter. Users needing a change in iterator behavior
should override it directly.
Greg Ward [Wed, 7 May 2003 01:20:58 +0000 (01:20 +0000)]
SF #596434: tweak wordsep_re so the definition of an em-dash is
stricter: specifically, "--" must be preceded by a limited set of
characters, not by any non-whitespace character.
* Increase dictionary growth rate resulting in more sparse dictionaries,
fewer lookup collisions, increased memory use, and better cache
performance. For dicts with over 50k entries, keep the current
growth rate in case an application is suffering from tight memory
constraints.
* Set the most common case (no resize) to fall-through the test.