]> granicus.if.org Git - python/log
python
24 years agoupdate to use new symtable interface
Jeremy Hylton [Fri, 9 Feb 2001 22:57:10 +0000 (22:57 +0000)]
update to use new symtable interface

24 years agoupdate test cases for recent compiler changes: exec/import * in nested
Jeremy Hylton [Fri, 9 Feb 2001 22:56:46 +0000 (22:56 +0000)]
update test cases for recent compiler changes: exec/import * in nested
functinos and cell vars with */** parameters

24 years agoSF patch 103589: Fix handling of cell vars that are either * or ** parameters.
Jeremy Hylton [Fri, 9 Feb 2001 22:55:26 +0000 (22:55 +0000)]
SF patch 103589: Fix handling of cell vars that are either * or ** parameters.
(Nick Mathewson)

Remove to XXX comments

24 years agoRelax the rules for using 'from ... import *' and exec in the presence
Jeremy Hylton [Fri, 9 Feb 2001 22:22:18 +0000 (22:22 +0000)]
Relax the rules for using 'from ... import *' and exec in the presence
of nested functions.  Either is allowed in a function if it contains
no defs or lambdas or the defs and lambdas it contains have no free
variables.  If a function is itself nested and has free variables,
either is illegal.

Revise the symtable to use a PySymtableEntryObject, which holds all
the revelent information for a scope, rather than using a bunch of
st_cur_XXX pointers in the symtable struct.  The changes simplify the
internal management of the current symtable scope and of the stack.

Added new C source file: Python/symtable.c.  (Does the Windows build
process need to be updated?)

As part of these changes, the initial _symtable module interface
introduced in 2.1a2 is replaced.  A dictionary of
PySymtableEntryObjects are returned.

24 years agoWhitespace normalization.
Tim Peters [Fri, 9 Feb 2001 21:23:21 +0000 (21:23 +0000)]
Whitespace normalization.

24 years agoNuke accurate but confusing and unhelpful comments about split vs splitfields.
Tim Peters [Fri, 9 Feb 2001 20:18:41 +0000 (20:18 +0000)]
Nuke accurate but confusing and unhelpful comments about split vs splitfields.

24 years agoWhitespace normalization.
Tim Peters [Fri, 9 Feb 2001 20:17:14 +0000 (20:17 +0000)]
Whitespace normalization.

24 years agoWhitespace normalization.
Tim Peters [Fri, 9 Feb 2001 20:06:00 +0000 (20:06 +0000)]
Whitespace normalization.

24 years agoThis modified version of a patch by Thomas Heller allows __import__
Marc-André Lemburg [Fri, 9 Feb 2001 19:40:15 +0000 (19:40 +0000)]
This modified version of a patch by Thomas Heller allows __import__
hooks to take over the Python import machinery at a very early stage
in the Python startup phase.

If there are still places in the Python interpreter which need to
bypass the __import__ hook, these places must now use
PyImport_ImportModuleEx() instead. So far no other places than in
the import mechanism itself have been identified.

24 years agojoinfields -> join.
Eric S. Raymond [Fri, 9 Feb 2001 17:05:53 +0000 (17:05 +0000)]
joinfields -> join.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 16:56:44 +0000 (16:56 +0000)]
String method conversion.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 16:45:10 +0000 (16:45 +0000)]
String method conversion.

24 years agoFixed syntax error.
Sjoerd Mullender [Fri, 9 Feb 2001 16:34:24 +0000 (16:34 +0000)]
Fixed syntax error.

24 years agosplitfields -> split
Eric S. Raymond [Fri, 9 Feb 2001 16:25:20 +0000 (16:25 +0000)]
splitfields -> split

24 years agoAdded prototype for DlgObj_WhichDialog()
Jack Jansen [Fri, 9 Feb 2001 15:59:18 +0000 (15:59 +0000)]
Added prototype for DlgObj_WhichDialog()

24 years agoReplaced touched(), which no longer seems to work under os9, with something using...
Jack Jansen [Fri, 9 Feb 2001 15:58:34 +0000 (15:58 +0000)]
Replaced touched(), which no longer seems to work under os9, with something using an appleevent to the finder. More expensive, but at least it works:-)

24 years agoAdded a few constants.
Jack Jansen [Fri, 9 Feb 2001 15:57:53 +0000 (15:57 +0000)]
Added a few constants.

24 years agoDialogs and there windows were still confused in some spots. Fixed.
Jack Jansen [Fri, 9 Feb 2001 15:57:01 +0000 (15:57 +0000)]
Dialogs and there windows were still confused in some spots. Fixed.

24 years agoGet rid of from ... import *
Jack Jansen [Fri, 9 Feb 2001 15:56:19 +0000 (15:56 +0000)]
Get rid of from ... import *

24 years agoReindent a function that was somehow indented by 7 spaces. Also did a
Guido van Rossum [Fri, 9 Feb 2001 15:06:42 +0000 (15:06 +0000)]
Reindent a function that was somehow indented by 7 spaces.  Also did a
spaces->tab conversion for fields added to struct compiling.

24 years agoRemove silly EMPTYSTRING global. Saves a global lookup.
Marc-André Lemburg [Fri, 9 Feb 2001 13:37:37 +0000 (13:37 +0000)]
Remove silly EMPTYSTRING global. Saves a global lookup.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 12:20:51 +0000 (12:20 +0000)]
String method conversion.

24 years agoEliminate use of string.whitespace and a string import with it.
Eric S. Raymond [Fri, 9 Feb 2001 12:10:26 +0000 (12:10 +0000)]
Eliminate use of string.whitespace and a string import with it.
Some of the characters (form feed, vertical tab) are not
legal continuation characters anyway, so this was wrong as
well as annoying.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 12:03:45 +0000 (12:03 +0000)]
String method conversion.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 12:00:47 +0000 (12:00 +0000)]
String method conversion.
(This one was trivial -- no actual string. references in it!)

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 11:51:27 +0000 (11:51 +0000)]
String method conversion.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 11:46:37 +0000 (11:46 +0000)]
String method conversion.
(This one was trivial -- no actual string. references in it!)

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 11:14:08 +0000 (11:14 +0000)]
String method conversion.
(This one was trivial -- no actual string. references in it!)

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 11:10:16 +0000 (11:10 +0000)]
String method conversion.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 10:48:30 +0000 (10:48 +0000)]
String method conversion.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 10:30:23 +0000 (10:30 +0000)]
String method conversion.

24 years agoTest with an actual mbox caught a trivial error.
Eric S. Raymond [Fri, 9 Feb 2001 10:28:34 +0000 (10:28 +0000)]
Test with an actual mbox caught a trivial error.

24 years agoCorrection after translation test.
Eric S. Raymond [Fri, 9 Feb 2001 10:26:06 +0000 (10:26 +0000)]
Correction after translation test.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 10:23:55 +0000 (10:23 +0000)]
String method conversion.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 10:18:37 +0000 (10:18 +0000)]
String method conversion.

24 years agoAha. We can remove he string import after all by using ValueError.
Eric S. Raymond [Fri, 9 Feb 2001 10:14:53 +0000 (10:14 +0000)]
Aha.  We can remove he string import after all by using ValueError.

24 years agoUse ValueError instead of string.atoi.error, since we've switched to
Eric S. Raymond [Fri, 9 Feb 2001 10:12:19 +0000 (10:12 +0000)]
Use ValueError instead of string.atoi.error, since we've switched to
int().

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 10:10:02 +0000 (10:10 +0000)]
String method conversion.
(This one was trivial -- no actual string. references in it!)

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 10:06:47 +0000 (10:06 +0000)]
String method conversion.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 09:59:10 +0000 (09:59 +0000)]
String method conversion.

24 years agoPatches for AIX. Checked by Benjamin Collar.
Marc-André Lemburg [Fri, 9 Feb 2001 09:59:06 +0000 (09:59 +0000)]
Patches for AIX. Checked by Benjamin Collar.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 09:48:45 +0000 (09:48 +0000)]
String method conversion.

24 years agoString method conversion. Added a trivial main to test it with.
Eric S. Raymond [Fri, 9 Feb 2001 09:44:47 +0000 (09:44 +0000)]
String method conversion.  Added a trivial main to test it with.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 09:39:08 +0000 (09:39 +0000)]
String method conversion.

24 years agoOops...that will teach me to hit ^C^C too fast. Test passed.
Eric S. Raymond [Fri, 9 Feb 2001 09:21:01 +0000 (09:21 +0000)]
Oops...that will teach me to hit ^C^C too fast.  Test passed.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 09:19:27 +0000 (09:19 +0000)]
String method conversion.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 09:10:35 +0000 (09:10 +0000)]
String method conversion.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 08:56:30 +0000 (08:56 +0000)]
String method conversion.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 08:40:40 +0000 (08:40 +0000)]
String method conversion.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 08:33:43 +0000 (08:33 +0000)]
String method conversion.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 08:25:29 +0000 (08:25 +0000)]
String method conversion.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 07:58:53 +0000 (07:58 +0000)]
String method conversion.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 07:49:30 +0000 (07:49 +0000)]
String method conversion.

24 years agoFixed a bug in the test jig.
Eric S. Raymond [Fri, 9 Feb 2001 07:40:17 +0000 (07:40 +0000)]
Fixed a bug in the test jig.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 07:10:12 +0000 (07:10 +0000)]
String method conversion.

24 years agoSF bug #131225: sys.winver is still '2.0' in python 2.1a2.
Tim Peters [Fri, 9 Feb 2001 07:02:22 +0000 (07:02 +0000)]
SF bug #131225: sys.winver is still '2.0' in python 2.1a2.
SF patch #103683: Alternative dll version resources.
Changes similar to the patch.  MarkH should review.
File version and Product version text strings now 2.1a2.
64-bit file and product version numbers are now
    PY_MAJOR_VERSION, PY_MINOR_VERSION, messy, PYTHON_API_VERSION
where
    messy = PY_MICRO_VERSION*1000 + PY_RELEASE_LEVEL*10 + PY_RELEASE_SERIAL
Updated company name to "Digital Creations 2".
Copyright now lists Guido; "C in a circle" symbol used instead of (C).
Comments added so this is less likely to get flubbed again, and
#if/#error guys added to trigger if the version number manipulations
above overflow.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 07:02:17 +0000 (07:02 +0000)]
String method conversion.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 06:56:56 +0000 (06:56 +0000)]
String method conversion.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 06:50:21 +0000 (06:50 +0000)]
String method conversion.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 05:40:38 +0000 (05:40 +0000)]
String method conversion.

24 years agoCorrection to test main.
Eric S. Raymond [Fri, 9 Feb 2001 05:38:46 +0000 (05:38 +0000)]
Correction to test main.

24 years agoCorrection after second code path test.
Eric S. Raymond [Fri, 9 Feb 2001 05:37:25 +0000 (05:37 +0000)]
Correction after second code path test.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 05:19:09 +0000 (05:19 +0000)]
String method conversion.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 05:07:04 +0000 (05:07 +0000)]
String method conversion.

24 years agoString method conversion.
Eric S. Raymond [Fri, 9 Feb 2001 04:52:11 +0000 (04:52 +0000)]
String method conversion.

24 years agoUpdate documentation for pyexpat (xml.parsers.expat), to reflect the new
Fred Drake [Thu, 8 Feb 2001 15:40:33 +0000 (15:40 +0000)]
Update documentation for pyexpat (xml.parsers.expat), to reflect the new
support for Expat 1.95.*.

24 years agoset_error(): Handle construction of pyexpat.error exceptions. They
Fred Drake [Thu, 8 Feb 2001 15:39:08 +0000 (15:39 +0000)]
set_error():  Handle construction of pyexpat.error exceptions.  They
              now carry a 'code' attribute that gives the Expat error
              number.

Added support for additional handlers for Expat 1.95.*, including
XmlDeclHandler, EntityDeclHandler, ElementDeclHandler, and
AttlistDeclHandler.  Associated constants are in the 'model'
sub-object.

Added two new attributes to the parser object: ordered_attributes and
specified_attributes.  These are used to control how attributes are
reported and which attributes are reported.

24 years agoReplaced by :Lib:cfmfile.py.
Jack Jansen [Thu, 8 Feb 2001 13:17:23 +0000 (13:17 +0000)]
Replaced by :Lib:cfmfile.py.

24 years agoa few more __all__ lists
Skip Montanaro [Wed, 7 Feb 2001 23:14:30 +0000 (23:14 +0000)]
a few more __all__ lists

24 years agotest for presence of __builtins__ in names before deleting it, enabling this
Skip Montanaro [Wed, 7 Feb 2001 22:46:55 +0000 (22:46 +0000)]
test for presence of __builtins__ in names before deleting it, enabling this
to work with Jython (ugh! I hate that name!).  This closes patch 103665.

24 years agoRemove the optional integer argument to SSL_write; now it will always send
Andrew M. Kuchling [Wed, 7 Feb 2001 20:41:17 +0000 (20:41 +0000)]
Remove the optional integer argument to SSL_write; now it will always send
    the entire string passed to it

24 years agoBeOS doesn't have a libm.a, either; noted by Donn Cave
Andrew M. Kuchling [Tue, 6 Feb 2001 23:37:23 +0000 (23:37 +0000)]
BeOS doesn't have a libm.a, either; noted by Donn Cave

24 years agoPatch #103636: Allow writing strings containing null bytes to an SSL socket
Andrew M. Kuchling [Tue, 6 Feb 2001 22:58:05 +0000 (22:58 +0000)]
Patch #103636: Allow writing strings containing null bytes to an SSL socket

24 years agoPatch #103523, to make mpz module compile with Cygwin
Andrew M. Kuchling [Tue, 6 Feb 2001 22:33:45 +0000 (22:33 +0000)]
Patch #103523, to make mpz module compile with Cygwin

24 years agoPart of patch #103544: fix detection of BSDDB on BSD systems
Andrew M. Kuchling [Tue, 6 Feb 2001 22:26:30 +0000 (22:26 +0000)]
Part of patch #103544: fix detection of BSDDB on BSD systems

24 years agoPatch #103578 ] _tkinter build fix for he current Debian unstable tcl/tk 8.3
Andrew M. Kuchling [Tue, 6 Feb 2001 22:15:27 +0000 (22:15 +0000)]
Patch #103578 ] _tkinter build fix for he current Debian unstable tcl/tk 8.3
    packages

24 years agoAdded DlgObj_WhichDialog, analoguous to WhichWindow, and use this to get at dialogs.
Jack Jansen [Tue, 6 Feb 2001 16:14:54 +0000 (16:14 +0000)]
Added DlgObj_WhichDialog, analoguous to WhichWindow, and use this to get at dialogs.

24 years agoQDFlushPortBuffer() has an optional region argument.
Jack Jansen [Tue, 6 Feb 2001 16:13:50 +0000 (16:13 +0000)]
QDFlushPortBuffer() has an optional region argument.

24 years agoInstall shared modules enabled by Setup* in $(DESTSHARED) not
Neil Schemenauer [Tue, 6 Feb 2001 14:50:27 +0000 (14:50 +0000)]
Install shared modules enabled by Setup* in $(DESTSHARED) not
$(DESTSHARED)/Modules.

24 years agoSupport older PYTHON_API_VERSIONs for backwards compatibility.
Martin v. Löwis [Tue, 6 Feb 2001 09:34:40 +0000 (09:34 +0000)]
Support older PYTHON_API_VERSIONs for backwards compatibility.

24 years agoAdd xml declaration into toxml testcase.
Martin v. Löwis [Tue, 6 Feb 2001 01:16:48 +0000 (01:16 +0000)]
Add xml declaration into toxml testcase.

24 years agoDo not allow empty qualifiedName in createDocument.
Martin v. Löwis [Tue, 6 Feb 2001 01:16:06 +0000 (01:16 +0000)]
Do not allow empty qualifiedName in createDocument.
Rearrange pulldom to create documents with root element.
Provide clear methods so that the ContentHandler releases its hold on the
document.

24 years agoadded several more __all__ lists
Skip Montanaro [Tue, 6 Feb 2001 01:07:02 +0000 (01:07 +0000)]
added several more __all__ lists

24 years agoAdd toprettyxml method into minidom, closes patch #103471.
Martin v. Löwis [Tue, 6 Feb 2001 00:14:08 +0000 (00:14 +0000)]
Add toprettyxml method into minidom, closes patch #103471.

24 years agoA couple of changes to make this more conformant. MvL and Uche agree.
Guido van Rossum [Mon, 5 Feb 2001 19:17:50 +0000 (19:17 +0000)]
A couple of changes to make this more conformant.  MvL and Uche agree.
This will make it incompatible with the version found in Python 2.0.
Does this need to be done to PyXML too?

Changes that might break existing code are marked with (!) below.

- Formatting nit: no spaces inside parentheses: foo( a ) -> foo(a).

- Break long lines.

- (!) Fix getAttribute() and getAttributeNS() to return "" instead of
  raising KeyError when the attribute is not found.

- (!) Fix getAttributeNodeNS() to return None instead of raising
  KeyError.  (Curiously, getAttributeNode() already did this.)

- Added hasAttributes(), which returns true iff the node has any
  attributes.  )This is DOM level 3.)

- (!) In createDocument(), if the qualified name is not empty,
  actually create and insert the first element with that name (this
  will become doc.documentElement).  MvL believes that it should be an
  error to specify an empty qualified name; I'm not going there today,
  since it would require making a matching change to pulldom.  Maybe
  MvL will do this.

- In Document.writexml(), insert an xml declaration at the top.  (This
  doesn't include the encoding since there's no way to specify the
  encoding.  If that's preferred, all writexml() methods should be
  fixed to support an optional encoding argument that they pass to
  each other -- and they should use it to encode all text they write,
  too.  Later.)

24 years agoDon't get fooled by an empty prefix with a valid namespaceURI -- in
Guido van Rossum [Mon, 5 Feb 2001 18:50:15 +0000 (18:50 +0000)]
Don't get fooled by an empty prefix with a valid namespaceURI -- in
this case, the code used to generate invalid tags and attribute names
with a leading colon, e.g. <:tag> or <tag :attr="foo">.

24 years agoPatch #103587: Fix typo that broke the install_data command; caught by
Andrew M. Kuchling [Mon, 5 Feb 2001 17:43:11 +0000 (17:43 +0000)]
Patch #103587: Fix typo that broke the install_data command; caught by
   Uche Ogbuji

24 years agoFixed UnboundLocalError for nested scopes
Jeremy Hylton [Mon, 5 Feb 2001 17:36:46 +0000 (17:36 +0000)]
Fixed UnboundLocalError for nested scopes

24 years agoFix test 9 (caught by ?!ng)
Jeremy Hylton [Mon, 5 Feb 2001 17:35:20 +0000 (17:35 +0000)]
Fix test 9 (caught by ?!ng)
Add tests for unbound locals (Nick Mathewson)

24 years agoSF patch 103596 by Nick Mathewson: rause UnboundLocalError for
Jeremy Hylton [Mon, 5 Feb 2001 17:23:16 +0000 (17:23 +0000)]
SF patch 103596 by Nick Mathewson: rause UnboundLocalError for
uninitialized free variables

24 years agoAlso recognize DragRef as a method-argument.
Jack Jansen [Mon, 5 Feb 2001 13:47:13 +0000 (13:47 +0000)]
Also recognize DragRef as a method-argument.

24 years agoWrote section on nested scopes, and moved it to the front
Andrew M. Kuchling [Mon, 5 Feb 2001 02:47:52 +0000 (02:47 +0000)]
Wrote section on nested scopes, and moved it to the front
Began a section on weak references
Various rewrites and paragraph refills
Added: non-recursive makefiles, repr() of strings now uses \n, raw socket I/O
Bumped version number

24 years agoFix binfmt_register documentation to always register the right magic.
Martin v. Löwis [Sun, 4 Feb 2001 22:37:56 +0000 (22:37 +0000)]
Fix binfmt_register documentation to always register the right magic.

24 years agoImprove diagnostic output when an external command returns a non-zero exit
Fred Drake [Sun, 4 Feb 2001 15:20:26 +0000 (15:20 +0000)]
Improve diagnostic output when an external command returns a non-zero exit
code, showing the transcript for that command.

This closes SF bug #129740.

24 years agoAnother _testXXX -> _testcapiXXX renaming.
Tim Peters [Sun, 4 Feb 2001 09:18:21 +0000 (09:18 +0000)]
Another _testXXX -> _testcapiXXX renaming.

24 years agoRenamed _testXXX to _testcapiXXX. Jack is my hero -- good call!
Tim Peters [Sun, 4 Feb 2001 03:09:53 +0000 (03:09 +0000)]
Renamed _testXXX to _testcapiXXX.  Jack is my hero -- good call!

24 years agoSuperseded by $(srcdir)/Makefile.pre.in.
Neil Schemenauer [Sat, 3 Feb 2001 17:18:21 +0000 (17:18 +0000)]
Superseded by $(srcdir)/Makefile.pre.in.

24 years agoTweak clean targets yet again.
Neil Schemenauer [Sat, 3 Feb 2001 17:16:29 +0000 (17:16 +0000)]
Tweak clean targets yet again.

24 years agoClarify the news item about "from M import X" if "M is not a real
Guido van Rossum [Sat, 3 Feb 2001 15:06:40 +0000 (15:06 +0000)]
Clarify the news item about "from M import X" if "M is not a real
module" after a complaint from Tim.

24 years agoFix markup typo in a {verbatim} environment (there should not be any!);
Fred Drake [Sat, 3 Feb 2001 14:35:38 +0000 (14:35 +0000)]
Fix markup typo in a {verbatim} environment (there should not be any!);
caught by Eric Raymond.