Update of /cvsroot/python/python/dist/src/Tools/scripts
In directory slayer.i.sourceforge.net:/tmp/cvs-serv26632/python/dist/src/tools/scripts

Modified Files:
ndiff.py
Log Message:
Hack ndiff to display lines w/ leading tabs more intuitively. This synchs
ndiff w/ a custom version I made for Guido during the pre-2.0 freeze.


Index: ndiff.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Tools/scripts/ndiff.py,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -r1.4 -r1.5
*** ndiff.py 1999/03/28 17:55:32 1.4
--- ndiff.py 2000/11/01 02:51:27 1.5
***************
*** 1,6 ****
#! /usr/bin/env python

! # Module ndiff version 1.4.0
! # Released to the public domain 27-Mar-1999,
# by Tim Peters (tim_one@email.msn.com).

--- 1,6 ----
#! /usr/bin/env python

! # Module ndiff version 1.5.0
! # Released to the public domain 08-Oct-2000,
# by Tim Peters (tim_one@email.msn.com).

***************
*** 29,40 ****

Lines beginning with "? " attempt to guide the eye to intraline
! differences, and were not present in either input file. These lines can
! be confusing if the source files contain tab characters.

The first file can be recovered by retaining only lines that begin with
" " or "- ", and deleting those 2-character prefixes; use ndiff with -r1.

! The second file can be recovered similarly, but by retaining only " "
! and "+ " lines; use ndiff with -r2; or, on Unix, the second file can be
recovered by piping the output through

--- 29,40 ----

Lines beginning with "? " attempt to guide the eye to intraline
! differences, and were not present in either input file. These lines can be
! confusing if the source files contain tab characters.

The first file can be recovered by retaining only lines that begin with
" " or "- ", and deleting those 2-character prefixes; use ndiff with -r1.

! The second file can be recovered similarly, but by retaining only " " and
! "+ " lines; use ndiff with -r2; or, on Unix, the second file can be
recovered by piping the output through

***************
*** 44,48 ****
"""

! __version__ = 1, 4, 0

# SequenceMatcher tries to compute a "human-friendly diff" between
--- 44,48 ----
"""

! __version__ = 1, 5, 0

# SequenceMatcher tries to compute a "human-friendly diff" between
***************
*** 515,520 ****
btags = btags + ' ' * (la - lb)
combined = map(lambda x,y: _combine[x+y], atags, btags)
! print '-', aelt, '+', belt, '?', \
! string.rstrip(string.join(combined, ''))
else:
# the synch pair is identical
--- 515,519 ----
btags = btags + ' ' * (la - lb)
combined = map(lambda x,y: _combine[x+y], atags, btags)
! printq(aelt, belt, string.rstrip(string.join(combined, '')))
else:
# the synch pair is identical
***************
*** 532,535 ****
--- 531,550 ----
elif blo < bhi:
dump('+', b, blo, bhi)
+
+ # Crap to deal with leading tabs in "?" output. Can hurt, but will
+ # probably help most of the time.
+
+ def printq(aline, bline, qline):
+ common = min(count_leading(aline, "\t"),
+ count_leading(bline, "\t"))
+ common = min(common, count_leading(qline[:common], " "))
+ qline = "\t" * common + qline[common:]
+ print '-', aline, '+', bline, '?', qline
+
+ def count_leading(line, ch):
+ i, n = 0, len(line)
+ while i < n and line[i] == ch:
+ i += 1
+ return i

def fail(msg):



From python-dev@python.org Wed Nov 1 03:12:37 2000
From: python-dev@python.org (Fred L. Drake)
Date: Tue, 31 Oct 2000 19:12:37 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib libasyncore.tex,1.5,1.6
Message-ID: <200011010312.TAA28493@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv28479

Modified Files:
libasyncore.tex
Log Message:

Typo: writeable --> writable
Reported by Erno Kuusela <erno@iki.fi>.


Index: libasyncore.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/libasyncore.tex,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -r1.5 -r1.6
*** libasyncore.tex 2000/07/16 19:01:09 1.5
--- libasyncore.tex 2000/11/01 03:12:34 1.6
***************
*** 104,108 ****
\end{methoddesc}

! \begin{methoddesc}{writeable}{}
Each time through the \method{select()} loop, the set of sockets
is scanned, and this method is called to see if there is any
--- 104,108 ----
\end{methoddesc}

! \begin{methoddesc}{writable}{}
Each time through the \method{select()} loop, the set of sockets
is scanned, and this method is called to see if there is any
***************
*** 188,192 ****
print data

! def writeable(self):
return (len(self.buffer) > 0)

--- 188,192 ----
print data

! def writable(self):
return (len(self.buffer) > 0)




From python-dev@python.org Wed Nov 1 19:59:15 2000
From: python-dev@python.org (A.M. Kuchling)
Date: Wed, 1 Nov 2000 11:59:15 -0800
Subject: [Python-checkins] CVS: python/dist/src/Modules _cursesmodule.c,2.39,2.40
Message-ID: <200011011959.LAA13600@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Modules
In directory slayer.i.sourceforge.net:/tmp/cvs-serv13420

Modified Files:
_cursesmodule.c
Log Message:
Patch from Randall Hopper to fix PR #116172, "curses module fails to
build on SGI":
* Check for 'sgi' preprocessor symbol, not '__sgi__'
* Surround individual character macros with #ifdef's, instead of making them
all rely on STRICT_SYSV_CURSES


Index: _cursesmodule.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Modules/_cursesmodule.c,v
retrieving revision 2.39
retrieving revision 2.40
diff -C2 -r2.39 -r2.40
*** _cursesmodule.c 2000/09/01 03:46:16 2.39
--- _cursesmodule.c 2000/11/01 19:59:12 2.40
***************
*** 79,83 ****
#endif

! #if defined(__sgi__) || defined(__sun__)
#define STRICT_SYSV_CURSES /* Don't use ncurses extensions */
typedef chtype attr_t; /* No attr_t type is available */
--- 79,91 ----
#endif

! #ifdef sgi
! /* This prototype is in <term.h>, but including this header #defines
! many common symbols (such as "lines") which breaks the curses
! module in other ways. So the code will just specify an explicit
! prototype here. */
! extern char *tigetstr(char *);
! #endif
!
! #if defined(sgi) || defined(__sun__)
#define STRICT_SYSV_CURSES /* Don't use ncurses extensions */
typedef chtype attr_t; /* No attr_t type is available */
***************
*** 1740,1750 ****
SetDictInt("ACS_SBSB", (ACS_VLINE));
SetDictInt("ACS_SSSS", (ACS_PLUS));
! #ifndef STRICT_SYSV_CURSES
! /* The following are never available with strict SYSV curses */
SetDictInt("ACS_S3", (ACS_S3));
SetDictInt("ACS_LEQUAL", (ACS_LEQUAL));
SetDictInt("ACS_GEQUAL", (ACS_GEQUAL));
SetDictInt("ACS_PI", (ACS_PI));
SetDictInt("ACS_NEQUAL", (ACS_NEQUAL));
SetDictInt("ACS_STERLING", (ACS_STERLING));
#endif
--- 1748,1772 ----
SetDictInt("ACS_SBSB", (ACS_VLINE));
SetDictInt("ACS_SSSS", (ACS_PLUS));
!
! /* The following are never available with strict SYSV curses */
! #ifdef ACS_S3
SetDictInt("ACS_S3", (ACS_S3));
+ #endif
+ #ifdef ACS_S7
+ SetDictInt("ACS_S7", (ACS_S7));
+ #endif
+ #ifdef ACS_LEQUAL
SetDictInt("ACS_LEQUAL", (ACS_LEQUAL));
+ #endif
+ #ifdef ACS_GEQUAL
SetDictInt("ACS_GEQUAL", (ACS_GEQUAL));
+ #endif
+ #ifdef ACS_PI
SetDictInt("ACS_PI", (ACS_PI));
+ #endif
+ #ifdef ACS_NEQUAL
SetDictInt("ACS_NEQUAL", (ACS_NEQUAL));
+ #endif
+ #ifdef ACS_STERLING
SetDictInt("ACS_STERLING", (ACS_STERLING));
#endif
***************
*** 2271,2280 ****
SetDictInt("A_CHARTEXT", A_CHARTEXT);
SetDictInt("A_COLOR", A_COLOR);
! #ifndef STRICT_SYSV_CURSES
SetDictInt("A_HORIZONTAL", A_HORIZONTAL);
SetDictInt("A_LEFT", A_LEFT);
SetDictInt("A_LOW", A_LOW);
SetDictInt("A_RIGHT", A_RIGHT);
SetDictInt("A_TOP", A_TOP);
SetDictInt("A_VERTICAL", A_VERTICAL);
#endif
--- 2293,2314 ----
SetDictInt("A_CHARTEXT", A_CHARTEXT);
SetDictInt("A_COLOR", A_COLOR);
!
! /* The following are never available with strict SYSV curses */
! #ifdef A_HORIZONTAL
SetDictInt("A_HORIZONTAL", A_HORIZONTAL);
+ #endif
+ #ifdef A_LEFT
SetDictInt("A_LEFT", A_LEFT);
+ #endif
+ #ifdef A_LOW
SetDictInt("A_LOW", A_LOW);
+ #endif
+ #ifdef A_RIGHT
SetDictInt("A_RIGHT", A_RIGHT);
+ #endif
+ #ifdef A_TOP
SetDictInt("A_TOP", A_TOP);
+ #endif
+ #ifdef A_VERTICAL
SetDictInt("A_VERTICAL", A_VERTICAL);
#endif



From python-dev@python.org Wed Nov 1 22:03:03 2000
From: python-dev@python.org (Moshe Zadka)
Date: Wed, 1 Nov 2000 14:03:03 -0800
Subject: [Python-checkins] CVS: python/nondist/sf-html sf-faq.html,1.15,1.16
Message-ID: <200011012203.OAA03403@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/sf-html
In directory slayer.i.sourceforge.net:/tmp/cvs-serv3265

Modified Files:
sf-faq.html
Log Message:
Changed description of bug report procedures.


Index: sf-faq.html
==================================================================RCS file: /cvsroot/python/python/nondist/sf-html/sf-faq.html,v
retrieving revision 1.15
retrieving revision 1.16
diff -C2 -r1.15 -r1.16
*** sf-faq.html 2000/08/25 07:55:48 1.15
--- sf-faq.html 2000/11/01 22:03:00 1.16
***************
*** 58,62 ****
<ol>
<li><a href="#b1">Where can I submit/view bugs for Python?</a></li>
! <li><a href="#b2">How do I use jitterbug?</a></li>
</ol>

--- 58,62 ----
<ol>
<li><a href="#b1">Where can I submit/view bugs for Python?</a></li>
! <li><a href="#b2">How do I use the sourceforge bug manager?</a></li>
</ol>

***************
*** 447,471 ****

<h4>A:</h4>
! As of now [25-Jul-200] the Python project does not use SourceForge's bug
! tracking facility. This may change when there is a way to import the existing
! jitterbug database. The jitterbug database can be accessed through the
! following interface:

- <blockquote>
- <tt><a
- href="http://www.python.org/python-bugs">http://www.python.org/python-bugs</a></tt></blockquote>
-
<h3><a name="b1" id="b1"></a>6.1.:</h3>

! <h4>Q: How do I use jitterbug?</h4>

<h4>A:</h4>
! To get the list of open bugs click on <tt>open</tt> (hidden between the second
! last and the last horizontal ruler).

! <p>To get a list of the bugs which are related to some area, enter an
! appropriate regular expression and press "Select Messages". Then select
! <tt>open</tt> (or whatever category you would like to view) as described
! above.</p>

<h1><a name="appendix" id="appendix"></a>A. Appendix</h1>
--- 447,465 ----

<h4>A:</h4>
! The Python project uses SourceForge's bug
! tracking facility. Go to
! <a href="http://sourceforge.net/bugs/?group_idT70">http://sourceforge.net/bugs/?group_idT70</a> for all bug management needs.

<h3><a name="b1" id="b1"></a>6.1.:</h3>

! <h4>Q: How do I use the sourceforge bug manager?</h4>

<h4>A:</h4>
! By default, you will see the list of all Open bugs. You can change
! which bugs you're viewing by selecting the assigned_to/status/area/type
! select boxes.

! <p>To submit a bug, use the "Submit a Bug" link, near the top of the page.
! </p>

<h1><a name="appendix" id="appendix"></a>A. Appendix</h1>
***************
*** 601,606 ****
submission. The patch manager is for <b>patches</b> only; if you have a
problem or suggestion but don't know how to write the code for it, use the
! <a href="http://www.python.org/search/search_bugs.html">Python Bugs
! List</a> instead. The bugs list is searchable; if you have a problem and
you're not sure if it has been reported or fixed already, this is the
first place to look. (There used to be a separate TODO list; we now prefer
--- 595,600 ----
submission. The patch manager is for <b>patches</b> only; if you have a
problem or suggestion but don't know how to write the code for it, use the
! <a href="#b1">bug reporting mechanism</a> instead.
! The bugs list is searchable; if you have a problem and
you're not sure if it has been reported or fixed already, this is the
first place to look. (There used to be a separate TODO list; we now prefer
***************
*** 609,615 ****
way.</b> When adding the patch, be sure to set the "<b>Category</b>" field
to "<b>documentation</b>". For documentation errors without patches,
! please use the <a
! href="http://www.python.org/search/search_bugs.html">Python Bugs List</a>
! instead.</li>
<li>We like context diffs. We grudgingly accept unified diffs. <b>Straight
("ed-style") diffs are right out!</b> If you don't know how to generate
--- 603,607 ----
way.</b> When adding the patch, be sure to set the "<b>Category</b>" field
to "<b>documentation</b>". For documentation errors without patches,
! please use the <a href="#b1">bug reporting mechanism</a>.</li>
<li>We like context diffs. We grudgingly accept unified diffs. <b>Straight
("ed-style") diffs are right out!</b> If you don't know how to generate



From python-dev@python.org Wed Nov 1 22:28:46 2000
From: python-dev@python.org (Moshe Zadka)
Date: Wed, 1 Nov 2000 14:28:46 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0042.txt,1.40,1.41
Message-ID: <200011012228.OAA05685@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv5018

Modified Files:
pep-0042.txt
Log Message:
- Added PyX_Update() addition to the API request (120081)
- Added vars() enhancement request (120082)


Index: pep-0042.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0042.txt,v
retrieving revision 1.40
retrieving revision 1.41
diff -C2 -r1.40 -r1.41
*** pep-0042.txt 2000/10/30 20:48:44 1.40
--- pep-0042.txt 2000/11/01 22:28:42 1.41
***************
*** 81,84 ****
--- 81,95 ----
http://sourceforge.net/bugs/?funcÞtailbug&bug_id6405&group_idT70

+ - The C API should include a PyDict_Update() function which takes a
+ dictionary as its first argument, and an arbitrary mapping as its
+ second. Similarly there should probably be a PyMapping_Update() in the
+ abstract API (and several other dictionary methods in there too).
+
+ http://sourceforge.net/bugs/?funcÞtailbug&bug_id2081&group_idT70
+
+ - Inside a function, vars() should include both locals() and globals()
+
+ http://sourceforge.net/bugs/?funcÞtailbug&bug_id2082&group_idT70
+
Standard Library




From python-dev@python.org Wed Nov 1 22:37:39 2000
From: python-dev@python.org (Thomas Wouters)
Date: Wed, 1 Nov 2000 14:37:39 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0204.txt,1.4,1.5
Message-ID: <200011012237.OAA06642@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv6200

Modified Files:
pep-0204.txt
Log Message:

Update this PEP to current, harsh, reality. It's been rejected :) If at all
possible, the reasoning should be extended to include the real reasons it
was rejected -- this is just guesswork from my side. (This means you, Guido,
or anyone who can channel Guido enough to call himself Guido.)



Index: pep-0204.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0204.txt,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -r1.4 -r1.5
*** pep-0204.txt 2000/08/23 05:41:57 1.4
--- pep-0204.txt 2000/11/01 22:37:36 1.5
***************
*** 3,7 ****
Version: $Revision$
Author: thomas@xs4all.net (Thomas Wouters)
! Status: Draft
Type: Standards Track
Python-Version: 2.0
--- 3,7 ----
Version: $Revision$
Author: thomas@xs4all.net (Thomas Wouters)
! Status: Rejected
Type: Standards Track
Python-Version: 2.0
***************
*** 263,267 ****
to be classified: are they part of the API, or should they be
made private functions?
!

References:
--- 263,281 ----
to be classified: are they part of the API, or should they be
made private functions?
!
!
! Rejection
!
! After careful consideration, and a period of meditation, this
! proposal has been rejected. The open issues, as well as some
! confusion between ranges and slice syntax, raised enough questions
! for Guido not to accept it for Python 2.0, and later to reject the
! proposal altogether. The new syntax and its intentions were deemed
! not obvious enough.
!
! [ TBD: Guido, ammend/confirm this, please. Preferably both; this
! is a PEP, it should contain *all* the reasons for rejection
! and/or reconsideration, for future reference. ]
!

References:



From python-dev@python.org Wed Nov 1 22:43:45 2000
From: python-dev@python.org (Thomas Wouters)
Date: Wed, 1 Nov 2000 14:43:45 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0204.txt,1.5,1.6
Message-ID: <200011012243.OAA07233@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv7213

Modified Files:
pep-0204.txt
Log Message:

Add Copyright.



Index: pep-0204.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0204.txt,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -r1.5 -r1.6
*** pep-0204.txt 2000/11/01 22:37:36 1.5
--- pep-0204.txt 2000/11/01 22:43:42 1.6
***************
*** 279,282 ****
--- 279,287 ----


+ Copyright
+
+ This document has been placed in the Public Domain.
+
+
References:




From python-dev@python.org Wed Nov 1 23:45:50 2000
From: python-dev@python.org (Thomas Wouters)
Date: Wed, 1 Nov 2000 15:45:50 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep2html.py,1.15,1.16
Message-ID: <200011012345.PAA12044@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv12019

Modified Files:
pep2html.py
Log Message:

Add -u and --user options to the call to getopt, to make them actually work.



Index: pep2html.py
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep2html.py,v
retrieving revision 1.15
retrieving revision 1.16
diff -C2 -r1.15 -r1.16
*** pep2html.py 2000/09/08 15:31:36 1.15
--- pep2html.py 2000/11/01 23:45:47 1.16
***************
*** 192,197 ****

try:
! opts, args = getopt.getopt(sys.argv[1:], 'ihq',
! ['install', 'help', 'quiet'])
except getopt.error, msg:
usage(1, msg)
--- 192,197 ----

try:
! opts, args = getopt.getopt(sys.argv[1:], 'ihqu:',
! ['install', 'help', 'quiet', 'user='])
except getopt.error, msg:
usage(1, msg)



From python-dev@python.org Thu Nov 2 08:05:41 2000
From: python-dev@python.org (Moshe Zadka)
Date: Thu, 2 Nov 2000 00:05:41 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0217.txt,1.2,1.3
Message-ID: <200011020805.AAA24917@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv24852

Modified Files:
pep-0217.txt
Log Message:
Added some more meat to the PEP
Added a section about Jython issues.


Index: pep-0217.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0217.txt,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** pep-0217.txt 2000/08/23 05:50:32 1.2
--- pep-0217.txt 2000/11/02 08:05:38 1.3
***************
*** 2,6 ****
Title: Display Hook for Interactive Use
Version: $Revision$
! Author: moshez@math.huji.ac.il (Moshe Zadka)
Status: Draft
Type: Standards Track
--- 2,6 ----
Title: Display Hook for Interactive Use
Version: $Revision$
! Author: peps@zadka.site.co.il (Moshe Zadka)
Status: Draft
Type: Standards Track
***************
*** 21,24 ****
--- 21,44 ----
interactive interpreter.

+ Solution
+
+ The bytecode PRINT_EXPR will call sys.displayhook(POP())
+ A displayhook() will be added to the sys builtin module, which is
+ equivalent to
+
+ import __builtin__
+ def displayhook(o):
+ if o is None:
+ return
+ __builtin__._ = o
+ print o
+
+ Jython Issues
+
+ The author knows too little about Jython, but it is very important
+ to be compatible with it. displayhook will have to be added to sys,
+ but since Jython works with Java bytecodes, the compiler would have
+ to be changed too, or maybe not.
+ Barry?





From python-dev@python.org Thu Nov 2 16:18:27 2000
From: python-dev@python.org (Barry Warsaw)
Date: Thu, 2 Nov 2000 08:18:27 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0227.txt,NONE,1.1
Message-ID: <200011021618.IAA15298@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv15290

Added Files:
pep-0227.txt
Log Message:
PEP 227, Statically Nested Scopes, Jeremy Hylton


***** Error reading new file: (2, 'No such file or directory')


From python-dev@python.org Thu Nov 2 16:19:09 2000
From: python-dev@python.org (Barry Warsaw)
Date: Thu, 2 Nov 2000 08:19:09 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0000.txt,1.40,1.41
Message-ID: <200011021619.IAA15368@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv15358

Modified Files:
pep-0000.txt
Log Message:
Added PEP 227, Statically Nested Scopes, Jeremy Hylton


Index: pep-0000.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0000.txt,v
retrieving revision 1.40
retrieving revision 1.41
diff -C2 -r1.40 -r1.41
*** pep-0000.txt 2000/10/30 21:16:38 1.40
--- pep-0000.txt 2000/11/02 16:19:06 1.41
***************
*** 56,59 ****
--- 56,60 ----
SD 225 pep-0225.txt Elementwise/Objectwise Operators Zhu, Lielens
I 226 pep-0226.txt Python 2.1 Release Schedule Hylton
+ S 227 pep-0227.txt Statically Nested Scopes Hylton





From python-dev@python.org Thu Nov 2 16:38:18 2000
From: python-dev@python.org (Barry Warsaw)
Date: Thu, 2 Nov 2000 08:38:18 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0000.txt,1.41,1.42
Message-ID: <200011021638.IAA16894@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv16886

Modified Files:
pep-0000.txt
Log Message:
Update PEP 204 status to Rejected.


Index: pep-0000.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0000.txt,v
retrieving revision 1.41
retrieving revision 1.42
diff -C2 -r1.41 -r1.42
*** pep-0000.txt 2000/11/02 16:19:06 1.41
--- pep-0000.txt 2000/11/02 16:38:15 1.42
***************
*** 33,37 ****
S 202 pep-0202.txt List Comprehensions Peters
SF 203 pep-0203.txt Augmented Assignments Wouters
! S 204 pep-0204.txt Range Literals Wouters
SD 205 pep-0205.txt Weak References Drake
I 206 pep-0206.txt 2.0 Batteries Included Zadka
--- 33,37 ----
S 202 pep-0202.txt List Comprehensions Peters
SF 203 pep-0203.txt Augmented Assignments Wouters
! SR 204 pep-0204.txt Range Literals Wouters
SD 205 pep-0205.txt Weak References Drake
I 206 pep-0206.txt 2.0 Batteries Included Zadka



From python-dev@python.org Thu Nov 2 16:43:34 2000
From: python-dev@python.org (Barry Warsaw)
Date: Thu, 2 Nov 2000 08:43:34 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0000.txt,1.42,1.43
Message-ID: <200011021643.IAA17418@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv17409

Modified Files:
pep-0000.txt
Log Message:
Mark PEP 200 as Final now that 2.0 is out the door.


Index: pep-0000.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0000.txt,v
retrieving revision 1.42
retrieving revision 1.43
diff -C2 -r1.42 -r1.43
*** pep-0000.txt 2000/11/02 16:38:15 1.42
--- pep-0000.txt 2000/11/02 16:43:32 1.43
***************
*** 29,33 ****
I 160 pep-0160.txt Python 1.6 Release Schedule Drake

! I 200 pep-0200.txt Python 2.0 Release Schedule Hylton
SF 201 pep-0201.txt Lockstep Iteration Warsaw
S 202 pep-0202.txt List Comprehensions Peters
--- 29,33 ----
I 160 pep-0160.txt Python 1.6 Release Schedule Drake

! IF 200 pep-0200.txt Python 2.0 Release Schedule Hylton
SF 201 pep-0201.txt Lockstep Iteration Warsaw
S 202 pep-0202.txt List Comprehensions Peters



From python-dev@python.org Thu Nov 2 16:44:06 2000
From: python-dev@python.org (Barry Warsaw)
Date: Thu, 2 Nov 2000 08:44:06 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0200.txt,1.45,1.46
Message-ID: <200011021644.IAA17466@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv17455

Modified Files:
pep-0200.txt
Log Message:
Mark status as Final, remove "Tentative" from Release Schedule.


Index: pep-0200.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0200.txt,v
retrieving revision 1.45
retrieving revision 1.46
diff -C2 -r1.45 -r1.46
*** pep-0200.txt 2000/10/30 20:48:44 1.45
--- pep-0200.txt 2000/11/02 16:44:04 1.46
***************
*** 4,8 ****
Owner: Jeremy Hylton <jeremy@digicool.com>
Python-Version: 2.0
! Status: Incomplete


--- 4,8 ----
Owner: Jeremy Hylton <jeremy@digicool.com>
Python-Version: 2.0
! Status: Final


***************
*** 16,20 ****
historical record.

! Tentative Release Schedule
[revised 5 Oct 2000]

--- 16,20 ----
historical record.

! Release Schedule
[revised 5 Oct 2000]




From python-dev@python.org Thu Nov 2 16:54:22 2000
From: python-dev@python.org (Guido van Rossum)
Date: Thu, 2 Nov 2000 08:54:22 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0042.txt,1.41,1.42
Message-ID: <200011021654.IAA18474@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv18457

Modified Files:
pep-0042.txt
Log Message:
Remove two rejected feature requests.


Index: pep-0042.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0042.txt,v
retrieving revision 1.41
retrieving revision 1.42
diff -C2 -r1.41 -r1.42
*** pep-0042.txt 2000/11/01 22:28:42 1.41
--- pep-0042.txt 2000/11/02 16:54:19 1.42
***************
*** 81,95 ****
http://sourceforge.net/bugs/?funcÞtailbug&bug_id6405&group_idT70

- - The C API should include a PyDict_Update() function which takes a
- dictionary as its first argument, and an arbitrary mapping as its
- second. Similarly there should probably be a PyMapping_Update() in the
- abstract API (and several other dictionary methods in there too).
-
- http://sourceforge.net/bugs/?funcÞtailbug&bug_id2081&group_idT70
-
- - Inside a function, vars() should include both locals() and globals()
-
- http://sourceforge.net/bugs/?funcÞtailbug&bug_id2082&group_idT70
-
Standard Library

--- 81,84 ----



From python-dev@python.org Thu Nov 2 17:52:59 2000
From: python-dev@python.org (Fred L. Drake)
Date: Thu, 2 Nov 2000 09:52:59 -0800
Subject: [Python-checkins] CVS: python/dist/src configure.in,1.175,1.176
Message-ID: <200011021752.JAA23302@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src
In directory slayer.i.sourceforge.net:/tmp/cvs-serv23294

Modified Files:
configure.in
Log Message:

Make sure the Modules/ directory is created before writing Modules/Setup.


Index: configure.in
==================================================================RCS file: /cvsroot/python/python/dist/src/configure.in,v
retrieving revision 1.175
retrieving revision 1.176
diff -C2 -r1.175 -r1.176
*** configure.in 2000/10/30 17:45:07 1.175
--- configure.in 2000/11/02 17:52:56 1.176
***************
*** 1301,1304 ****
--- 1301,1307 ----
AC_MSG_CHECKING(for Modules/Setup)
if test ! -f Modules/Setup ; then
+ if test ! -d Modules ; then
+ mkdir Modules
+ fi
cp "$srcdir/Modules/Setup.dist" Modules/Setup
AC_MSG_RESULT(creating)



From python-dev@python.org Thu Nov 2 19:33:56 2000
From: python-dev@python.org (Guido van Rossum)
Date: Thu, 2 Nov 2000 11:33:56 -0800
Subject: [Python-checkins] CVS: python/dist/src configure,1.167,1.168
Message-ID: <200011021933.LAA31933@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src
In directory slayer.i.sourceforge.net:/tmp/cvs-serv31920

Modified Files:
configure
Log Message:
New configure script from latest configure.in with autoconf 2.13

Index: configure
==================================================================RCS file: /cvsroot/python/python/dist/src/configure,v
retrieving revision 1.167
retrieving revision 1.168
diff -C2 -r1.167 -r1.168
*** configure 2000/10/30 17:45:07 1.167
--- configure 2000/11/02 19:33:53 1.168
***************
*** 1,5 ****
#! /bin/sh

! # From configure.in Revision: 1.175

# Guess values for system-dependent variables and create Makefiles.
--- 1,5 ----
#! /bin/sh

! # From configure.in Revision: 1.176

# Guess values for system-dependent variables and create Makefiles.
***************
*** 5976,5979 ****
--- 5976,5982 ----
echo "configure:5977: checking for Modules/Setup" >&5
if test ! -f Modules/Setup ; then
+ if test ! -d Modules ; then
+ mkdir Modules
+ fi
cp "$srcdir/Modules/Setup.dist" Modules/Setup
echo "$ac_t""creating" 1>&6



From python-dev@python.org Thu Nov 2 21:49:42 2000
From: python-dev@python.org (Fred L. Drake)
Date: Thu, 2 Nov 2000 13:49:42 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/ext ext.tex,1.87,1.88
Message-ID: <200011022149.NAA22985@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/ext
In directory slayer.i.sourceforge.net:/tmp/cvs-serv22968

Modified Files:
ext.tex
Log Message:

Fix cut & paste error that describes three paramters when there are only
two [bug #119729].

Update use of distutils.sysconfig that "broke" when Greg W. changed the API
[bug #119645].


Index: ext.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/ext/ext.tex,v
retrieving revision 1.87
retrieving revision 1.88
diff -C2 -r1.87 -r1.88
*** ext.tex 2000/10/26 17:19:58 1.87
--- ext.tex 2000/11/02 21:49:17 1.88
***************
*** 719,726 ****

The variant reads one C variable and stores into two C variables, the
! first one a pointer to an encoding name string (\var{encoding}), the
second a pointer to a pointer to a character buffer (\var{**buffer},
! the buffer used for storing the encoded data) and the third one a
! pointer to an integer (\var{*buffer_length}, the buffer length).

The encoding name must map to a registered codec. If set to \NULL{},
--- 719,725 ----

The variant reads one C variable and stores into two C variables, the
! first one a pointer to an encoding name string (\var{encoding}), and the
second a pointer to a pointer to a character buffer (\var{**buffer},
! the buffer used for storing the encoded data).

The encoding name must map to a registered codec. If set to \NULL{},
***************
*** 2139,2143 ****
\begin{verbatim}
import distutils.sysconfig
! >>> distutils.sysconfig.LINKFORSHARED
'-Xlinker -export-dynamic'
\end{verbatim}
--- 2138,2142 ----
\begin{verbatim}
import distutils.sysconfig
! >>> distutils.sysconfig.get_config_var('LINKFORSHARED')
'-Xlinker -export-dynamic'
\end{verbatim}



From python-dev@python.org Thu Nov 2 21:51:55 2000
From: python-dev@python.org (Thomas Wouters)
Date: Thu, 2 Nov 2000 13:51:55 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0204.txt,1.6,1.7
Message-ID: <200011022151.NAA23108@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv23090

Modified Files:
pep-0204.txt
Log Message:

Small whitespace 'fix', to test checkins.



Index: pep-0204.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0204.txt,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -r1.6 -r1.7
*** pep-0204.txt 2000/11/01 22:43:42 1.6
--- pep-0204.txt 2000/11/02 21:51:53 1.7
***************
*** 159,163 ****
literals. In slices, `end' would default to the end of the list,
but this has no meaning in range literals.
!

Reference Implementation
--- 159,163 ----
literals. In slices, `end' would default to the end of the list,
but this has no meaning in range literals.
!

Reference Implementation



From python-dev@python.org Thu Nov 2 23:53:53 2000
From: python-dev@python.org (Moshe Zadka)
Date: Thu, 2 Nov 2000 15:53:53 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0217.txt,1.3,1.4
Message-ID: <200011022353.PAA03931@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv3904

Modified Files:
pep-0217.txt
Log Message:
Added Jython solution
Added abstract interface specification.
(Motivation is in the abstract)


Index: pep-0217.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0217.txt,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** pep-0217.txt 2000/11/02 08:05:38 1.3
--- pep-0217.txt 2000/11/02 23:53:51 1.4
***************
*** 21,24 ****
--- 21,35 ----
interactive interpreter.

+ Interface
+
+ The current Python solution has worked for many users, and this
+ should not break it. Therefore, in the default configuration,
+ nothing will change in the REPL loop. To change the way the
+ interpreter prints interactively entered expressions, users
+ will have to rebind sys.displayhook to a callable object.
+ The result of calling this object with the result of the
+ interactively entered expression should be print-able,
+ and this is what will be printed on sys.stdout.
+
Solution

***************
*** 31,44 ****
if o is None:
return
__builtin__._ = o
- print o

Jython Issues

! The author knows too little about Jython, but it is very important
! to be compatible with it. displayhook will have to be added to sys,
! but since Jython works with Java bytecodes, the compiler would have
! to be changed too, or maybe not.
! Barry?


--- 42,52 ----
if o is None:
return
+ __builtin__._ = None
+ print `o`
__builtin__._ = o

Jython Issues

! The method Py.printResult will be similarily changed.





From python-dev@python.org Fri Nov 3 02:08:17 2000
From: python-dev@python.org (fidan latifi)
Date: Fri, 03 Nov 2000 02:08:17 GMT
Subject: [Python-checkins] null(2139,2143
Message-ID: <F84cOrBLSAQV6uPDVni0000917a@hotmail.com>

_________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.

Share information about yourself, create your own public profile at
http://profiles.msn.com.



From python-dev@python.org Fri Nov 3 02:08:30 2000
From: python-dev@python.org (fidan latifi)
Date: Fri, 03 Nov 2000 02:08:30 GMT
Subject: [Python-checkins] null(2139,2143
Message-ID: <F86pgk0BYACaRzsGwh800008f25@hotmail.com>

_________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.

Share information about yourself, create your own public profile at
http://profiles.msn.com.



From python-dev@python.org Fri Nov 3 02:56:07 2000
From: python-dev@python.org (Guido van Rossum)
Date: Thu, 2 Nov 2000 18:56:07 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0000.txt,1.43,1.44
Message-ID: <200011030256.SAA03410@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv3399

Modified Files:
pep-0000.txt
Log Message:
Added an index by category.


Index: pep-0000.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0000.txt,v
retrieving revision 1.43
retrieving revision 1.44
diff -C2 -r1.43 -r1.44
*** pep-0000.txt 2000/11/02 16:43:32 1.43
--- pep-0000.txt 2000/11/03 02:56:05 1.44
***************
*** 15,22 ****


! Index

num filename title owner
--- ------------ ----- -----
I 0 pep-0000.txt Index of Python Enhancement Proposals Warsaw
I 1 pep-0001.txt PEP Guidelines Warsaw, Hylton
--- 15,85 ----


! Index by Category

num filename title owner
--- ------------ ----- -----
+
+ Meta-PEPs (PEPs about PEPs)
+
+ I 0 pep-0000.txt Index of Python Enhancement Proposals Warsaw
+ I 1 pep-0001.txt PEP Guidelines Warsaw, Hylton
+ I 2 pep-0002.txt Procedure for Adding New Modules Raymond
+ I 3 pep-0003.txt Guidelines for Handling Bug Reports Hylton
+ I 4 pep-0004.txt Deprecation of Standard Modules von Loewis
+ I 5 pep-0005.txt Guidelines for Language Evolution Prescod
+
+ Active PEPs (under serious consideration for Python 2.1 - even if empty)
+
+ I 42 pep-0042.txt Small Feature Requests Hylton
+ S 207 pep-0207.txt Rich Comparisons Ascher
+ S 208 pep-0208.txt Reworking the Coercion Model Ascher
+ S 217 pep-0217.txt Display Hook for Interactive Use Zadka
+ S 222 pep-0222.txt Web Library Enhancements Kuchling
+ I 226 pep-0226.txt Python 2.1 Release Schedule Hylton
+ S 227 pep-0227.txt Statically Nested Scopes Hylton
+
+ Pie-in-the-sky PEPs (not ready; may become active yet)
+
+ I 206 pep-0206.txt 2.0 Batteries Included Zadka
+ SD 211 pep-0211.txt Adding New Linear Algebra Operators Wilson
+ SD 212 pep-0212.txt Loop Counter Iteration Schneider-Kamp
+ SD 213 pep-0213.txt Attribute Access Handlers Prescod
+ SD 224 pep-0224.txt Attribute Docstrings Lemburg
+ SD 225 pep-0225.txt Elementwise/Objectwise Operators Zhu, Lielens
+
+ Incomplete PEPs (only an abstract)
+
+ SD 218 pep-0218.txt Adding a Built-In Set Object Type Wilson
+ SD 219 pep-0219.txt Stackless Python McMillan
+ I 220 pep-0220.txt Coroutines, Generators, Continuations McMillan
+
+ Empty PEPs (nothing written yet)
+
+ SD 205 pep-0205.txt Weak References Drake
+ SD 209 pep-0209.txt Adding Multidimensional Arrays Ascher
+ SD 210 pep-0210.txt Decoupling the Interpreter Loop Ascher
+ SD 215 pep-0215.txt String Interpolation Yee
+ I 216 pep-0216.txt Docstring Format Zadka
+
+ Finished PEPs (done, implemented)
+
+ I 160 pep-0160.txt Python 1.6 Release Schedule Drake
+ IF 200 pep-0200.txt Python 2.0 Release Schedule Hylton
+ SF 201 pep-0201.txt Lockstep Iteration Warsaw
+ S 202 pep-0202.txt List Comprehensions Peters
+ SF 203 pep-0203.txt Augmented Assignments Wouters
+ SF 214 pep-0214.txt Extended Print Statement Warsaw
+ SF 221 pep-0221.txt Import As Wouters
+ SF 223 pep-0223.txt Change the Meaning of \x Escapes Peters
+
+ Rejected PEPs
+
+ SR 204 pep-0204.txt Range Literals Wouters
+
+
+ Numerical Index
+
+ num filename title owner
+ --- ------------ ----- -----
I 0 pep-0000.txt Index of Python Enhancement Proposals Warsaw
I 1 pep-0001.txt PEP Guidelines Warsaw, Hylton
***************
*** 36,41 ****
SD 205 pep-0205.txt Weak References Drake
I 206 pep-0206.txt 2.0 Batteries Included Zadka
! SD 207 pep-0207.txt Rich Comparisons Ascher
! SD 208 pep-0208.txt Reworking the Coercion Model Ascher
SD 209 pep-0209.txt Adding Multidimensional Arrays Ascher
SD 210 pep-0210.txt Decoupling the Interpreter Loop Ascher
--- 99,104 ----
SD 205 pep-0205.txt Weak References Drake
I 206 pep-0206.txt 2.0 Batteries Included Zadka
! S 207 pep-0207.txt Rich Comparisons Ascher
! S 208 pep-0208.txt Reworking the Coercion Model Ascher
SD 209 pep-0209.txt Adding Multidimensional Arrays Ascher
SD 210 pep-0210.txt Decoupling the Interpreter Loop Ascher
***************
*** 46,57 ****
SD 215 pep-0215.txt String Interpolation Yee
I 216 pep-0216.txt Docstring Format Zadka
! SD 217 pep-0217.txt Display Hook for Interactive Use Zadka
SD 218 pep-0218.txt Adding a Built-In Set Object Type Wilson
SD 219 pep-0219.txt Stackless Python McMillan
I 220 pep-0220.txt Coroutines, Generators, Continuations McMillan
SF 221 pep-0221.txt Import As Wouters
! SD 222 pep-0222.txt Web Library Enhancements Kuchling
SF 223 pep-0223.txt Change the Meaning of \x Escapes Peters
! S 224 pep-0224.txt Attribute Docstrings Lemburg
SD 225 pep-0225.txt Elementwise/Objectwise Operators Zhu, Lielens
I 226 pep-0226.txt Python 2.1 Release Schedule Hylton
--- 109,120 ----
SD 215 pep-0215.txt String Interpolation Yee
I 216 pep-0216.txt Docstring Format Zadka
! S 217 pep-0217.txt Display Hook for Interactive Use Zadka
SD 218 pep-0218.txt Adding a Built-In Set Object Type Wilson
SD 219 pep-0219.txt Stackless Python McMillan
I 220 pep-0220.txt Coroutines, Generators, Continuations McMillan
SF 221 pep-0221.txt Import As Wouters
! S 222 pep-0222.txt Web Library Enhancements Kuchling
SF 223 pep-0223.txt Change the Meaning of \x Escapes Peters
! SD 224 pep-0224.txt Attribute Docstrings Lemburg
SD 225 pep-0225.txt Elementwise/Objectwise Operators Zhu, Lielens
I 226 pep-0226.txt Python 2.1 Release Schedule Hylton



From python-dev@python.org Fri Nov 3 02:57:35 2000
From: python-dev@python.org (Fred L. Drake)
Date: Thu, 2 Nov 2000 18:57:35 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/tools mkhowto,1.17,1.18
Message-ID: <200011030257.SAA03504@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/tools
In directory slayer.i.sourceforge.net:/tmp/cvs-serv3491/tools

Modified Files:
mkhowto
Log Message:

Make sure we clean up the index data each time it is written by LaTeX.


Index: mkhowto
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/tools/mkhowto,v
retrieving revision 1.17
retrieving revision 1.18
diff -C2 -r1.17 -r1.18
*** mkhowto 2000/09/20 05:49:09 1.17
--- mkhowto 2000/11/03 02:57:31 1.18
***************
*** 280,284 ****
--- 280,286 ----
if os.path.isfile("mod%s.idx" % self.doc):
self.run("%s mod%s.idx" % (MAKEINDEX_BINARY, self.doc))
+ use_indfix = 0
if os.path.isfile(self.doc + ".idx"):
+ use_indfix = 1
# call to Doc/tools/fix_hack omitted; doesn't appear necessary
self.run("%s %s.idx" % (MAKEINDEX_BINARY, self.doc))
***************
*** 296,302 ****
self.run("%s -s %s mod%s.idx"
% (MAKEINDEX_BINARY, ISTFILE, self.doc))
! if os.path.isfile(self.doc + ".idx"):
self.run("%s -s %s %s.idx"
% (MAKEINDEX_BINARY, ISTFILE, self.doc))
self.process_synopsis_files()
#
--- 298,305 ----
self.run("%s -s %s mod%s.idx"
% (MAKEINDEX_BINARY, ISTFILE, self.doc))
! if use_indfix:
self.run("%s -s %s %s.idx"
% (MAKEINDEX_BINARY, ISTFILE, self.doc))
+ indfix.process(self.doc + ".ind")
self.process_synopsis_files()
#



From python-dev@python.org Fri Nov 3 08:18:40 2000
From: python-dev@python.org (Thomas Wouters)
Date: Fri, 3 Nov 2000 00:18:40 -0800
Subject: [Python-checkins] CVS: python/dist/src/Demo/pysvr pysvr.c,1.8,1.9
Message-ID: <200011030818.AAA28198@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Demo/pysvr
In directory slayer.i.sourceforge.net:/tmp/cvs-serv27629/Demo/pysvr

Modified Files:
pysvr.c
Log Message:

Move our own getopt() implementation to _PyOS_GetOpt(), and use it
regardless of whether the system getopt() does what we want. This avoids the
hassle with prototypes and externs, and the check to see if the system
getopt() does what we want. Prefix optind, optarg and opterr with _PyOS_ to
avoid name clashes. Add new include file to define the right symbols. Fix
Demo/pyserv/pyserv.c to include getopt.h itself, instead of relying on
Python to provide it.



Index: pysvr.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Demo/pysvr/pysvr.c,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -r1.8 -r1.9
*** pysvr.c 2000/07/22 19:25:51 1.8
--- pysvr.c 2000/11/03 08:18:37 1.9
***************
*** 20,23 ****
--- 20,24 ----

#include <pthread.h>
+ #include <getopt.h>

/* XXX Umpfh.
***************
*** 32,39 ****
#define PORT 4000
#endif
-
- extern int optind;
- extern char *optarg;
- extern int getopt(int, char **, char *);

struct workorder {
--- 33,36 ----



From python-dev@python.org Fri Nov 3 08:18:40 2000
From: python-dev@python.org (Thomas Wouters)
Date: Fri, 3 Nov 2000 00:18:40 -0800
Subject: [Python-checkins] CVS: python/dist/src/Python Makefile.in,2.26,2.27 getopt.c,2.8,2.9
Message-ID: <200011030818.AAA28209@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Python
In directory slayer.i.sourceforge.net:/tmp/cvs-serv27629/Python

Modified Files:
Makefile.in getopt.c
Log Message:

Move our own getopt() implementation to _PyOS_GetOpt(), and use it
regardless of whether the system getopt() does what we want. This avoids the
hassle with prototypes and externs, and the check to see if the system
getopt() does what we want. Prefix optind, optarg and opterr with _PyOS_ to
avoid name clashes. Add new include file to define the right symbols. Fix
Demo/pyserv/pyserv.c to include getopt.h itself, instead of relying on
Python to provide it.



Index: Makefile.in
==================================================================RCS file: /cvsroot/python/python/dist/src/Python/Makefile.in,v
retrieving revision 2.26
retrieving revision 2.27
diff -C2 -r2.26 -r2.27
*** Makefile.in 2000/08/23 21:16:10 2.26
--- Makefile.in 2000/11/03 08:18:37 2.27
***************
*** 47,51 ****
pyfpe.o pystate.o pythonrun.o \
structmember.o sysmodule.o \
! traceback.o \
$(DYNLOADFILE) \
$(LIBOBJS)
--- 47,51 ----
pyfpe.o pystate.o pythonrun.o \
structmember.o sysmodule.o \
! traceback.o getopt.o \
$(DYNLOADFILE) \
$(LIBOBJS)

Index: getopt.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Python/getopt.c,v
retrieving revision 2.8
retrieving revision 2.9
diff -C2 -r2.8 -r2.9
*** getopt.c 2000/07/22 18:47:25 2.8
--- getopt.c 2000/11/03 08:18:37 2.9
***************
*** 28,73 ****
#include <string.h>

! #define bool int
! #ifndef TRUE
! #define TRUE 1
! #endif
! #ifndef FALSE
! #define FALSE 0
! #endif
!
! bool opterr = TRUE; /* generate error messages */
! int optind = 1; /* index into argv array */
! char * optarg = NULL; /* optional argument */
!
!
! #ifndef __BEOS__
! int getopt(int argc, char *argv[], char optstring[])
! #else
! int getopt(int argc, char *const *argv, const char *optstring)
! #endif
{
! static char *opt_ptr = "";
! register char *ptr;
! int option;

if (*opt_ptr == '\0') {

! if (optind >= argc || argv[optind][0] != '-' ||
! argv[optind][1] == '\0' /* lone dash */ )
return -1;

! else if (strcmp(argv[optind], "--") == 0) {
! ++optind;
return -1;
}

! opt_ptr = &argv[optind++][1];
}

if ( (option = *opt_ptr++) == '\0')
! return -1;

if ((ptr = strchr(optstring, option)) == NULL) {
! if (opterr)
fprintf(stderr, "Unknown option: -%c\n", option);

--- 28,60 ----
#include <string.h>

! int _PyOS_opterr = 1; /* generate error messages */
! int _PyOS_optind = 1; /* index into argv array */
! char *_PyOS_optarg = NULL; /* optional argument */
!
! int _PyOS_GetOpt(int argc, char **argv, char *optstring)
{
! static char *opt_ptr = "";
! char *ptr;
! int option;

if (*opt_ptr == '\0') {

! if (_PyOS_optind >= argc || argv[_PyOS_optind][0] != '-' ||
! argv[_PyOS_optind][1] == '\0' /* lone dash */ )
return -1;

! else if (strcmp(argv[_PyOS_optind], "--") == 0) {
! ++_PyOS_optind;
return -1;
}

! opt_ptr = &argv[_PyOS_optind++][1];
}

if ( (option = *opt_ptr++) == '\0')
! return -1;

if ((ptr = strchr(optstring, option)) == NULL) {
! if (_PyOS_opterr)
fprintf(stderr, "Unknown option: -%c\n", option);

***************
*** 77,87 ****
if (*(ptr + 1) == ':') {
if (*opt_ptr != '\0') {
! optarg = opt_ptr;
opt_ptr = "";
}

else {
! if (optind >= argc) {
! if (opterr)
fprintf(stderr,
"Argument expected for the -%c option\n", option);
--- 64,74 ----
if (*(ptr + 1) == ':') {
if (*opt_ptr != '\0') {
! _PyOS_optarg = opt_ptr;
opt_ptr = "";
}

else {
! if (_PyOS_optind >= argc) {
! if (_PyOS_opterr)
fprintf(stderr,
"Argument expected for the -%c option\n", option);
***************
*** 89,93 ****
}

! optarg = argv[optind++];
}
}
--- 76,80 ----
}

! _PyOS_optarg = argv[_PyOS_optind++];
}
}



From python-dev@python.org Fri Nov 3 08:18:40 2000
From: python-dev@python.org (Thomas Wouters)
Date: Fri, 3 Nov 2000 00:18:40 -0800
Subject: [Python-checkins] CVS: python/dist/src configure,1.168,1.169 configure.in,1.176,1.177
Message-ID: <200011030818.AAA28202@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src
In directory slayer.i.sourceforge.net:/tmp/cvs-serv27629

Modified Files:
configure configure.in
Log Message:

Move our own getopt() implementation to _PyOS_GetOpt(), and use it
regardless of whether the system getopt() does what we want. This avoids the
hassle with prototypes and externs, and the check to see if the system
getopt() does what we want. Prefix optind, optarg and opterr with _PyOS_ to
avoid name clashes. Add new include file to define the right symbols. Fix
Demo/pyserv/pyserv.c to include getopt.h itself, instead of relying on
Python to provide it.



Index: configure
==================================================================RCS file: /cvsroot/python/python/dist/src/configure,v
retrieving revision 1.168
retrieving revision 1.169
diff -C2 -r1.168 -r1.169
*** configure 2000/11/02 19:33:53 1.168
--- configure 2000/11/03 08:18:36 1.169
***************
*** 4840,4844 ****

/* Ultrix mips cc rejects this. */
! typedef int charset[2]; const charset x;
/* SunOS 4.1.1 cc rejects this. */
char const *const *ccp;
--- 4840,4844 ----

/* Ultrix mips cc rejects this. */
! typedef int charset[2]; const charset x = {0,0};
/* SunOS 4.1.1 cc rejects this. */
char const *const *ccp;
***************
*** 4915,4919 ****

int main() {
! } $ac_kw foo() {
; return 0; }
EOF
--- 4915,4919 ----

int main() {
! } int $ac_kw foo() {
; return 0; }
EOF
***************
*** 5626,5670 ****
LIBS=$LIBS_SAVE

- # check for getopt
- echo $ac_n "checking for genuine getopt""... $ac_c" 1>&6
- echo "configure:5631: checking for genuine getopt" >&5
- if eval "test \"`echo '$''{'ac_cv_func_getopt'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
- if test "$cross_compiling" = yes; then
- ac_cv_func_getopt=no
- else
- cat > conftest.$ac_ext <<EOF
- #line 5639 "configure"
- #include "confdefs.h"
- #include <stdio.h>
- extern int optind, opterr, getopt();
- extern char* optarg;
- int main() {
- char* av[] = { "testprog", "parameter", "-fFlag", NULL };
- opterr = 0;
- if (getopt(3, av, "f:") == 'f') { exit(1); }
- exit(0);
- }
- EOF
- if { (eval echo configure:5651: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
- then
- ac_cv_func_getopt=yes
- else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -fr conftest*
- ac_cv_func_getopt=no
- fi
- rm -fr conftest*
- fi
-
- fi
- echo "$ac_t""$ac_cv_func_getopt" 1>&6
- test $ac_cv_func_getopt = no && LIBOBJS="$LIBOBJS getopt.o"
-
# check whether malloc(0) returns NULL or not
echo $ac_n "checking what malloc(0) returns""... $ac_c" 1>&6
! echo "configure:5669: checking what malloc(0) returns" >&5
if eval "test \"`echo '$''{'ac_cv_malloc_zero'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
--- 5626,5632 ----
LIBS=$LIBS_SAVE

# check whether malloc(0) returns NULL or not
echo $ac_n "checking what malloc(0) returns""... $ac_c" 1>&6
! echo "configure:5631: checking what malloc(0) returns" >&5
if eval "test \"`echo '$''{'ac_cv_malloc_zero'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
***************
*** 5674,5678 ****
else
cat > conftest.$ac_ext <<EOF
! #line 5677 "configure"
#include "confdefs.h"
#include <stdio.h>
--- 5636,5640 ----
else
cat > conftest.$ac_ext <<EOF
! #line 5639 "configure"
#include "confdefs.h"
#include <stdio.h>
***************
*** 5693,5697 ****
}
EOF
! if { (eval echo configure:5696: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_malloc_zero=nonnull
--- 5655,5659 ----
}
EOF
! if { (eval echo configure:5658: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_malloc_zero=nonnull
***************
*** 5719,5733 ****
ac_safe=`echo "wchar.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for wchar.h""... $ac_c" 1>&6
! echo "configure:5722: checking for wchar.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5727 "configure"
#include "confdefs.h"
#include <wchar.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
! { (eval echo configure:5732: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
--- 5681,5695 ----
ac_safe=`echo "wchar.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for wchar.h""... $ac_c" 1>&6
! echo "configure:5684: checking for wchar.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5689 "configure"
#include "confdefs.h"
#include <wchar.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
! { (eval echo configure:5694: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
***************
*** 5759,5768 ****
usable_wchar_t="unkown"
echo $ac_n "checking for usable wchar_t""... $ac_c" 1>&6
! echo "configure:5762: checking for usable wchar_t" >&5
if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
! #line 5767 "configure"
#include "confdefs.h"

--- 5721,5730 ----
usable_wchar_t="unkown"
echo $ac_n "checking for usable wchar_t""... $ac_c" 1>&6
! echo "configure:5724: checking for usable wchar_t" >&5
if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
! #line 5729 "configure"
#include "confdefs.h"

***************
*** 5778,5782 ****

EOF
! if { (eval echo configure:5781: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
cat >> confdefs.h <<\EOF
--- 5740,5744 ----

EOF
! if { (eval echo configure:5743: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
cat >> confdefs.h <<\EOF
***************
*** 5797,5801 ****
# check for endianness
echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
! echo "configure:5800: checking whether byte ordering is bigendian" >&5
if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
--- 5759,5763 ----
# check for endianness
echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
! echo "configure:5762: checking whether byte ordering is bigendian" >&5
if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
***************
*** 5804,5808 ****
# See if sys/param.h defines the BYTE_ORDER macro.
cat > conftest.$ac_ext <<EOF
! #line 5807 "configure"
#include "confdefs.h"
#include <sys/types.h>
--- 5766,5770 ----
# See if sys/param.h defines the BYTE_ORDER macro.
cat > conftest.$ac_ext <<EOF
! #line 5769 "configure"
#include "confdefs.h"
#include <sys/types.h>
***************
*** 5815,5823 ****
; return 0; }
EOF
! if { (eval echo configure:5818: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
# It does; now see whether it defined to BIG_ENDIAN or not.
cat > conftest.$ac_ext <<EOF
! #line 5822 "configure"
#include "confdefs.h"
#include <sys/types.h>
--- 5777,5785 ----
; return 0; }
EOF
! if { (eval echo configure:5780: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
# It does; now see whether it defined to BIG_ENDIAN or not.
cat > conftest.$ac_ext <<EOF
! #line 5784 "configure"
#include "confdefs.h"
#include <sys/types.h>
***************
*** 5830,5834 ****
; return 0; }
EOF
! if { (eval echo configure:5833: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_bigendian=yes
--- 5792,5796 ----
; return 0; }
EOF
! if { (eval echo configure:5795: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_bigendian=yes
***************
*** 5850,5854 ****
else
cat > conftest.$ac_ext <<EOF
! #line 5853 "configure"
#include "confdefs.h"
main () {
--- 5812,5816 ----
else
cat > conftest.$ac_ext <<EOF
! #line 5815 "configure"
#include "confdefs.h"
main () {
***************
*** 5863,5867 ****
}
EOF
! if { (eval echo configure:5866: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_bigendian=no
--- 5825,5829 ----
}
EOF
! if { (eval echo configure:5828: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_bigendian=no
***************
*** 5890,5894 ****
# or fills with zeros (like the Cray J90, according to Tim Peters).
echo $ac_n "checking whether right shift extends the sign bit""... $ac_c" 1>&6
! echo "configure:5893: checking whether right shift extends the sign bit" >&5
if eval "test \"`echo '$''{'ac_cv_rshift_extends_sign'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
--- 5852,5856 ----
# or fills with zeros (like the Cray J90, according to Tim Peters).
echo $ac_n "checking whether right shift extends the sign bit""... $ac_c" 1>&6
! echo "configure:5855: checking whether right shift extends the sign bit" >&5
if eval "test \"`echo '$''{'ac_cv_rshift_extends_sign'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
***************
*** 5899,5903 ****
else
cat > conftest.$ac_ext <<EOF
! #line 5902 "configure"
#include "confdefs.h"

--- 5861,5865 ----
else
cat > conftest.$ac_ext <<EOF
! #line 5864 "configure"
#include "confdefs.h"

***************
*** 5908,5912 ****

EOF
! if { (eval echo configure:5911: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_rshift_extends_sign=yes
--- 5870,5874 ----

EOF
! if { (eval echo configure:5873: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_rshift_extends_sign=yes
***************
*** 5940,5949 ****
EOF
echo $ac_n "checking for socklen_t""... $ac_c" 1>&6
! echo "configure:5943: checking for socklen_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_socklen_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5948 "configure"
#include "confdefs.h"
#include <sys/types.h>
--- 5902,5911 ----
EOF
echo $ac_n "checking for socklen_t""... $ac_c" 1>&6
! echo "configure:5905: checking for socklen_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_socklen_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5910 "configure"
#include "confdefs.h"
#include <sys/types.h>
***************
*** 5974,5978 ****

echo $ac_n "checking for Modules/Setup""... $ac_c" 1>&6
! echo "configure:5977: checking for Modules/Setup" >&5
if test ! -f Modules/Setup ; then
if test ! -d Modules ; then
--- 5936,5940 ----

echo $ac_n "checking for Modules/Setup""... $ac_c" 1>&6
! echo "configure:5939: checking for Modules/Setup" >&5
if test ! -f Modules/Setup ; then
if test ! -d Modules ; then

Index: configure.in
==================================================================RCS file: /cvsroot/python/python/dist/src/configure.in,v
retrieving revision 1.176
retrieving revision 1.177
diff -C2 -r1.176 -r1.177
*** configure.in 2000/11/02 17:52:56 1.176
--- configure.in 2000/11/03 08:18:36 1.177
***************
*** 1205,1224 ****
LIBS=$LIBS_SAVE

- # check for getopt
- AC_MSG_CHECKING(for genuine getopt)
- AC_CACHE_VAL(ac_cv_func_getopt,
- [AC_TRY_RUN([#include <stdio.h>
- extern int optind, opterr, getopt();
- extern char* optarg;
- int main() {
- char* av[] = { "testprog", "parameter", "-fFlag", NULL };
- opterr = 0;
- if (getopt(3, av, "f:") == 'f') { exit(1); }
- exit(0);
- }], ac_cv_func_getopt=yes, ac_cv_func_getopt=no, ac_cv_func_getopt=no)])dnl
- AC_MSG_RESULT($ac_cv_func_getopt)
- test $ac_cv_func_getopt = no && LIBOBJS="$LIBOBJS getopt.o"
- AC_SUBST(LIBOBJS)dnl
-
# check whether malloc(0) returns NULL or not
AC_MSG_CHECKING(what malloc(0) returns)
--- 1205,1208 ----



From python-dev@python.org Fri Nov 3 08:18:40 2000
From: python-dev@python.org (Thomas Wouters)
Date: Fri, 3 Nov 2000 00:18:40 -0800
Subject: [Python-checkins] CVS: python/dist/src/Include pygetopt.h,NONE,2.1
Message-ID: <200011030818.AAA28197@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Include
In directory slayer.i.sourceforge.net:/tmp/cvs-serv27629/Include

Added Files:
pygetopt.h
Log Message:

Move our own getopt() implementation to _PyOS_GetOpt(), and use it
regardless of whether the system getopt() does what we want. This avoids the
hassle with prototypes and externs, and the check to see if the system
getopt() does what we want. Prefix optind, optarg and opterr with _PyOS_ to
avoid name clashes. Add new include file to define the right symbols. Fix
Demo/pyserv/pyserv.c to include getopt.h itself, instead of relying on
Python to provide it.



--- NEW FILE ---

#ifndef Py_PYGETOPT_H
#define Py_PYGETOPT_H
#ifdef __cplusplus
extern "C" {
#endif

extern DL_IMPORT(int) _PyOS_opterr;
extern DL_IMPORT(int) _PyOS_optind;
extern DL_IMPORT(char *) _PyOS_optarg;

DL_IMPORT(int) _PyOS_GetOpt(int argc, char **argv, char *optstring);

#ifdef __cplusplus
}
#endif
#endif /* !Py_PYGETOPT_H */



From python-dev@python.org Fri Nov 3 08:18:40 2000
From: python-dev@python.org (Thomas Wouters)
Date: Fri, 3 Nov 2000 00:18:40 -0800
Subject: [Python-checkins] CVS: python/dist/src/Modules main.c,1.45,1.46
Message-ID: <200011030818.AAA28208@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Modules
In directory slayer.i.sourceforge.net:/tmp/cvs-serv27629/Modules

Modified Files:
main.c
Log Message:

Move our own getopt() implementation to _PyOS_GetOpt(), and use it
regardless of whether the system getopt() does what we want. This avoids the
hassle with prototypes and externs, and the check to see if the system
getopt() does what we want. Prefix optind, optarg and opterr with _PyOS_ to
avoid name clashes. Add new include file to define the right symbols. Fix
Demo/pyserv/pyserv.c to include getopt.h itself, instead of relying on
Python to provide it.



Index: main.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Modules/main.c,v
retrieving revision 1.45
retrieving revision 1.46
diff -C2 -r1.45 -r1.46
*** main.c 2000/09/15 18:40:42 1.45
--- main.c 2000/11/03 08:18:37 1.46
***************
*** 18,30 ****
#endif

#define COPYRIGHT \
"Type \"copyright\", \"credits\" or \"license\" for more information."

- /* Interface to getopt(): */
- extern int optind;
- extern char *optarg;
- extern int getopt(); /* PROTO((int, char **, char *)); -- not standardized */
-
-
/* For Py_GetArgcArgv(); set by main() */
static char **orig_argv;
--- 18,26 ----
#endif

+ #include "pygetopt.h"
+
#define COPYRIGHT \
"Type \"copyright\", \"credits\" or \"license\" for more information."

/* For Py_GetArgcArgv(); set by main() */
static char **orig_argv;
***************
*** 106,119 ****
unbuffered = 1;

! while ((c = getopt(argc, argv, "c:diOStuUvxXhV")) != EOF) {
if (c == 'c') {
/* -c is the last option; following arguments
that look like options are left for the
the command to interpret. */
! command = malloc(strlen(optarg) + 2);
if (command == NULL)
Py_FatalError(
"not enough memory to copy -c argument");
! strcpy(command, optarg);
strcat(command, "\n");
break;
--- 102,115 ----
unbuffered = 1;

! while ((c = _PyOS_GetOpt(argc, argv, "c:diOStuUvxXhV")) != EOF) {
if (c == 'c') {
/* -c is the last option; following arguments
that look like options are left for the
the command to interpret. */
! command = malloc(strlen(_PyOS_optarg) + 2);
if (command == NULL)
Py_FatalError(
"not enough memory to copy -c argument");
! strcpy(command, _PyOS_optarg);
strcat(command, "\n");
break;
***************
*** 182,189 ****
}

! if (command == NULL && optind < argc &&
! strcmp(argv[optind], "-") != 0)
{
! filename = argv[optind];
if (filename != NULL) {
if ((fp = fopen(filename, "r")) == NULL) {
--- 178,185 ----
}

! if (command == NULL && _PyOS_optind < argc &&
! strcmp(argv[_PyOS_optind], "-") != 0)
{
! filename = argv[_PyOS_optind];
if (filename != NULL) {
if ((fp = fopen(filename, "r")) == NULL) {
***************
*** 254,263 ****

if (command != NULL) {
! /* Backup optind and force sys.argv[0] = '-c' */
! optind--;
! argv[optind] = "-c";
}

! PySys_SetArgv(argc-optind, argv+optind);

if ((inspect || (command == NULL && filename == NULL)) &&
--- 250,259 ----

if (command != NULL) {
! /* Backup _PyOS_optind and force sys.argv[0] = '-c' */
! _PyOS_optind--;
! argv[_PyOS_optind] = "-c";
}

! PySys_SetArgv(argc-_PyOS_optind, argv+_PyOS_optind);

if ((inspect || (command == NULL && filename == NULL)) &&



From python-dev@python.org Fri Nov 3 12:58:11 2000
From: python-dev@python.org (Guido van Rossum)
Date: Fri, 3 Nov 2000 04:58:11 -0800
Subject: [Python-checkins] CVS: python/dist/src/Demo/pysvr Makefile,1.3,1.4
Message-ID: <200011031258.EAA32272@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Demo/pysvr
In directory slayer.i.sourceforge.net:/tmp/cvs-serv32260

Modified Files:
Makefile
Log Message:
Fix Makefile so at least it uses Python 2.0, and compiles out of the
box on Linux.


Index: Makefile
==================================================================RCS file: /cvsroot/python/python/dist/src/Demo/pysvr/Makefile,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** Makefile 1997/08/14 19:48:42 1.3
--- Makefile 2000/11/03 12:58:09 1.4
***************
*** 14,18 ****
# Where Python is installed, and which version
INST=/usr/local
! VER=1.5

# Expressions using the above definitions -- no need to change
--- 14,18 ----
# Where Python is installed, and which version
INST=/usr/local
! VER=2.0

# Expressions using the above definitions -- no need to change
***************
*** 29,33 ****
# (See LIBS= in Modules/Makefile in build tree)
RLLIBS=-lreadline -ltermcap
! OTHERLIBS=-lsocket -lnsl -lpthread -ldl -lm

# Compilation and link flags -- no need to change normally
--- 29,33 ----
# (See LIBS= in Modules/Makefile in build tree)
RLLIBS=-lreadline -ltermcap
! OTHERLIBS=-lnsl -lpthread -ldl -lm -ldb -lutil

# Compilation and link flags -- no need to change normally



From python-dev@python.org Fri Nov 3 15:42:23 2000
From: python-dev@python.org (Barry Warsaw)
Date: Fri, 3 Nov 2000 07:42:23 -0800
Subject: [Python-checkins] CVS: python/nondist/peps Makefile,1.1,1.2
Message-ID: <200011031542.HAA19766@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19757

Modified Files:
Makefile
Log Message:
Added `install' and `clean' targets.


Index: Makefile
==================================================================RCS file: /cvsroot/python/python/nondist/peps/Makefile,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** Makefile 2000/09/07 01:29:32 1.1
--- Makefile 2000/11/03 15:42:20 1.2
***************
*** 4,8 ****
# Not really important, but convenient.

! PEP2HTML=./pep2html.py -q

.SUFFIXES: .txt .html
--- 4,8 ----
# Not really important, but convenient.

! PEP2HTML=./pep2html.py

.SUFFIXES: .txt .html
***************
*** 14,15 ****
--- 14,21 ----

all: $(TARGETS)
+
+ install:
+ $(PEP2HTML) -i
+
+ clean:
+ -rm *.html



From python-dev@python.org Fri Nov 3 15:43:31 2000
From: python-dev@python.org (Barry Warsaw)
Date: Fri, 3 Nov 2000 07:43:31 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep2html.py,1.16,1.17
Message-ID: <200011031543.HAA19847@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19838

Modified Files:
pep2html.py
Log Message:
Document -q/--quiet in the module docstring.


Index: pep2html.py
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep2html.py,v
retrieving revision 1.16
retrieving revision 1.17
diff -C2 -r1.16 -r1.17
*** pep2html.py 2000/11/01 23:45:47 1.16
--- pep2html.py 2000/11/03 15:43:28 1.17
***************
*** 20,23 ****
--- 20,26 ----
ignored.

+ -q/--quiet
+ Turn off verbose messages.
+
-h/--help
Print this help message and exit.



From python-dev@python.org Fri Nov 3 20:24:17 2000
From: python-dev@python.org (Fredrik Lundh)
Date: Fri, 3 Nov 2000 12:24:17 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib/test/output test_unicodedata,1.3,1.4
Message-ID: <200011032024.MAA26242@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib/test/output
In directory slayer.i.sourceforge.net:/tmp/cvs-serv25791/lib/test/output

Modified Files:
test_unicodedata
Log Message:


Added 38,642 missing characters to the Unicode database (first-last
ranges) -- but thanks to the 2.0 compression scheme, this doesn't add
a single byte to the resulting binaries (!)

Closes bug #117524

Index: test_unicodedata
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/test/output/test_unicodedata,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** test_unicodedata 2000/09/27 12:25:14 1.3
--- test_unicodedata 2000/11/03 20:24:15 1.4
***************
*** 1,5 ****
test_unicodedata
Testing Unicode Database...
! Methods: 86793e1265f3cf5506e6ede8f69ab4deb973f3ea
! Functions: 5abd7e976848725e58f5834a0e5e37615f40d3a2
API: ok
--- 1,5 ----
test_unicodedata
Testing Unicode Database...
! Methods: 6c7a7c02657b69d0fdd7a7d174f573194bba2e18
! Functions: 41e1d4792185d6474a43c83ce4f593b1bdb01f8a
API: ok



From python-dev@python.org Fri Nov 3 20:24:17 2000
From: python-dev@python.org (Fredrik Lundh)
Date: Fri, 3 Nov 2000 12:24:17 -0800
Subject: [Python-checkins] CVS: python/dist/src/Objects unicodetype_db.h,1.2,1.3
Message-ID: <200011032024.MAA26233@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Objects
In directory slayer.i.sourceforge.net:/tmp/cvs-serv25791/Objects

Modified Files:
unicodetype_db.h
Log Message:


Added 38,642 missing characters to the Unicode database (first-last
ranges) -- but thanks to the 2.0 compression scheme, this doesn't add
a single byte to the resulting binaries (!)

Closes bug #117524

Index: unicodetype_db.h
==================================================================RCS file: /cvsroot/python/python/dist/src/Objects/unicodetype_db.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** unicodetype_db.h 2000/09/25 23:03:33 1.2
--- unicodetype_db.h 2000/11/03 20:24:15 1.3
***************
*** 1,3 ****
! /* this file was generated by Tools\unicode\makeunicodedata.py 1.1 */

/* a list of unique character type descriptors */
--- 1,3 ----
! /* this file was generated by tools\unicode\makeunicodedata.py 1.1 */

/* a list of unique character type descriptors */
***************
*** 151,231 ****
172, 173, 174, 90, 48, 175, 90, 48, 176, 177, 178, 48, 48, 179, 127, 36,
36, 124, 23, 146, 180, 23, 181, 182, 183, 23, 23, 23, 184, 23, 23, 185,
! 183, 186, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 187, 36, 36, 186, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 188, 36,
36, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 52, 189, 190, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 186, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 191, 36, 36, 192,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 193, 192, 36, 36, 193, 192, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 193, 192, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
--- 151,231 ----
172, 173, 174, 90, 48, 175, 90, 48, 176, 177, 178, 48, 48, 179, 127, 36,
36, 124, 23, 146, 180, 23, 181, 182, 183, 23, 23, 23, 184, 23, 23, 185,
! 183, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 186, 36, 36, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 187, 36,
36, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 52, 188, 189, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 190, 36, 36, 191,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 192, 191, 36, 36, 192, 191, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 192, 191, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
***************
*** 238,245 ****
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 193, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 194, 36, 36, 36, 36, 36, 36, 195, 196, 197, 48, 48, 198, 199,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 200, 201, 48, 202, 48, 203, 204,
! 36, 151, 205, 206, 48, 48, 48, 207, 208, 2, 209, 210, 48, 211, 212, 213,
};

--- 238,245 ----
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 192, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 193, 36, 36, 36, 36, 36, 36, 194, 195, 196, 48, 48, 197, 198,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 199, 200, 48, 201, 48, 202, 203,
! 36, 151, 204, 205, 48, 48, 48, 206, 207, 2, 208, 209, 48, 210, 211, 212,
};

***************
*** 532,549 ****
1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0,
! 0, 40, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 40, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 40, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1,
! 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 40, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 40, 40, 40, 40, 40,
! 40, 40, 40, 40, 40, 40, 40, 40, 40, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 16, 16, 16, 16, 16, 16, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 16, 16, 16, 16, 16, 0, 0, 0, 0, 0, 40, 1, 40, 40, 40, 40, 40,
40, 40, 40, 40, 40, 1, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40,
40, 0, 40, 40, 40, 40, 40, 0, 40, 0, 40, 40, 0, 40, 40, 0, 40, 40, 40,
--- 532,548 ----
1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0,
! 0, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40,
! 40, 40, 40, 40, 40, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 40, 40, 40, 40, 40, 40,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1,
! 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 40, 40, 40, 40, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 40, 40, 40, 40,
! 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 16, 16, 16, 16, 16, 16, 16, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 16, 16, 16, 16, 16, 0, 0, 0, 0, 0, 40, 1, 40, 40, 40, 40, 40,
40, 40, 40, 40, 40, 1, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40,
40, 0, 40, 40, 40, 40, 40, 0, 40, 0, 40, 40, 0, 40, 40, 0, 40, 40, 40,



From python-dev@python.org Fri Nov 3 20:24:17 2000
From: python-dev@python.org (Fredrik Lundh)
Date: Fri, 3 Nov 2000 12:24:17 -0800
Subject: [Python-checkins] CVS: python/dist/src/Modules unicodedata_db.h,1.2,1.3
Message-ID: <200011032024.MAA26244@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Modules
In directory slayer.i.sourceforge.net:/tmp/cvs-serv25791/Modules

Modified Files:
unicodedata_db.h
Log Message:


Added 38,642 missing characters to the Unicode database (first-last
ranges) -- but thanks to the 2.0 compression scheme, this doesn't add
a single byte to the resulting binaries (!)

Closes bug #117524

Index: unicodedata_db.h
==================================================================RCS file: /cvsroot/python/python/dist/src/Modules/unicodedata_db.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** unicodedata_db.h 2000/09/25 08:07:05 1.2
--- unicodedata_db.h 2000/11/03 20:24:15 1.3
***************
*** 1,3 ****
! /* this file was generated by ..\Tools\unicode\makeunicodedata.py 1.1 */

/* a list of unique database records */
--- 1,3 ----
! /* this file was generated by tools\unicode\makeunicodedata.py 1.1 */

/* a list of unique database records */
***************
*** 3635,3639 ****
NULL
};
! /* index tables used to find the right database record */
#define SHIFT 5
static unsigned char index1[] = {
--- 3635,3639 ----
NULL
};
! /* index tables for the database records */
#define SHIFT 5
static unsigned char index1[] = {
***************
*** 3663,3744 ****
189, 190, 90, 103, 191, 90, 103, 192, 193, 194, 103, 103, 195, 128, 35,
35, 196, 197, 198, 199, 197, 200, 201, 202, 166, 166, 166, 203, 166, 166,
! 204, 202, 205, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 206, 35, 35, 205, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 207, 35, 35, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 208, 209, 210, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 205, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 211, 35, 35, 212, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 213, 212, 35, 35, 213, 212, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 213, 214, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
--- 3663,3763 ----
189, 190, 90, 103, 191, 90, 103, 192, 193, 194, 103, 103, 195, 128, 35,
35, 196, 197, 198, 199, 197, 200, 201, 202, 166, 166, 166, 203, 166, 166,
! 204, 202, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 205, 35, 35, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 206, 35, 35, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 207, 208, 209, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 210, 35, 35, 211, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 212, 211, 35, 35, 212, 211, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 212, 213, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
***************
*** 3751,3758 ****
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 215, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 216, 35, 35, 35, 35, 35, 35, 217, 218, 219, 47, 47, 220, 221, 47, 47, 47,
! 47, 47, 47, 47, 47, 47, 47, 222, 223, 47, 224, 47, 225, 226, 35, 227,
! 228, 229, 47, 47, 47, 230, 231, 232, 233, 234, 235, 236, 237, 238,
};

--- 3770,3777 ----
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 214, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 215, 35, 35, 35, 35, 35, 35, 216, 217, 218, 47, 47, 219, 220, 47,
! 47, 47, 47, 47, 47, 47, 47, 47, 47, 221, 222, 47, 223, 47, 224, 225, 35,
! 226, 227, 228, 47, 47, 47, 229, 230, 231, 232, 233, 234, 235, 236, 237,
};

***************
*** 4099,4106 ****
42, 0, 0, 0, 0, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42,
42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42,
! 42, 42, 42, 0, 0, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 0,
0, 0, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
--- 4118,4124 ----
42, 0, 0, 0, 0, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42,
42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42,
! 42, 42, 42, 0, 0, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
! 30, 30, 30, 30, 30, 30, 30, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 30, 30, 30,
! 30, 30, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 0,
0, 0, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
***************
*** 4108,4127 ****
0, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 0, 23, 23, 23, 0, 23,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 115, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 115, 116, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 116, 30, 30, 30, 30,
! 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 21, 21, 21, 21, 21, 21, 21, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 21, 21, 21, 21, 21, 0, 0, 0, 0, 0, 64, 117, 64, 64, 64, 64,
! 64, 64, 64, 64, 64, 64, 11, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64,
! 64, 64, 0, 64, 64, 64, 64, 64, 0, 64, 0, 64, 64, 0, 64, 64, 0, 64, 64,
! 64, 64, 64, 64, 64, 64, 64, 64, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66,
66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66,
! 66, 66, 66, 66, 66, 66, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 66, 66, 66, 66, 66,
66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66,
66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66,
--- 4126,4145 ----
0, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 0, 23, 23, 23, 0, 23,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 30, 30, 30, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 115, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 115, 116, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 116, 30, 30, 30,
! 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 21, 21, 21, 21, 21, 21, 21, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 21, 21, 21, 21, 21, 0, 0, 0, 0, 0, 64, 117, 64, 64, 64,
! 64, 64, 64, 64, 64, 64, 64, 11, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64,
! 64, 64, 64, 0, 64, 64, 64, 64, 64, 0, 64, 0, 64, 64, 0, 64, 64, 0, 64,
! 64, 64, 64, 64, 64, 64, 64, 64, 64, 66, 66, 66, 66, 66, 66, 66, 66, 66,
66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66,
! 66, 66, 66, 66, 66, 66, 66, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 66, 66, 66, 66, 66,
66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66,
66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66,
***************
*** 4155,4159 ****
};

! /* same, for the decomposition data */
#define DECOMP_SHIFT 5
static unsigned char decomp_index1[] = {
--- 4173,4177 ----
};

! /* index tables for the decomposition data */
#define DECOMP_SHIFT 5
static unsigned char decomp_index1[] = {



From python-dev@python.org Fri Nov 3 20:24:17 2000
From: python-dev@python.org (Fredrik Lundh)
Date: Fri, 3 Nov 2000 12:24:17 -0800
Subject: [Python-checkins] CVS: python/dist/src/Tools/unicode makeunicodedata.py,1.7,1.8
Message-ID: <200011032024.MAA26229@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Tools/unicode
In directory slayer.i.sourceforge.net:/tmp/cvs-serv25791/tools/unicode

Modified Files:
makeunicodedata.py
Log Message:


Added 38,642 missing characters to the Unicode database (first-last
ranges) -- but thanks to the 2.0 compression scheme, this doesn't add
a single byte to the resulting binaries (!)

Closes bug #117524

Index: makeunicodedata.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Tools/unicode/makeunicodedata.py,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -r1.7 -r1.8
*** makeunicodedata.py 2000/10/26 03:56:46 1.7
--- makeunicodedata.py 2000/11/03 20:24:15 1.8
***************
*** 10,13 ****
--- 10,14 ----
# 2000-09-25 fl added character type table
# 2000-09-26 fl added LINEBREAK, DECIMAL, and DIGIT flags/fields
+ # 2000-11-03 fl expand first/last ranges
#
# written by Fredrik Lundh (fredrik@pythonware.com), September 2000
***************
*** 40,47 ****
UPPER_MASK = 0x80

! def maketables():

unicode = UnicodeData(UNICODE_DATA)

# extract unicode properties
dummy = (0, 0, 0, 0)
--- 41,51 ----
UPPER_MASK = 0x80

! def maketables(trace=0):

unicode = UnicodeData(UNICODE_DATA)

+ print "--- Processing", UNICODE_DATA, "..."
+ print len(filter(None, unicode.table)), "characters"
+
# extract unicode properties
dummy = (0, 0, 0, 0)
***************
*** 92,95 ****
--- 96,104 ----
FILE = "Modules/unicodedata_db.h"

+ print "--- Writing", FILE, "..."
+
+ print len(table), "unique properties"
+ print len(decomp_data), "unique decomposition entries"
+
fp = open(FILE, "w")
print >>fp, "/* this file was generated by %s %s */" % (SCRIPT, VERSION)
***************
*** 126,130 ****

# split record index table
! index1, index2, shift = splitbins(index)

print >>fp, "/* index tables for the database records */"
--- 135,139 ----

# split record index table
! index1, index2, shift = splitbins(index, trace)

print >>fp, "/* index tables for the database records */"
***************
*** 134,138 ****

# split decomposition index table
! index1, index2, shift = splitbins(decomp_index)

print >>fp, "/* index tables for the decomposition data */"
--- 143,147 ----

# split decomposition index table
! index1, index2, shift = splitbins(decomp_index, trace)

print >>fp, "/* index tables for the decomposition data */"
***************
*** 201,210 ****
index[char] = i

- print len(table), "ctype entries"
-
FILE = "Objects/unicodetype_db.h"

fp = open(FILE, "w")

print >>fp, "/* this file was generated by %s %s */" % (SCRIPT, VERSION)
print >>fp
--- 210,221 ----
index[char] = i

FILE = "Objects/unicodetype_db.h"

fp = open(FILE, "w")

+ print "--- Writing", FILE, "..."
+
+ print len(table), "unique character type entries"
+
print >>fp, "/* this file was generated by %s %s */" % (SCRIPT, VERSION)
print >>fp
***************
*** 217,221 ****

# split decomposition index table
! index1, index2, shift = splitbins(index)

print >>fp, "/* type indexes */"
--- 228,232 ----

# split decomposition index table
! index1, index2, shift = splitbins(index, trace)

print >>fp, "/* type indexes */"
***************
*** 234,238 ****
class UnicodeData:

! def __init__(self, filename):
file = open(filename)
table = [None] * 65536
--- 245,249 ----
class UnicodeData:

! def __init__(self, filename, expand=1):
file = open(filename)
table = [None] * 65536
***************
*** 245,248 ****
--- 256,275 ----
table[char] = s

+ # expand first-last ranges (ignore surrogates and private use)
+ if expand:
+ field = None
+ for i in range(0, 0xD800):
+ s = table[i]
+ if s:
+ if s[1][-6:] == "First>":
+ s[1] = ""
+ field = s[:]
+ elif s[1][-5:] == "Last>":
+ s[1] = ""
+ field = None
+ elif field:
+ field[0] = hex(i)
+ table[i] = field
+
# public attributes
self.filename = filename
***************
*** 307,312 ****
where mask is a bitmask isolating the last "shift" bits.

! If optional arg trace is true (default false), progress info is
! printed to sys.stderr.
"""

--- 334,340 ----
where mask is a bitmask isolating the last "shift" bits.

! If optional arg trace is non-zero (default zero), progress info
! is printed to sys.stderr. The higher the value, the more info
! you'll get.
"""

***************
*** 342,346 ****
# determine memory size
b = len(t1)*getsize(t1) + len(t2)*getsize(t2)
! if trace:
dump(t1, t2, shift, b)
if b < bytes:
--- 370,374 ----
# determine memory size
b = len(t1)*getsize(t1) + len(t2)*getsize(t2)
! if trace > 1:
dump(t1, t2, shift, b)
if b < bytes:
***************
*** 359,361 ****

if __name__ == "__main__":
! maketables()
--- 387,389 ----

if __name__ == "__main__":
! maketables(1)



From python-dev@python.org Fri Nov 3 20:50:48 2000
From: python-dev@python.org (M.-A. Lemburg)
Date: Fri, 03 Nov 2000 21:50:48 +0100
Subject: [Python-checkins] CVS: python/dist/src/Lib/test/output
test_unicodedata,1.3,1.4
References: <200011032024.MAA26242@slayer.i.sourceforge.net>
Message-ID: <3A032528.D743FC0A@lemburg.com>

Fredrik Lundh wrote:
Update of /cvsroot/python/python/dist/src/Lib/test/output
In directory slayer.i.sourceforge.net:/tmp/cvs-serv25791/lib/test/output

Modified Files:
test_unicodedata
Log Message:

Added 38,642 missing characters to the Unicode database (first-last
ranges) -- but thanks to the 2.0 compression scheme, this doesn't add
a single byte to the resulting binaries (!)

Closes bug #117524
Cool :-)

--
Marc-Andre Lemburg
______________________________________________________________________
Business: http://www.lemburg.com/
Python Pages: http://www.lemburg.com/python/


From python-dev@python.org Sun Nov 5 16:48:58 2000
From: python-dev@python.org (Moshe Zadka)
Date: Sun, 5 Nov 2000 08:48:58 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0216.txt,1.2,1.3
Message-ID: <200011051648.IAA13172@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv13154

Modified Files:
pep-0216.txt
Log Message:
Added requirements and problems.


Index: pep-0216.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0216.txt,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** pep-0216.txt 2000/08/23 05:49:27 1.2
--- pep-0216.txt 2000/11/05 16:48:55 1.3
***************
*** 7,10 ****
--- 7,94 ----
Created: 31-Jul-2000

+ Abstract
+
+ Named Python objects, such as modules, classes and functions, have a
+ string attribute called __doc__. If the first expression inside
+ the definition is a literal string, that string is assigned
+ to the __doc__ attribute.
+
+ The __doc__ attribute is called a documentation string, or docstring.
+ It is often used to summarize the interface of the module, class or
+ function. However, since there is no common format for documentation
+ string, tools for extracting docstrings and transforming those into
+ documentation in a standard format (e.g., DocBook) have not sprang
+ up in abundance, and those that do exist are for the most part
+ unmaintained and unused.
+
+ Perl Documentation
+
+ In Perl, most modules are documented in a format called POD -- Plain
+ Old Documentation. This is an easy-to-type, very low level format
+ which integrates well with the Perl parser. Many tools exist to turn
+ POD documentation into other formats: info, HTML and man pages, among
+ others. However, in Perl, the information is not available at run-time.
+
+ Java Documentation
+
+ In Java, special comments before classes and functions function to
+ document the code. A program to extract these, and turn them into
+ HTML documentation is called javadoc, and is part of the standard
+ Java distribution. However, the only output format that is supported
+ is HTML, and JavaDoc has a very intimate relationship with HTML.
+
+ Python Docstring Goals
+
+ Python documentation string are easy to spot during parsing, and are
+ also available to the runtime interpreter. This double purpose is
+ a bit problematic, sometimes: for example, some are reluctant to have
+ too long docstrings, because they do not want to take much space in
+ the runtime. In addition, because of the current lack of tools, people
+ read objects' docstrings by "print"ing them, so a tendancy to make them
+ brief and free of markups has sprung up. This tendancy hinders writing
+ better documentation-extraction tools, since it causes docstrings to
+ contain little information, which is hard to parse.
+
+ High Level Solutions
+
+ To counter the objection that the strings take up place in the running
+ program, it is suggested that documentation extraction tools will
+ concatenate a maximum prefix of string literals which appear in the
+ beginning of a definition. The first of these will also be available
+ in the interactive interpreter, so it should contain a few summary
+ lines.
+
+ Docstring Format Goals
+
+ These are the goals for the docstring format, as discussed ad neasum
+ in the doc-sig.
+
+ 1. It must be easy to type with any standard text editor.
+ 2. It must be readable to the casual observer.
+ 3. It must not contain information which can be deduced from parsing
+ the module.
+ 4. It must contain sufficient information so it can be converted
+ to any reasonable markup format.
+ 5. It must be possible to write a module's entire documentation in
+ docstrings, without feeling hampered by the markup language.
+
+ Docstring Contents
+
+ For requirement 5. above, it is needed to specify what must be
+ in docstrings.
+
+ At least the following must be available:
+
+ a. A tag that means "this is a Python ``something'', guess what"
+ b. Tags that mean "this is a Python class/module/class var/instance var..."
+ c. An easy way to include Python source code/Python interactive sessions
+ d. Emphasis/bold
+ e. List/tables
+
+ Rejected Suggestions
+
+ XML -- it's very hard to type, and too cluttered to read it
+ comfortably.
+





From python-dev@python.org Sun Nov 5 16:55:27 2000
From: python-dev@python.org (Moshe Zadka)
Date: Sun, 5 Nov 2000 08:55:27 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0228.txt,NONE,1.1 pep-0000.txt,1.44,1.45
Message-ID: <200011051655.IAA13536@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv13461

Modified Files:
pep-0000.txt
Added Files:
pep-0228.txt
Log Message:
Added first revision of numerical model pep.


***** Error reading new file: (2, 'No such file or directory')
***** file: pep-0228.txt cwd: /tmp/cvs-serv13461
Index: pep-0000.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0000.txt,v
retrieving revision 1.44
retrieving revision 1.45
diff -C2 -r1.44 -r1.45
*** pep-0000.txt 2000/11/03 02:56:05 1.44
--- pep-0000.txt 2000/11/05 16:55:24 1.45
***************
*** 120,123 ****
--- 120,124 ----
I 226 pep-0226.txt Python 2.1 Release Schedule Hylton
S 227 pep-0227.txt Statically Nested Scopes Hylton
+ S 228 pep-0228.txt Reworking Python's Numeric Model Zadka





From python-dev@python.org Sun Nov 5 20:36:11 2000
From: python-dev@python.org (Moshe Zadka)
Date: Sun, 5 Nov 2000 12:36:11 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0228.txt,1.1,1.2
Message-ID: <200011052036.MAA09976@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv9952

Modified Files:
pep-0228.txt
Log Message:
Added some issues because of Py-Dev feedback


Index: pep-0228.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0228.txt,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** pep-0228.txt 2000/11/05 16:55:24 1.1
--- pep-0228.txt 2000/11/05 20:36:06 1.2
***************
*** 1,3 ****
! PEP: Unassigned
Title: Reworking Python's Numeric Model
Version: $Revision$
--- 1,3 ----
! PEP: 228
Title: Reworking Python's Numeric Model
Version: $Revision$
***************
*** 76,104 ****
mathematicl result.

- 6. Rationale -- The rationale fleshes out the specification by
- describing what motivated the design and why particular design
- decisions were made. It should describe alternate designs that
- were considered and related work, e.g. how the feature is
- supported in other languages.
-
- The rationale should provide evidence of consensus within the
- community and discuss important objections or concerns raised
- during discussion.
-
- 7. Reference Implementation -- The reference implementation must
- be completed before any PEP is given status 'final,' but it
- need not be completed before the PEP is accepted. It is better
- to finish the specification and rationale first and reach
- consensus on it before writing code.
-
- The final implementation must include test code and
- documentation appropriate for either the Python language
- reference or the standard library reference.
-
Numerical Python Issues

! People using Numerical Python do that for high-performance
! vector operations. Therefore, NumPy should keep it's hardware
! based numeric model.

Copyright
--- 76,90 ----
mathematicl result.

Numerical Python Issues
+
+ People using Numerical Python do that for high-performance
+ vector operations. Therefore, NumPy should keep it's hardware
+ based numeric model.
+
+ Unresolved Issues
+
+ Which number literals will be exact, and which inexact?

! How do we deal with IEEE 754?

Copyright



From python-dev@python.org Mon Nov 6 00:44:37 2000
From: python-dev@python.org (Guido van Rossum)
Date: Sun, 5 Nov 2000 16:44:37 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0000.txt,1.45,1.46
Message-ID: <200011060044.QAA27975@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv27965

Modified Files:
pep-0000.txt
Log Message:
Add 228 (numerical model) to the pie-in-the-sky category -- this can't
be ready for Python 2.1.


Index: pep-0000.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0000.txt,v
retrieving revision 1.45
retrieving revision 1.46
diff -C2 -r1.45 -r1.46
*** pep-0000.txt 2000/11/05 16:55:24 1.45
--- pep-0000.txt 2000/11/06 00:44:34 1.46
***************
*** 47,50 ****
--- 47,51 ----
SD 224 pep-0224.txt Attribute Docstrings Lemburg
SD 225 pep-0225.txt Elementwise/Objectwise Operators Zhu, Lielens
+ S 228 pep-0228.txt Reworking Python's Numeric Model Zadka

Incomplete PEPs (only an abstract)



From python-dev@python.org Mon Nov 6 02:49:29 2000
From: python-dev@python.org (Mark Hammond)
Date: Sun, 5 Nov 2000 18:49:29 -0800
Subject: [Python-checkins] CVS: python/dist/src/Tools/freeze modulefinder.py,1.14,1.15
Message-ID: <200011060249.SAA15782@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Tools/freeze
In directory slayer.i.sourceforge.net:/tmp/cvs-serv15773

Modified Files:
modulefinder.py
Log Message:
Application of [ Patch #102226 ] freeze/modulefinder.py should use _winreg, not win32api

Index: modulefinder.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Tools/freeze/modulefinder.py,v
retrieving revision 1.14
retrieving revision 1.15
diff -C2 -r1.14 -r1.15
*** modulefinder.py 2000/09/15 16:37:42 1.14
--- modulefinder.py 2000/11/06 02:49:27 1.15
***************
*** 9,23 ****
import sys

- if sys.platform=="win32":
- # On Windows, we can locate modules in the registry with
- # the help of the win32api package.
- try:
- import win32api
- except ImportError:
- print "The win32api module is not available - modules listed"
- print "in the registry will not be found."
- win32api = None
-
-
IMPORT_NAME = dis.opname.index('IMPORT_NAME')
IMPORT_FROM = dis.opname.index('IMPORT_FROM')
--- 9,12 ----
***************
*** 340,352 ****

# Emulate the Registered Module support on Windows.
! if sys.platform=="win32" and win32api is not None:
! HKEY_LOCAL_MACHINE = 0x80000002
try:
! pathname = win32api.RegQueryValue(HKEY_LOCAL_MACHINE, "Software\\Python\\PythonCore\\%s\\Modules\\%s" % (sys.winver, name))
fp = open(pathname, "rb")
# XXX - To do - remove the hard code of C_EXTENSION.
stuff = "", "rb", imp.C_EXTENSION
return fp, pathname, stuff
! except win32api.error:
pass

--- 329,343 ----

# Emulate the Registered Module support on Windows.
! if sys.platform=="win32":
! import _winreg
! from _winreg import HKEY_LOCAL_MACHINE
try:
! pathname = _winreg.QueryValueEx(HKEY_LOCAL_MACHINE, \
! "Software\\Python\\PythonCore\\%s\\Modules\\%s" % (sys.winver, name))
fp = open(pathname, "rb")
# XXX - To do - remove the hard code of C_EXTENSION.
stuff = "", "rb", imp.C_EXTENSION
return fp, pathname, stuff
! except _winreg.error:
pass




From python-dev@python.org Mon Nov 6 03:33:54 2000
From: python-dev@python.org (Jeremy Hylton)
Date: Sun, 5 Nov 2000 19:33:54 -0800
Subject: [Python-checkins] CVS: python/dist/src/Tools/compiler/compiler transformer.py,1.17,1.18
Message-ID: <200011060333.TAA18666@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Tools/compiler/compiler
In directory slayer.i.sourceforge.net:/tmp/cvs-serv18510

Modified Files:
transformer.py
Log Message:
If a function contains a doc string, remove the doc string node from
the function's body.

If assert is used without an error message, make the AST node None
rather than Name('None').



Index: transformer.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Tools/compiler/compiler/transformer.py,v
retrieving revision 1.17
retrieving revision 1.18
diff -C2 -r1.17 -r1.18
*** transformer.py 2000/10/25 18:10:32 1.17
--- transformer.py 2000/11/06 03:33:52 1.18
***************
*** 174,177 ****
--- 174,181 ----
code = self.com_node(nodelist[4])

+ if doc is not None:
+ assert isinstance(code, Stmt)
+ assert isinstance(code.nodes[0], Discard)
+ del code.nodes[0]
n = Function(name, names, defaults, flags, doc, code)
n.lineno = lineno
***************
*** 401,405 ****
expr2 = self.com_node(nodelist[3])
else:
! expr2 = Name('None')
n = Assert(expr1, expr2)
n.lineno = nodelist[0][2]
--- 405,409 ----
expr2 = self.com_node(nodelist[3])
else:
! expr2 = None
n = Assert(expr1, expr2)
n.lineno = nodelist[0][2]



From python-dev@python.org Mon Nov 6 03:43:14 2000
From: python-dev@python.org (Jeremy Hylton)
Date: Sun, 5 Nov 2000 19:43:14 -0800
Subject: [Python-checkins] CVS: python/dist/src/Tools/compiler/compiler pycodegen.py,1.26,1.27 pyassem.py,1.13,1.14 misc.py,1.6,1.7
Message-ID: <200011060343.TAA19466@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Tools/compiler/compiler
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19430

Modified Files:
pycodegen.py pyassem.py misc.py
Log Message:
Change the graph structure to contain the code generator object for
embedded code objects (e.g. functions) rather than the generated code
object. This change means that the compiler generates code for
everything at the end, rather then generating code for each function
as it finds it. Implementation note: _convert_LOAD_CONST in
pyassem.py must be change to call getCode().

Other changes follow. Several changes creates extra edges between
basic blocks to reflect control flow for loops and exceptions. These
missing edges had gone unnoticed because they do not affect the
current compilation process.

pyassem.py:
Add _enable_debug() and _disable_debug() methods that print
instructions and blocks to stdout as they are generated.

Add edges between blocks for instructions like SETUP_LOOP,
FOR_LOOP, etc.

Add pruneNext to get rid of bogus edges remaining after
unconditional transfer ops (e.g. JUMP_FORWARD)

Change repr of Block to omit block length.

pycodegen.py:
Make sure a new block is started after FOR_LOOP, etc.

Change assert implementation to use RAISE_VARARGS 1 when there is
no user-specified failure output.

misc.py:
Implement __contains__ and copy for Set.





Index: pycodegen.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Tools/compiler/compiler/pycodegen.py,v
retrieving revision 1.26
retrieving revision 1.27
diff -C2 -r1.26 -r1.27
*** pycodegen.py 2000/10/13 21:58:13 1.26
--- pycodegen.py 2000/11/06 03:43:11 1.27
***************
*** 161,165 ****
for default in node.defaults:
self.visit(default)
! self.emit('LOAD_CONST', gen.getCode())
self.emit('MAKE_FUNCTION', len(node.defaults))

--- 161,165 ----
for default in node.defaults:
self.visit(default)
! self.emit('LOAD_CONST', gen)
self.emit('MAKE_FUNCTION', len(node.defaults))

***************
*** 196,200 ****
self.visit(suite)
self.emit('JUMP_FORWARD', end)
! self.nextBlock(nextTest)
self.emit('POP_TOP')
if node.else_:
--- 196,200 ----
self.visit(suite)
self.emit('JUMP_FORWARD', end)
! self.startBlock(nextTest)
self.emit('POP_TOP')
if node.else_:
***************
*** 244,251 ****
self.set_lineno(node)
self.emit('FOR_LOOP', anchor)
self.visit(node.assign)
self.visit(node.body)
self.emit('JUMP_ABSOLUTE', start)
! self.nextBlock(anchor)
self.emit('POP_BLOCK')
if node.else_:
--- 244,252 ----
self.set_lineno(node)
self.emit('FOR_LOOP', anchor)
+ self.nextBlock()
self.visit(node.assign)
self.visit(node.body)
self.emit('JUMP_ABSOLUTE', start)
! self.startBlock(anchor)
self.emit('POP_BLOCK')
if node.else_:
***************
*** 305,309 ****
end = self.newBlock()
self.emit('JUMP_FORWARD', end)
! self.nextBlock(cleanup)
self.emit('ROT_TWO')
self.emit('POP_TOP')
--- 306,310 ----
end = self.newBlock()
self.emit('JUMP_FORWARD', end)
! self.startBlock(cleanup)
self.emit('ROT_TWO')
self.emit('POP_TOP')
***************
*** 345,353 ****
skip_one = self.newBlock()
self.emit('JUMP_FORWARD', skip_one)
! self.nextBlock(cont)
self.emit('POP_TOP')
self.nextBlock(skip_one)
self.emit('JUMP_ABSOLUTE', start)
! self.nextBlock(anchor)
self.delName(append)

--- 346,354 ----
skip_one = self.newBlock()
self.emit('JUMP_FORWARD', skip_one)
! self.startBlock(cont)
self.emit('POP_TOP')
self.nextBlock(skip_one)
self.emit('JUMP_ABSOLUTE', start)
! self.startBlock(anchor)
self.delName(append)

***************
*** 364,367 ****
--- 365,369 ----
self.nextBlock(start)
self.emit('FOR_LOOP', anchor)
+ self.nextBlock()
self.visit(node.assign)
return start, anchor
***************
*** 391,397 ****
self.emit('JUMP_IF_TRUE', end)
self.nextBlock()
self.emit('LOAD_GLOBAL', 'AssertionError')
! self.visit(node.fail)
! self.emit('RAISE_VARARGS', 2)
self.nextBlock(end)
self.emit('POP_TOP')
--- 393,403 ----
self.emit('JUMP_IF_TRUE', end)
self.nextBlock()
+ self.emit('POP_TOP')
self.emit('LOAD_GLOBAL', 'AssertionError')
! if node.fail:
! self.visit(node.fail)
! self.emit('RAISE_VARARGS', 2)
! else:
! self.emit('RAISE_VARARGS', 1)
self.nextBlock(end)
self.emit('POP_TOP')
***************
*** 420,427 ****
self.set_lineno(node)
self.emit('SETUP_EXCEPT', handlers)
self.visit(node.body)
self.emit('POP_BLOCK')
self.emit('JUMP_FORWARD', lElse)
! self.nextBlock(handlers)

last = len(node.handlers) - 1
--- 426,434 ----
self.set_lineno(node)
self.emit('SETUP_EXCEPT', handlers)
+ self.nextBlock()
self.visit(node.body)
self.emit('POP_BLOCK')
self.emit('JUMP_FORWARD', lElse)
! self.startBlock(handlers)

last = len(node.handlers) - 1
***************
*** 447,450 ****
--- 454,459 ----
if expr:
self.nextBlock(next)
+ else:
+ self.nextBlock()
self.emit('POP_TOP')
self.emit('END_FINALLY')
***************
*** 458,461 ****
--- 467,471 ----
self.set_lineno(node)
self.emit('SETUP_FINALLY', final)
+ self.nextBlock()
self.visit(node.body)
self.emit('POP_BLOCK')

Index: pyassem.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Tools/compiler/compiler/pyassem.py,v
retrieving revision 1.13
retrieving revision 1.14
diff -C2 -r1.13 -r1.14
*** pyassem.py 2000/10/13 21:58:13 1.13
--- pyassem.py 2000/11/06 03:43:11 1.14
***************
*** 4,11 ****
--- 4,19 ----
import new
import string
+ import sys
import types

from compiler import misc

+ def xxx_sort(l):
+ l = l[:]
+ def sorter(a, b):
+ return cmp(a.bid, b.bid)
+ l.sort(sorter)
+ return l
+
class FlowGraph:
def __init__(self):
***************
*** 17,27 ****

def startBlock(self, block):
self.current = block

! def nextBlock(self, block=None):
! if block is None:
! block = self.newBlock()
# XXX think we need to specify when there is implicit transfer
! # from one block to the next
#
# I think this strategy works: each block has a child
--- 25,40 ----

def startBlock(self, block):
+ if self._debug:
+ if self.current:
+ print "end", repr(self.current)
+ print " ", self.current.get_children()
+ print repr(block)
self.current = block

! def nextBlock(self, block=None, force=0):
# XXX think we need to specify when there is implicit transfer
! # from one block to the next. might be better to represent this
! # with explicit JUMP_ABSOLUTE instructions that are optimized
! # out when they are unnecessary.
#
# I think this strategy works: each block has a child
***************
*** 31,34 ****
--- 44,57 ----
# immediately after its parent.
# Worry: maintaining this invariant could be tricky
+ if block is None:
+ block = self.newBlock()
+
+ # Note: If the current block ends with an unconditional
+ # control transfer, then it is incorrect to add an implicit
+ # transfer to the block graph. The current code requires
+ # these edges to get the blocks emitted in the right order,
+ # however. :-( If a client needs to remove these edges, call
+ # pruneEdges().
+
self.current.addNext(block)
self.startBlock(block)
***************
*** 42,52 ****
self.startBlock(self.exit)

def emit(self, *inst):
! # XXX should jump instructions implicitly call nextBlock?
if inst[0] == 'RETURN_VALUE':
self.current.addOutEdge(self.exit)
self.current.emit(inst)

! def getBlocks(self):
"""Return the blocks in reverse postorder

--- 65,86 ----
self.startBlock(self.exit)

+ _debug = 0
+
+ def _enable_debug(self):
+ self._debug = 1
+
+ def _disable_debug(self):
+ self._debug = 0
+
def emit(self, *inst):
! if self._debug:
! print "\t", inst
if inst[0] == 'RETURN_VALUE':
self.current.addOutEdge(self.exit)
+ if len(inst) == 2 and isinstance(inst[1], Block):
+ self.current.addOutEdge(inst[1])
self.current.emit(inst)

! def getBlocksInOrder(self):
"""Return the blocks in reverse postorder

***************
*** 65,75 ****
if not self.exit in order:
order.append(self.exit)
return order

def dfs_postorder(b, seen):
"""Depth-first search of tree rooted at b, return in postorder"""
order = []
seen[b] = b
! for c in b.children():
if seen.has_key(c):
continue
--- 99,153 ----
if not self.exit in order:
order.append(self.exit)
+
+ ## for b in order:
+ ## print repr(b)
+ ## print "\t", b.get_children()
+ ## print b
+ ## print
+
return order

+ def getBlocks(self):
+ return self.blocks.elements()
+
+ def getRoot(self):
+ """Return nodes appropriate for use with dominator"""
+ return self.entry
+
+ def getContainedGraphs(self):
+ l = []
+ for b in self.getBlocks():
+ l.extend(b.getContainedGraphs())
+ return l
+
+ _uncond_transfer = ('RETURN_VALUE', 'RAISE_VARARGS',
+ 'JUMP_ABSOLUTE', 'JUMP_FORWARD')
+
+ def pruneNext(self):
+ """Remove bogus edge for unconditional transfers
+
+ Each block has a next edge that accounts for implicit control
+ transfers, e.g. from a JUMP_IF_FALSE to the block that will be
+ executed if the test is true.
+
+ These edges must remain for the current assembler code to
+ work. If they are removed, the dfs_postorder gets things in
+ weird orders. However, they shouldn't be there for other
+ purposes, e.g. conversion to SSA form. This method will
+ remove the next edge when it follows an unconditional control
+ transfer.
+ """
+ try:
+ op, arg = self.insts[-1]
+ except (IndexError, TypeError):
+ return
+ if op in self._uncond_transfer:
+ self.next = []
+
def dfs_postorder(b, seen):
"""Depth-first search of tree rooted at b, return in postorder"""
order = []
seen[b] = b
! for c in b.get_children():
if seen.has_key(c):
continue
***************
*** 92,99 ****
def __repr__(self):
if self.label:
! return "<block %s id=%d len=%d>" % (self.label, self.bid,
! len(self.insts))
else:
! return "<block id=%d len=%d>" % (self.bid, len(self.insts))

def __str__(self):
--- 170,176 ----
def __repr__(self):
if self.label:
! return "<block %s id=%d>" % (self.label, self.bid)
else:
! return "<block id=%d>" % (self.bid)

def __str__(self):
***************
*** 121,127 ****
assert len(self.next) == 1, map(str, self.next)

! def children(self):
return self.outEdges.elements() + self.next

# flags for code objects
CO_OPTIMIZED = 0x0001
--- 198,221 ----
assert len(self.next) == 1, map(str, self.next)

! def get_children(self):
! if self.next and self.next[0] in self.outEdges:
! self.outEdges.remove(self.next[0])
return self.outEdges.elements() + self.next

+ def getContainedGraphs(self):
+ """Return all graphs contained within this block.
+
+ For example, a MAKE_FUNCTION block will contain a reference to
+ the graph for the function body.
+ """
+ contained = []
+ for inst in self.insts:
+ if len(inst) == 1:
+ continue
+ op = inst[1]
+ if hasattr(op, 'graph'):
+ contained.append(op.graph)
+ return contained
+
# flags for code objects
CO_OPTIMIZED = 0x0001
***************
*** 205,209 ****
begin = {}
end = {}
! for b in self.getBlocks():
begin[b] = pc
for inst in b.getInstructions():
--- 299,303 ----
begin = {}
end = {}
! for b in self.getBlocksInOrder():
begin[b] = pc
for inst in b.getInstructions():
***************
*** 275,278 ****
--- 369,374 ----
_converters = {}
def _convert_LOAD_CONST(self, arg):
+ if hasattr(arg, 'getCode'):
+ arg = arg.getCode()
return self._lookupName(arg, self.consts)


Index: misc.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Tools/compiler/compiler/misc.py,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -r1.6 -r1.7
*** misc.py 2000/03/16 20:02:38 1.6
--- misc.py 2000/11/06 03:43:11 1.7
***************
*** 15,18 ****
--- 15,20 ----
def __len__(self):
return len(self.elts)
+ def __contains__(self, elt):
+ return self.elts.has_key(elt)
def add(self, elt):
self.elts[elt] = elt
***************
*** 23,26 ****
--- 25,32 ----
def remove(self, elt):
del self.elts[elt]
+ def copy(self):
+ c = Set()
+ c.elts.update(self.elts)
+ return c

class Stack:



From python-dev@python.org Mon Nov 6 03:47:41 2000
From: python-dev@python.org (Jeremy Hylton)
Date: Sun, 5 Nov 2000 19:47:41 -0800
Subject: [Python-checkins] CVS: python/dist/src/Tools/compiler/compiler pyassem.py,1.14,1.15
Message-ID: <200011060347.TAA20007@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Tools/compiler/compiler
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19954/compiler

Modified Files:
pyassem.py
Log Message:
move pruneNext method to correct object (doh!)


Index: pyassem.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Tools/compiler/compiler/pyassem.py,v
retrieving revision 1.14
retrieving revision 1.15
diff -C2 -r1.14 -r1.15
*** pyassem.py 2000/11/06 03:43:11 1.14
--- pyassem.py 2000/11/06 03:47:39 1.15
***************
*** 121,148 ****
return l

- _uncond_transfer = ('RETURN_VALUE', 'RAISE_VARARGS',
- 'JUMP_ABSOLUTE', 'JUMP_FORWARD')
-
- def pruneNext(self):
- """Remove bogus edge for unconditional transfers
-
- Each block has a next edge that accounts for implicit control
- transfers, e.g. from a JUMP_IF_FALSE to the block that will be
- executed if the test is true.
-
- These edges must remain for the current assembler code to
- work. If they are removed, the dfs_postorder gets things in
- weird orders. However, they shouldn't be there for other
- purposes, e.g. conversion to SSA form. This method will
- remove the next edge when it follows an unconditional control
- transfer.
- """
- try:
- op, arg = self.insts[-1]
- except (IndexError, TypeError):
- return
- if op in self._uncond_transfer:
- self.next = []
-
def dfs_postorder(b, seen):
"""Depth-first search of tree rooted at b, return in postorder"""
--- 121,124 ----
***************
*** 197,200 ****
--- 173,200 ----
self.next.append(block)
assert len(self.next) == 1, map(str, self.next)
+
+ _uncond_transfer = ('RETURN_VALUE', 'RAISE_VARARGS',
+ 'JUMP_ABSOLUTE', 'JUMP_FORWARD')
+
+ def pruneNext(self):
+ """Remove bogus edge for unconditional transfers
+
+ Each block has a next edge that accounts for implicit control
+ transfers, e.g. from a JUMP_IF_FALSE to the block that will be
+ executed if the test is true.
+
+ These edges must remain for the current assembler code to
+ work. If they are removed, the dfs_postorder gets things in
+ weird orders. However, they shouldn't be there for other
+ purposes, e.g. conversion to SSA form. This method will
+ remove the next edge when it follows an unconditional control
+ transfer.
+ """
+ try:
+ op, arg = self.insts[-1]
+ except (IndexError, ValueError):
+ return
+ if op in self._uncond_transfer:
+ self.next = []

def get_children(self):



From python-dev@python.org Mon Nov 6 15:30:02 2000
From: python-dev@python.org (Barry Warsaw)
Date: Mon, 6 Nov 2000 07:30:02 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0228.txt,1.2,1.3
Message-ID: <200011061530.HAA23507@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv23491

Modified Files:
pep-0228.txt
Log Message:
Spell-checking, grammar, formatting.


Index: pep-0228.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0228.txt,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** pep-0228.txt 2000/11/05 20:36:06 1.2
--- pep-0228.txt 2000/11/06 15:29:58 1.3
***************
*** 5,8 ****
--- 5,9 ----
Status: Draft
Type: Standards Track
+ Python-Version: ??
Created: 4-Nov-2000
Post-History:
***************
*** 10,45 ****
Abstract

! Today, Python's numerical model is similar to the C numeric model:
! there are several unrelated numerical types, and when operations
! between numerical types are requested, coercions happen. While the C
! rational for the numerical model is that it is very similar to what
! happens on the hardware level, that rational does not apply to Python.
! So, while it is acceptable to C programmers that 2/3 == 0, it is very
! surprising to Python programmers.

Rationale

- In usability studies, one of Python hardest to learn features was
- the fact integer division returns the floor of the division. This
- makes it hard to program correctly, requiring casts to float() in
- various parts through the code. Python numerical model stems from
- C, while an easier numerical model would stem from the mathematical
- understanding of numbers.

Other Numerical Models

! Perl's numerical model is that there is one type of numbers -- floating
! point numbers. While it is consistent and superficially non-suprising,
! it tends to have subtle gotchas. One of these is that printing numbers
! is very tricky, and requires correct rounding. In Perl, there is also
! a mode where all numbers are integers. This mode also has its share of
! problems, which arise from the fact that there is not even an approximate
! way of dividing numbers and getting meaningful answers.
!
! Suggested Interface For Python Numerical Model
!
! While coercion rules will remain for add-on types and classes, the built
! in type system will have exactly one Python type -- a number. There
! are several things which can be considered "number methods":

1. isnatural()
--- 11,51 ----
Abstract

! Today, Python's numerical model is similar to the C numeric model:
! there are several unrelated numerical types, and when operations
! between numerical types are requested, coercions happen. While
! the C rationale for the numerical model is that it is very similar
! to what happens on the hardware level, that rationale does not
! apply to Python. So, while it is acceptable to C programmers that
! 2/3 == 0, it is very surprising to Python programmers.

+
Rationale
+
+ In usability studies, one of Python features hardest to learn was
+ the fact that integer division returns the floor of the division.
+ This makes it hard to program correctly, requiring casts to
+ float() in various parts through the code. Python's numerical
+ model stems from C, while an easier numerical model would stem
+ from the mathematical understanding of numbers.


Other Numerical Models

! Perl's numerical model is that there is one type of numbers --
! floating point numbers. While it is consistent and superficially
! non-surprising, it tends to have subtle gotchas. One of these is
! that printing numbers is very tricky, and requires correct
! rounding. In Perl, there is also a mode where all numbers are
! integers. This mode also has its share of problems, which arise
! from the fact that there is not even an approximate way of
! dividing numbers and getting meaningful answers.
!
!
! Suggested Interface For Python's Numerical Model
!
! While coercion rules will remain for add-on types and classes, the
! built in type system will have exactly one Python type -- a
! number. There are several things which can be considered "number
! methods":

1. isnatural()
***************
*** 51,65 ****
a. isexact()

! Obviously, a number which answers m as true, also answers m+k as true.
! If "isexact()" is not true, then any answer might be wrong. (But not
! horribly wrong: it's close the truth).

Now, there is two thing the models promises for the field operations
(+, -, /, *):

! If both operands satisfy isexact(), the result satisfies isexact()

! All field rules are true, except that for not-isexact() numbers,
! they might be only approximately true.

There is one important operation, inexact() which takes a number
--- 57,72 ----
a. isexact()

! Obviously, a number which answers m as true, also answers m+k as
! true. If "isexact()" is not true, then any answer might be wrong.
! (But not horribly wrong: it's close to the truth.)

Now, there is two thing the models promises for the field operations
(+, -, /, *):

! - If both operands satisfy isexact(), the result satisfies
! isexact().

! - All field rules are true, except that for not-isexact() numbers,
! they might be only approximately true.

There is one important operation, inexact() which takes a number
***************
*** 69,85 ****
when given inexact numbers: e.g, int().

Inexact Operations

- The functions in the "math" module will be allowed to return inexact
- results for exact values. However, they will never return a non-real
- number. The functions in the "cmath" module will return the correct
- mathematicl result.

Numerical Python Issues

! People using Numerical Python do that for high-performance
! vector operations. Therefore, NumPy should keep it's hardware
! based numeric model.

Unresolved Issues

--- 76,95 ----
when given inexact numbers: e.g, int().

+
Inexact Operations
+
+ The functions in the "math" module will be allowed to return
+ inexact results for exact values. However, they will never return
+ a non-real number. The functions in the "cmath" module will
+ return the correct mathematical result.


Numerical Python Issues

! People who use Numerical Python do so for high-performance vector
! operations. Therefore, NumPy should keep its hardware based
! numeric model.

+
Unresolved Issues

***************
*** 88,94 ****
--- 98,106 ----
How do we deal with IEEE 754?

+
Copyright

This document has been placed in the public domain.
+





From python-dev@python.org Mon Nov 6 15:30:49 2000
From: python-dev@python.org (Barry Warsaw)
Date: Mon, 6 Nov 2000 07:30:49 -0800
Subject: [Python-checkins] CVS: python/nondist/peps Makefile,1.2,1.3
Message-ID: <200011061530.HAA23602@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv23585

Modified Files:
Makefile
Log Message:
Added `update' target


Index: Makefile
==================================================================RCS file: /cvsroot/python/python/nondist/peps/Makefile,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** Makefile 2000/11/03 15:42:20 1.2
--- Makefile 2000/11/06 15:30:47 1.3
***************
*** 20,21 ****
--- 20,24 ----
clean:
-rm *.html
+
+ update:
+ cvs update -P -d



From python-dev@python.org Mon Nov 6 16:03:54 2000
From: python-dev@python.org (Jeremy Hylton)
Date: Mon, 6 Nov 2000 08:03:54 -0800
Subject: [Python-checkins] CVS: python/dist/src/Tools/compiler/compiler transformer.py,1.18,1.19
Message-ID: <200011061603.IAA26508@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Tools/compiler/compiler
In directory slayer.i.sourceforge.net:/tmp/cvs-serv26474

Modified Files:
transformer.py
Log Message:
a few small optimizations that seem to give a 5-10% speedup; the
further optimization of com_node makes the most difference.


Index: transformer.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Tools/compiler/compiler/transformer.py,v
retrieving revision 1.18
retrieving revision 1.19
diff -C2 -r1.18 -r1.19
*** transformer.py 2000/11/06 03:33:52 1.18
--- transformer.py 2000/11/06 16:03:52 1.19
***************
*** 83,90 ****

def __init__(self):
! self._dispatch = { }
for value, name in symbol.sym_name.items():
if hasattr(self, name):
self._dispatch[value] = getattr(self, name)

def transform(self, tree):
--- 83,99 ----

def __init__(self):
! self._dispatch = {}
for value, name in symbol.sym_name.items():
if hasattr(self, name):
self._dispatch[value] = getattr(self, name)
+ self._dispatch[token.NEWLINE] = self.com_NEWLINE
+ self._atom_dispatch = {token.LPAR: self.atom_lpar,
+ token.LSQB: self.atom_lsqb,
+ token.LBRACE: self.atom_lbrace,
+ token.BACKQUOTE: self.atom_backquote,
+ token.NUMBER: self.atom_number,
+ token.STRING: self.atom_string,
+ token.NAME: self.atom_name,
+ }

def transform(self, tree):
***************
*** 485,489 ****
# testlist: expr (',' expr)* [',']
# exprlist: expr (',' expr)* [',']
! return self.com_binary('tuple', nodelist)

exprlist = testlist
--- 494,498 ----
# testlist: expr (',' expr)* [',']
# exprlist: expr (',' expr)* [',']
! return self.com_binary(Tuple, nodelist)

exprlist = testlist
***************
*** 493,501 ****
if len(nodelist) == 1 and nodelist[0][0] == symbol.lambdef:
return self.lambdef(nodelist[0])
! return self.com_binary('or', nodelist)

def and_test(self, nodelist):
# not_test ('and' not_test)*
! return self.com_binary('and', nodelist)

def not_test(self, nodelist):
--- 502,510 ----
if len(nodelist) == 1 and nodelist[0][0] == symbol.lambdef:
return self.lambdef(nodelist[0])
! return self.com_binary(Or, nodelist)

def and_test(self, nodelist):
# not_test ('and' not_test)*
! return self.com_binary(And, nodelist)

def not_test(self, nodelist):
***************
*** 545,557 ****
def expr(self, nodelist):
# xor_expr ('|' xor_expr)*
! return self.com_binary('bitor', nodelist)

def xor_expr(self, nodelist):
# xor_expr ('^' xor_expr)*
! return self.com_binary('bitxor', nodelist)

def and_expr(self, nodelist):
# xor_expr ('&' xor_expr)*
! return self.com_binary('bitand', nodelist)

def shift_expr(self, nodelist):
--- 554,566 ----
def expr(self, nodelist):
# xor_expr ('|' xor_expr)*
! return self.com_binary(Bitor, nodelist)

def xor_expr(self, nodelist):
# xor_expr ('^' xor_expr)*
! return self.com_binary(Bitxor, nodelist)

def and_expr(self, nodelist):
# xor_expr ('&' xor_expr)*
! return self.com_binary(Bitand, nodelist)

def shift_expr(self, nodelist):
***************
*** 584,610 ****
for i in range(2, len(nodelist), 2):
right = self.com_node(nodelist[i])
! if nodelist[i-1][0] == token.STAR:
node = Mul([node, right])
! node.lineno = nodelist[1][2]
! elif nodelist[i-1][0] == token.SLASH:
node = Div([node, right])
- node.lineno = nodelist[1][2]
else:
node = Mod([node, right])
! node.lineno = nodelist[1][2]
return node

def factor(self, nodelist):
! t = nodelist[0][0]
node = self.com_node(nodelist[-1])
if t == token.PLUS:
node = UnaryAdd(node)
! node.lineno = nodelist[0][2]
elif t == token.MINUS:
node = UnarySub(node)
! node.lineno = nodelist[0][2]
elif t == token.TILDE:
node = Invert(node)
! node.lineno = nodelist[0][2]
return node

--- 593,619 ----
for i in range(2, len(nodelist), 2):
right = self.com_node(nodelist[i])
! t = nodelist[i-1][0]
! if t == token.STAR:
node = Mul([node, right])
! elif t == token.SLASH:
node = Div([node, right])
else:
node = Mod([node, right])
! node.lineno = nodelist[1][2]
return node

def factor(self, nodelist):
! elt = nodelist[0]
! t = elt[0]
node = self.com_node(nodelist[-1])
if t == token.PLUS:
node = UnaryAdd(node)
! node.lineno = elt[2]
elif t == token.MINUS:
node = UnarySub(node)
! node.lineno = elt[2]
elif t == token.TILDE:
node = Invert(node)
! node.lineno = elt[2]
return node

***************
*** 613,674 ****
node = self.com_node(nodelist[0])
for i in range(1, len(nodelist)):
! if nodelist[i][0] == token.DOUBLESTAR:
n = Power([node, self.com_node(nodelist[i+1])])
! n.lineno = nodelist[i][2]
return n

! node = self.com_apply_trailer(node, nodelist[i])

return node

def atom(self, nodelist):
! t = nodelist[0][0]
! if t == token.LPAR:
! if nodelist[1][0] == token.RPAR:
! n = Tuple(())
! n.lineno = nodelist[0][2]
! return n
! return self.com_node(nodelist[1])
!
! if t == token.LSQB:
! if nodelist[1][0] == token.RSQB:
! n = List(())
! n.lineno = nodelist[0][2]
! return n
! return self.com_list_constructor(nodelist[1])

! if t == token.LBRACE:
! if nodelist[1][0] == token.RBRACE:
! return Dict(())
! return self.com_dictmaker(nodelist[1])
!
! if t == token.BACKQUOTE:
! n = Backquote(self.com_node(nodelist[1]))
n.lineno = nodelist[0][2]
return n

! if t == token.NUMBER:
! ### need to verify this matches compile.c
! k = eval(nodelist[0][1])
! n = Const(k)
n.lineno = nodelist[0][2]
return n

! if t == token.STRING:
! ### need to verify this matches compile.c
! k = ''
! for node in nodelist:
! k = k + eval(node[1])
! n = Const(k)
! n.lineno = nodelist[0][2]
! return n

! if t == token.NAME:
! ### any processing to do?
! n = Name(nodelist[0][1])
! n.lineno = nodelist[0][2]
! return n

! raise error, "unknown node type"

# --------------------------------------------------------------
--- 622,683 ----
node = self.com_node(nodelist[0])
for i in range(1, len(nodelist)):
! elt = nodelist[i]
! if elt[0] == token.DOUBLESTAR:
n = Power([node, self.com_node(nodelist[i+1])])
! n.lineno = elt[2]
return n

! node = self.com_apply_trailer(node, elt)

return node

def atom(self, nodelist):
! return self._atom_dispatch[nodelist[0][0]](nodelist)

! def atom_lpar(self, nodelist):
! if nodelist[1][0] == token.RPAR:
! n = Tuple(())
n.lineno = nodelist[0][2]
return n
+ return self.com_node(nodelist[1])

! def atom_lsqb(self, nodelist):
! if nodelist[1][0] == token.RSQB:
! n = List(())
n.lineno = nodelist[0][2]
return n
+ return self.com_list_constructor(nodelist[1])

! def atom_lbrace(self, nodelist):
! if nodelist[1][0] == token.RBRACE:
! return Dict(())
! return self.com_dictmaker(nodelist[1])

! def atom_backquote(self, nodelist):
! n = Backquote(self.com_node(nodelist[1]))
! n.lineno = nodelist[0][2]
! return n
!
! def atom_number(self, nodelist):
! ### need to verify this matches compile.c
! k = eval(nodelist[0][1])
! n = Const(k)
! n.lineno = nodelist[0][2]
! return n
!
! def atom_string(self, nodelist):
! ### need to verify this matches compile.c
! k = ''
! for node in nodelist:
! k = k + eval(node[1])
! n = Const(k)
! n.lineno = nodelist[0][2]
! return n

! def atom_name(self, nodelist):
! ### any processing to do?
! n = Name(nodelist[0][1])
! n.lineno = nodelist[0][2]
! return n

# --------------------------------------------------------------
***************
*** 682,699 ****
# and compound_stmt.
# We'll just dispatch them.

# A ';' at the end of a line can make a NEWLINE token appear
# here, Render it harmless. (genc discards ('discard',
# ('const', xxxx)) Nodes)
! key = node[0]
!
! meth = self._dispatch.get(key, None)
! if meth:
! return meth(node[1:])
! else:
! if key == token.NEWLINE:
! return Discard(Const(None))
!
! raise error, 'illegal node passed to com_node: %s' % `node`

def com_arglist(self, nodelist):
--- 691,701 ----
# and compound_stmt.
# We'll just dispatch them.
+ return self._dispatch[node[0]](node[1:])

+ def com_NEWLINE(self):
# A ';' at the end of a line can make a NEWLINE token appear
# here, Render it harmless. (genc discards ('discard',
# ('const', xxxx)) Nodes)
! return Discard(Const(None))

def com_arglist(self, nodelist):
***************
*** 908,917 ****
def com_assign_trailer(self, primary, node, assigning):
t = node[1][0]
- if t == token.LPAR:
- raise SyntaxError, "can't assign to function call"
if t == token.DOT:
return self.com_assign_attr(primary, node[2], assigning)
if t == token.LSQB:
return self.com_subscriptlist(primary, node[2], assigning)
raise SyntaxError, "unknown trailer type: %s" % t

--- 910,919 ----
def com_assign_trailer(self, primary, node, assigning):
t = node[1][0]
if t == token.DOT:
return self.com_assign_attr(primary, node[2], assigning)
if t == token.LSQB:
return self.com_subscriptlist(primary, node[2], assigning)
+ if t == token.LPAR:
+ raise SyntaxError, "can't assign to function call"
raise SyntaxError, "unknown trailer type: %s" % t

***************
*** 919,923 ****
return AssAttr(primary, node[1], assigning)

! def com_binary(self, type, nodelist):
"Compile 'NODE (OP NODE)*' into (type, [ node1, ..., nodeN ])."
l = len(nodelist)
--- 921,925 ----
return AssAttr(primary, node[1], assigning)

! def com_binary(self, constructor, nodelist):
"Compile 'NODE (OP NODE)*' into (type, [ node1, ..., nodeN ])."
l = len(nodelist)
***************
*** 927,931 ****
for i in range(0, l, 2):
items.append(self.com_node(nodelist[i]))
! return Node(type, items)

def com_stmt(self, node):
--- 929,933 ----
for i in range(0, l, 2):
items.append(self.com_node(nodelist[i]))
! return constructor(items)

def com_stmt(self, node):
***************
*** 965,969 ****
fors = []
while node:
! if node[1][1] == 'for':
assignNode = self.com_assign(node[2], OP_ASSIGN)
listNode = self.com_node(node[4])
--- 967,972 ----
fors = []
while node:
! t = node[1][1]
! if t == 'for':
assignNode = self.com_assign(node[2], OP_ASSIGN)
listNode = self.com_node(node[4])
***************
*** 975,979 ****
else:
node = self.com_list_iter(node[5])
! elif node[1][1] == 'if':
test = self.com_node(node[2])
newif = ListCompIf(test)
--- 978,982 ----
else:
node = self.com_list_iter(node[5])
! elif t == 'if':
test = self.com_node(node[2])
newif = ListCompIf(test)
***************
*** 1102,1108 ****
# slice_item: expression | proper_slice | ellipsis
ch = node[1]
! if ch[0] == token.DOT and node[2][0] == token.DOT:
return Ellipsis()
! if ch[0] == token.COLON or len(node) > 2:
return self.com_sliceobj(node)
return self.com_node(ch)
--- 1105,1112 ----
# slice_item: expression | proper_slice | ellipsis
ch = node[1]
! t = ch[0]
! if t == token.DOT and node[2][0] == token.DOT:
return Ellipsis()
! if t == token.COLON or len(node) > 2:
return self.com_sliceobj(node)
return self.com_node(ch)



From python-dev@python.org Mon Nov 6 18:22:01 2000
From: python-dev@python.org (Moshe Zadka)
Date: Mon, 6 Nov 2000 10:22:01 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0000.txt,1.46,1.47 pep-0207.txt,1.1,1.2
Message-ID: <200011061822.KAA05805@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv5783

Modified Files:
pep-0000.txt pep-0207.txt
Log Message:
Changed ownership to MAL and me.


Index: pep-0000.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0000.txt,v
retrieving revision 1.46
retrieving revision 1.47
diff -C2 -r1.46 -r1.47
*** pep-0000.txt 2000/11/06 00:44:34 1.46
--- pep-0000.txt 2000/11/06 18:21:58 1.47
***************
*** 32,36 ****

I 42 pep-0042.txt Small Feature Requests Hylton
! S 207 pep-0207.txt Rich Comparisons Ascher
S 208 pep-0208.txt Reworking the Coercion Model Ascher
S 217 pep-0217.txt Display Hook for Interactive Use Zadka
--- 32,36 ----

I 42 pep-0042.txt Small Feature Requests Hylton
! S 207 pep-0207.txt Rich Comparisons Zadka, Lemburg
S 208 pep-0208.txt Reworking the Coercion Model Ascher
S 217 pep-0217.txt Display Hook for Interactive Use Zadka
***************
*** 100,104 ****
SD 205 pep-0205.txt Weak References Drake
I 206 pep-0206.txt 2.0 Batteries Included Zadka
! S 207 pep-0207.txt Rich Comparisons Ascher
S 208 pep-0208.txt Reworking the Coercion Model Ascher
SD 209 pep-0209.txt Adding Multidimensional Arrays Ascher
--- 100,104 ----
SD 205 pep-0205.txt Weak References Drake
I 206 pep-0206.txt 2.0 Batteries Included Zadka
! S 207 pep-0207.txt Rich Comparisons Zadka, Lemburg
S 208 pep-0208.txt Reworking the Coercion Model Ascher
SD 209 pep-0209.txt Adding Multidimensional Arrays Ascher

Index: pep-0207.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0207.txt,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** pep-0207.txt 2000/07/15 23:28:27 1.1
--- pep-0207.txt 2000/11/06 18:21:58 1.2
***************
*** 2,6 ****
Title: Rich Comparisions
Version: $Revision$
! Owner: davida@activestate.com (David Ascher)
Python-Version: 2.1
Status: Incomplete
--- 2,6 ----
Title: Rich Comparisions
Version: $Revision$
! Owner: mal@lemburg.com (Marc-Andre Lemburg), pep@zadka.site.co.il (Moshe Zadka)
Python-Version: 2.1
Status: Incomplete



From python-dev@python.org Mon Nov 6 18:46:11 2000
From: python-dev@python.org (Barry Warsaw)
Date: Mon, 6 Nov 2000 10:46:11 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib cgi.py,1.55,1.56
Message-ID: <200011061846.KAA07862@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv7854

Modified Files:
cgi.py
Log Message:
This fixes several bug reports concering memory bloating during large
file uploads.

In response to SF bugs 110674 and 119806, and discussions on
python-dev, we are removing the self.lines attribute from the
FieldStorage class. Specifically touched where methods __init__(),
read_lines_to_eof(), and skip_lines().

No one can remember why self.lines was added. Technically, it's part
of the public interface for the class, but it was never documented.
It's possible clever or nosy code will break because of this, but it
was decided to remove it and see who complains.

This resolution also closes the second half of the cgi.py entry in PEP
42. The first half of that PEP concerns specifically binary file
uploads, where there may be no end-of-line marker for a very long
time. This patch does not address that issue.


Index: cgi.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/cgi.py,v
retrieving revision 1.55
retrieving revision 1.56
diff -C2 -r1.55 -r1.56
*** cgi.py 2000/10/03 13:51:09 1.55
--- cgi.py 2000/11/06 18:46:09 1.56
***************
*** 20,24 ****
#

! __version__ = "2.4"


--- 20,24 ----
#

! __version__ = "2.5"


***************
*** 498,502 ****
self.list = self.file = None
self.done = 0
- self.lines = []
if ctype == 'application/x-www-form-urlencoded':
self.read_urlencoded()
--- 498,501 ----
***************
*** 634,638 ****
self.done = -1
break
- self.lines.append(line)
self.file.write(line)

--- 633,636 ----
***************
*** 647,651 ****
self.done = -1
break
- self.lines.append(line)
if line[:2] == "--":
strippedline = string.strip(line)
--- 645,648 ----
***************
*** 677,681 ****
self.done = -1
break
- self.lines.append(line)
if line[:2] == "--":
strippedline = string.strip(line)
--- 674,677 ----



From python-dev@python.org Mon Nov 6 18:49:08 2000
From: python-dev@python.org (Barry Warsaw)
Date: Mon, 6 Nov 2000 10:49:08 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0042.txt,1.42,1.43
Message-ID: <200011061849.KAA08213@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv8189

Modified Files:
pep-0042.txt
Log Message:
Updated the cgi.py entry after it was resolved to remove the
self.lines attribute. This doesn't completely address the binary file
upload part of the feature request.


Index: pep-0042.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0042.txt,v
retrieving revision 1.42
retrieving revision 1.43
diff -C2 -r1.42 -r1.43
*** pep-0042.txt 2000/11/02 16:54:19 1.42
--- pep-0042.txt 2000/11/06 18:49:06 1.43
***************
*** 178,186 ****
a binary type.

! Second, because the lines that are read are stored in an
! instance attribute (self.lines -- a list), the uploaded data is
! never freed. self.lines isn't definied as part of the public
! interface it /might/ be safe to remove it. OTOH, removing it
! will break code clever and nosy code.

- urllib should support proxy definitions that contain just the
--- 178,185 ----
a binary type.

! The second issue was related to the self.lines attribute, which
! was removed in revision 1.56 of cgi.py (see also):
!
! http://sourceforge.net/bugs/?funcÞtailbug&bug_id9806&group_idT70

- urllib should support proxy definitions that contain just the



From python-dev@python.org Mon Nov 6 20:17:40 2000
From: python-dev@python.org (Fred L. Drake)
Date: Mon, 6 Nov 2000 12:17:40 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib libstdtypes.tex,1.40,1.41
Message-ID: <200011062017.MAA18607@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv18590/lib

Modified Files:
libstdtypes.tex
Log Message:

Document the proper exception to be raised by I/O operations on closed
files; error reported by Ng Pheng Siong <ngps@post1.com>.

Make sure that various special object attributes are properly indexed.


Index: libstdtypes.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/libstdtypes.tex,v
retrieving revision 1.40
retrieving revision 1.41
diff -C2 -r1.40 -r1.41
*** libstdtypes.tex 2000/10/25 21:03:55 1.40
--- libstdtypes.tex 2000/11/06 20:17:37 1.41
***************
*** 973,976 ****
--- 973,977 ----
It is written as \code{Ellipsis}.

+
\subsubsection{File Objects\obindex{file}
\label{bltin-file-objects}}
***************
*** 996,1001 ****
\begin{methoddesc}[file]{close}{}
Close the file. A closed file cannot be read or written anymore.
! Any operation which requires that the file be open will raise an
! \exception{IOError} after the file has been closed. Calling
\method{close()} more than once is allowed.
\end{methoddesc}
--- 997,1002 ----
\begin{methoddesc}[file]{close}{}
Close the file. A closed file cannot be read or written anymore.
! Any operation which requires that the file be open will raise a
! \exception{ValueError} after the file has been closed. Calling
\method{close()} more than once is allowed.
\end{methoddesc}
***************
*** 1138,1141 ****
--- 1139,1143 ----
\end{memberdesc}

+
\subsubsection{Internal Objects \label{typesinternal}}

***************
*** 1150,1174 ****
object types, where they are relevant:

! \begin{memberdescni}{__dict__}
! A dictionary of some sort used to store an
object's (writable) attributes.
! \end{memberdescni}

! \begin{memberdescni}{__methods__}
List of the methods of many built-in object types,
e.g., \code{[].__methods__} yields
\code{['append', 'count', 'index', 'insert', 'pop', 'remove',
! 'reverse', 'sort']}.
! \end{memberdescni}

! \begin{memberdescni}{__members__}
! Similar to \member{__methods__}, but lists data attributes.
! \end{memberdescni}

! \begin{memberdescni}{__class__}
The class to which a class instance belongs.
! \end{memberdescni}

! \begin{memberdescni}{__bases__}
The tuple of base classes of a class object.
! \end{memberdescni}
--- 1152,1178 ----
object types, where they are relevant:

! \begin{memberdesc}[object]{__dict__}
! A dictionary or other mapping object used to store an
object's (writable) attributes.
! \end{memberdesc}

! \begin{memberdesc}[object]{__methods__}
List of the methods of many built-in object types,
e.g., \code{[].__methods__} yields
\code{['append', 'count', 'index', 'insert', 'pop', 'remove',
! 'reverse', 'sort']}. This usually does not need to be explicitly
! provided by the object.
! \end{memberdesc}

! \begin{memberdesc}[object]{__members__}
! Similar to \member{__methods__}, but lists data attributes. This
! usually does not need to be explicitly provided by the object.
! \end{memberdesc}

! \begin{memberdesc}[instance]{__class__}
The class to which a class instance belongs.
! \end{memberdesc}

! \begin{memberdesc}[class]{__bases__}
The tuple of base classes of a class object.
! \end{memberdesc}



From python-dev@python.org Tue Nov 7 03:34:47 2000
From: python-dev@python.org (A.M. Kuchling)
Date: Mon, 6 Nov 2000 19:34:47 -0800
Subject: [Python-checkins] CVS: python/dist/src/Modules _cursesmodule.c,2.40,2.41
Message-ID: <200011070334.TAA23335@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Modules
In directory slayer.i.sourceforge.net:/tmp/cvs-serv23315

Modified Files:
_cursesmodule.c
Log Message:
Patch #102278: add tparm() function to _curses module


Index: _cursesmodule.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Modules/_cursesmodule.c,v
retrieving revision 2.40
retrieving revision 2.41
diff -C2 -r2.40 -r2.41
*** _cursesmodule.c 2000/11/01 19:59:12 2.40
--- _cursesmodule.c 2000/11/07 03:34:44 2.41
***************
*** 48,55 ****
savetty scr_dump scr_init scr_restore scr_set scrl set_curterm
set_term setterm setupterm tgetent tgetflag tgetnum tgetstr
! tgoto timeout tparm tputs tputs typeahead use_default_colors
! vidattr vidputs waddchnstr waddchstr wchgat wcolor_set
! winchnstr winchstr winnstr wmouse_trafo wredrawln wscrl
! wtimeout

Low-priority:
--- 48,54 ----
savetty scr_dump scr_init scr_restore scr_set scrl set_curterm
set_term setterm setupterm tgetent tgetflag tgetnum tgetstr
! tgoto timeout tputs typeahead use_default_colors vidattr
! vidputs waddchnstr waddchstr wchgat wcolor_set winchnstr
! winchstr winnstr wmouse_trafo wredrawln wscrl wtimeout

Low-priority:
***************
*** 2099,2102 ****
--- 2098,2152 ----

static PyObject *
+ PyCurses_tparm(PyObject *self, PyObject *args)
+ {
+ char* fmt;
+ char* result = NULL;
+ int i1,i2,i3,i4,i5,i6,i7,i8,i9;
+
+ PyCursesInitialised;
+
+ if (!PyArg_ParseTuple(args, "s|iiiiiiiii:tparm",
+ &fmt, &i1, &i2, &i3, &i4,
+ &i5, &i6, &i7, &i8, &i9)) {
+ return NULL;
+ }
+
+ switch (PyTuple_GET_SIZE(args)) {
+ case 1:
+ result = tparm(fmt);
+ break;
+ case 2:
+ result = tparm(fmt,i1);
+ break;
+ case 3:
+ result = tparm(fmt,i1,i2);
+ break;
+ case 4:
+ result = tparm(fmt,i1,i2,i3);
+ break;
+ case 5:
+ result = tparm(fmt,i1,i2,i3,i4);
+ break;
+ case 6:
+ result = tparm(fmt,i1,i2,i3,i4,i5);
+ break;
+ case 7:
+ result = tparm(fmt,i1,i2,i3,i4,i5,i6);
+ break;
+ case 8:
+ result = tparm(fmt,i1,i2,i3,i4,i5,i6,i7);
+ break;
+ case 9:
+ result = tparm(fmt,i1,i2,i3,i4,i5,i6,i7,i8);
+ break;
+ case 10:
+ result = tparm(fmt,i1,i2,i3,i4,i5,i6,i7,i8,i9);
+ break;
+ }
+
+ return PyString_FromString(result);
+ }
+
+ static PyObject *
PyCurses_TypeAhead(PyObject *self, PyObject *args)
{
***************
*** 2247,2250 ****
--- 2297,2301 ----
{"tigetnum", (PyCFunction)PyCurses_tigetnum, METH_VARARGS},
{"tigetstr", (PyCFunction)PyCurses_tigetstr, METH_VARARGS},
+ {"tparm", (PyCFunction)PyCurses_tparm, METH_VARARGS},
{"typeahead", (PyCFunction)PyCurses_TypeAhead},
{"unctrl", (PyCFunction)PyCurses_UnCtrl},



From python-dev@python.org Tue Nov 7 03:35:26 2000
From: python-dev@python.org (A.M. Kuchling)
Date: Mon, 6 Nov 2000 19:35:26 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib libcurses.tex,1.20,1.21
Message-ID: <200011070335.TAA23460@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv23347

Modified Files:
libcurses.tex
Log Message:
Patch #102278: add tparm() function to _curses module


Index: libcurses.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/libcurses.tex,v
retrieving revision 1.20
retrieving revision 1.21
diff -C2 -r1.20 -r1.21
*** libcurses.tex 2000/10/10 17:03:45 1.20
--- libcurses.tex 2000/11/07 03:35:24 1.21
***************
*** 467,470 ****
--- 467,477 ----
\end{funcdesc}

+ \begin{funcdesc}{tparm}{str\optional{,...}}
+ Instantiates the string \var{str} with the supplied parameters, where
+ \var{str} should be a parameterized string obtained from the terminfo
+ database. E.g. \code{tparm(tigetstr("cup"),5,3)} could result in
+ \code{"\e{}033[6;4H"}, the exact result depending on terminal type.
+ \end{funcdesc}
+
\begin{funcdesc}{typeahead}{fd}
Specifies that the file descriptor \var{fd} be used for typeahead



From python-dev@python.org Tue Nov 7 09:11:07 2000
From: python-dev@python.org (Moshe Zadka)
Date: Tue, 7 Nov 2000 01:11:07 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0216.txt,1.3,1.4
Message-ID: <200011070911.BAA13249@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv13156

Modified Files:
pep-0216.txt
Log Message:
Added structured text consensus.


Index: pep-0216.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0216.txt,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** pep-0216.txt 2000/11/05 16:48:55 1.3
--- pep-0216.txt 2000/11/07 09:11:04 1.4
***************
*** 86,89 ****
--- 86,106 ----
e. List/tables

+ Docstring Basic Structure
+
+ The documentation strings will be in StructuredText
+ (http://www.zope.org/Members/jim/StructuredTextWiki/StructuredTextNG)
+ Since StructuredText is not yet strong enough to handle (a) and (b)
+ above, we will need to extend it. I suggest using
+ '[<optional description>:python identifier]'.
+ E.g.: [class:POP3], [:POP3.list], etc. If the description is missing,
+ a guess will be made from the text.
+
+ Unresolved Issues
+
+ How do we describe input and output types of functions?
+
+ What additional constraint do we enforce on each docstring?
+ (module/class/function)?
+
Rejected Suggestions




From python-dev@python.org Tue Nov 7 09:36:42 2000
From: python-dev@python.org (Fredrik Lundh)
Date: Tue, 7 Nov 2000 10:36:42 +0100
Subject: [Python-checkins] CVS: python/nondist/peps pep-0216.txt,1.3,1.4
References: <200011070911.BAA13249@slayer.i.sourceforge.net>
Message-ID: <01e301c0489e$3e349540$0900a8c0@SPIFF>

Moshe Zadka wrote:
Modified Files:
pep-0216.txt
Log Message:
Added structured text consensus.
when/where was this discussed?

</F>



From Moshe Zadka <moshez@math.huji.ac.il> Tue Nov 7 09:49:54 2000
From: Moshe Zadka (Moshe Zadka)
Date: Tue, 7 Nov 2000 11:49:54 +0200 (IST)
Subject: [Python-checkins] CVS: python/nondist/peps pep-0216.txt,1.3,1.4
In-Reply-To: <01e301c0489e$3e349540$0900a8c0@SPIFF>
Message-ID: <Pine.GSO.4.10.10011071149300.13407-100000@sundial>
On Tue, 7 Nov 2000, Fredrik Lundh wrote:

Moshe Zadka wrote:
Modified Files:
pep-0216.txt
Log Message:
Added structured text consensus.
when/where was this discussed?
ummmm....doc-sig, where all things documentation-related are discussed?

--
Moshe Zadka <moshez@math.huji.ac.il> -- 95855124
http://advogato.org/person/moshez



From python-dev@python.org Tue Nov 7 14:54:52 2000
From: python-dev@python.org (Greg Ward)
Date: Tue, 7 Nov 2000 06:54:52 -0800
Subject: [Python-checkins] CVS: python/nondist/sf-html sf-faq.html,1.16,1.17
Message-ID: <200011071454.GAA26318@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/sf-html
In directory slayer.i.sourceforge.net:/tmp/cvs-serv26310

Modified Files:
sf-faq.html
Log Message:
Fixed a couple of typos.

Index: sf-faq.html
==================================================================RCS file: /cvsroot/python/python/nondist/sf-html/sf-faq.html,v
retrieving revision 1.16
retrieving revision 1.17
diff -C2 -r1.16 -r1.17
*** sf-faq.html 2000/11/01 22:03:00 1.16
--- sf-faq.html 2000/11/07 14:54:50 1.17
***************
*** 336,340 ****

<h4>A:</h4>
! You probably want to turn of keyword expansion and line-ending conversion:

<blockquote>
--- 336,340 ----

<h4>A:</h4>
! You probably want to turn off keyword expansion and line-ending conversion:

<blockquote>
***************
*** 451,455 ****
<a href="http://sourceforge.net/bugs/?group_idT70">http://sourceforge.net/bugs/?group_idT70</a> for all bug management needs.

! <h3><a name="b1" id="b1"></a>6.1.:</h3>

<h4>Q: How do I use the sourceforge bug manager?</h4>
--- 451,455 ----
<a href="http://sourceforge.net/bugs/?group_idT70">http://sourceforge.net/bugs/?group_idT70</a> for all bug management needs.

! <h3><a name="b2" id="b2"></a>6.2.:</h3>

<h4>Q: How do I use the sourceforge bug manager?</h4>



From python-dev@python.org Tue Nov 7 15:44:24 2000
From: python-dev@python.org (Greg Ward)
Date: Tue, 7 Nov 2000 07:44:24 -0800
Subject: [Python-checkins] CVS: python/dist/src configure.in,1.177,1.178 configure,1.169,1.170
Message-ID: <200011071544.HAA31147@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src
In directory slayer.i.sourceforge.net:/tmp/cvs-serv30976

Modified Files:
configure.in configure
Log Message:
Fix for SF bug #117606:
- when compiling with GCC on Solaris, use "$(CC) -shared" instead
of "$(CC) -G" to generate .so files
- when compiling with GCC on any platform, add "-fPIC" to OPT
(without this, "$(CC) -shared" dies horribly)


Index: configure.in
==================================================================RCS file: /cvsroot/python/python/dist/src/configure.in,v
retrieving revision 1.177
retrieving revision 1.178
diff -C2 -r1.177 -r1.178
*** configure.in 2000/11/03 08:18:36 1.177
--- configure.in 2000/11/07 15:44:21 1.178
***************
*** 309,314 ****
yes)
case $ac_cv_prog_cc_g in
! yes) OPT="-g -O2 -Wall -Wstrict-prototypes";;
! *) OPT="-O2 -Wall -Wstrict-prototypes";;
esac
;;
--- 309,314 ----
yes)
case $ac_cv_prog_cc_g in
! yes) OPT="-g -O2 -Wall -Wstrict-prototypes -fPIC";;
! *) OPT="-O2 -Wall -Wstrict-prototypes -fPIC";;
esac
;;
***************
*** 565,569 ****
SunOS/5*)
if test "$GCC" = "yes"
! then LDSHARED='$(CC) -G'
else LDSHARED="ld -G";
fi ;;
--- 565,569 ----
SunOS/5*)
if test "$GCC" = "yes"
! then LDSHARED='$(CC) -shared'
else LDSHARED="ld -G";
fi ;;

Index: configure
==================================================================RCS file: /cvsroot/python/python/dist/src/configure,v
retrieving revision 1.169
retrieving revision 1.170
diff -C2 -r1.169 -r1.170
*** configure 2000/11/03 08:18:36 1.169
--- configure 2000/11/07 15:44:21 1.170
***************
*** 1,5 ****
#! /bin/sh

! # From configure.in Revision: 1.176

# Guess values for system-dependent variables and create Makefiles.
--- 1,5 ----
#! /bin/sh

! # From configure.in Revision: 1.178

# Guess values for system-dependent variables and create Makefiles.
***************
*** 1194,1199 ****
yes)
case $ac_cv_prog_cc_g in
! yes) OPT="-g -O2 -Wall -Wstrict-prototypes";;
! *) OPT="-O2 -Wall -Wstrict-prototypes";;
esac
;;
--- 1194,1199 ----
yes)
case $ac_cv_prog_cc_g in
! yes) OPT="-g -O2 -Wall -Wstrict-prototypes -fPIC";;
! *) OPT="-O2 -Wall -Wstrict-prototypes -fPIC";;
esac
;;
***************
*** 2651,2655 ****
SunOS/5*)
if test "$GCC" = "yes"
! then LDSHARED='$(CC) -G'
else LDSHARED="ld -G";
fi ;;
--- 2651,2655 ----
SunOS/5*)
if test "$GCC" = "yes"
! then LDSHARED='$(CC) -shared'
else LDSHARED="ld -G";
fi ;;
***************
*** 4840,4844 ****

/* Ultrix mips cc rejects this. */
! typedef int charset[2]; const charset x = {0,0};
/* SunOS 4.1.1 cc rejects this. */
char const *const *ccp;
--- 4840,4844 ----

/* Ultrix mips cc rejects this. */
! typedef int charset[2]; const charset x;
/* SunOS 4.1.1 cc rejects this. */
char const *const *ccp;
***************
*** 4915,4919 ****

int main() {
! } int $ac_kw foo() {
; return 0; }
EOF
--- 4915,4919 ----

int main() {
! } $ac_kw foo() {
; return 0; }
EOF



From python-dev@python.org Tue Nov 7 16:09:57 2000
From: python-dev@python.org (Fred L. Drake)
Date: Tue, 7 Nov 2000 08:09:57 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc ACKS,1.7,1.8
Message-ID: <200011071609.IAA01713@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc
In directory slayer.i.sourceforge.net:/tmp/cvs-serv1695/Doc

Modified Files:
ACKS
Log Message:

More names...


Index: ACKS
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/ACKS,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -r1.7 -r1.8
*** ACKS 2000/10/22 03:23:58 1.7
--- ACKS 2000/11/07 16:09:53 1.8
***************
*** 60,63 ****
--- 60,64 ----
Stefan Hoffmeister
Albert Hofkamp
+ Gregor Hoffleit
Gerrit Holl
Rob Hooft
***************
*** 103,106 ****
--- 104,108 ----
Sjoerd Mullender
Dale Nagata
+ Ng Pheng Siong
Koray Oner
Denis S. Otkidach



From python-dev@python.org Wed Nov 8 06:20:42 2000
From: python-dev@python.org (Fred L. Drake)
Date: Tue, 7 Nov 2000 22:20:42 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0205.txt,1.2,1.3
Message-ID: <200011080620.WAA20659@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv20652

Modified Files:
pep-0205.txt
Log Message:

Added some text describing the motivations for weak references, what is
available in Java, and pointers to previous work in Python.

There is a lot to be done before there can be a sample implementation;
issues related to implementation need to be discussed.


Index: pep-0205.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0205.txt,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** pep-0205.txt 2000/10/30 20:48:44 1.2
--- pep-0205.txt 2000/11/08 06:20:40 1.3
***************
*** 2,8 ****
Title: Weak References
Version: $Revision$
! Owner: fdrake@acm.org (Fred Drake)
Python-Version: 2.1
Status: Incomplete


--- 2,149 ----
Title: Weak References
Version: $Revision$
! Owner: Fred L. Drake, Jr. <fdrake@acm.org>
Python-Version: 2.1
Status: Incomplete
+ Type: Standards Track
+ Post-History:
+
+ Motivation
+
+ There are two basic applications for weak references which have
+ been noted by Python programmers: object caches and reduction of
+ pain from circular references.
+
+ Caches (weak dictionaries)
+
+ There is a need to allow objects to be maintained to represent
+ external state, mapping a single instance to the external
+ reality, where allowing multiple instances to be mapped to the
+ same external resource would create unnecessary difficulty
+ maintaining synchronization among instances. In these cases,
+ a common idiom is to support a cache of instances; a factory
+ function is used to return either a new or existing instance.
+
+ The difficulty in this approach is that one of two things must
+ be tolerated: either the cache grows without bound, or there
+ needs to be explicit management of the cache elsewhere in the
+ application. The later can be very tedious and leads to more
+ code than is really necessary to solve the problem at hand,
+ and the former can be unacceptable for long-running processes
+ or even relatively short processes with substantial memory
+ requirements.
+
+ - External objects that need to be represented by a single
+ instance, no matter how many internal users there are. This
+ can be useful for representing files that need to be written
+ back to disk in whole rather than locked & modified for
+ every use.
+
+ - Objects which are expensive to create, but may be needed by
+ multiple internal consumers. Similar to the first case, but
+ not necessarily bound to external resources, and possibly
+ not an issue for shared state. Weak references are only
+ useful in this case if there is some flavor of "soft"
+ references or if there is a high likelihood that users of
+ individual objects will overlap in lifespan.
+
+ Circular references
+
+ - DOMs require a huge amount of circular (to parent & document
+ nodes), but most of these aren't useful. Using weak
+ references allows applications to hold onto less of the tree
+ without a lot of difficulty. This might be especially
+ useful in the context of something like xml.dom.pulldom.
+
+
+ Weak References in Java
+
+ http://java.sun.com/j2se/1.3/docs/api/java/lang/ref/package-summary.html
+
+ Java provides three forms of weak references, and one interesting
+ helper class. The three forms are called "weak", "soft", and
+ "phantom" references. The relevant classes are defined in the
+ java.lang.ref package.
+
+ For each of the reference types, there is an option to add the
+ reference to a queue when it is invalidated by the memory
+ allocator. The primary purpose of this facility seems to be that
+ it allows larger structures to be composed to incorporate
+ weak-reference semantics without having to impose substantial
+ additional locking requirements. For instance, it would not be
+ difficult to use this facility to create a "weak" hash table which
+ removes keys and referents when a reference is no longer used
+ elsewhere. Using weak references for the objects without some
+ sort of notification queue for invalidations leads to much more
+ tedious implementation of the various operations required on hash
+ tables. This can be a performance bottleneck if deallocations of
+ the stored objects are infrequent.
+
+ Java's "weak" references are most like Diane Hackborn's old vref
+ proposal: a reference object refers to a single Python object,
+ but does not own a reference to that object. When that object is
+ deallocated, the reference object is invalidated. Users of the
+ reference object can easily determine that the reference has been
+ invalidated, or a NullObjectDereferenceError can be raised when
+ an attempt is made to use the referred-to object.
+
+ The "soft" references are similar, but are not invalidated as soon
+ as all other references to the referred-to object have been
+ released. The "soft" reference does own a reference, but allows
+ the memory allocator to free the referent if the memory is needed
+ elsewhere. It is not clear whether this means soft references are
+ released before the malloc() implementation calls sbrk() or its
+ equivalent, or if soft references are only cleared when malloc()
+ returns NULL.
+
+ XXX -- Need to figure out what phantom references are all about.
+
+ Unlike the other two reference types, "phantom" references must be
+ associated with an invalidation queue.
+
+
+ Previous Weak Reference Work in Python
+
+ Diane Hackborn's vref work. 'vref' objects were very similar to
+ java.lang.ref.WeakReference objects, except there was no
+ equivalent to the invalidation queues. Implementing a "weak
+ dictionary" would be just as difficult as using only weak
+ references (without the invalidation queue) in Java. Information
+ on this appears to have disappeared from the Web. Original
+ discussion occurred in the comp.lang.python newsgroup; a good
+ archive of that may turn up something more. Dianne's old Web
+ pages at Oregon State University have disappeared. I've sent an
+ email to what appears to be a recent email address for Dianne to
+ see if any information is still available.
+
+ Marc-André Lemburg's mx.Proxy package. These Web pages appear to
+ be unavailable at the moment.
+
+ http://starship.python.net/crew/lemburg/
+
+ The weakdict module by Dieter Maurer is implemented in C and
+ Python. It appears that the Web pages have not been updated since
+ Python 1.5.2a, so I'm not yet sure if the implementation is
+ compatible with Python 2.0.
+
+ http://www.handshake.de/~dieter/weakdict.html
+
+
+ Possible Applications
+
+ PyGTK+ bindings?
+
+ Tkinter?
+
+ DOM trees?
+
+
+ Proposed Implementation
+
+ XXX -- Not yet.
+
+
+ Copyright
+
+ This document has been placed in the public domain.





From python-dev@python.org Wed Nov 8 06:23:37 2000
From: python-dev@python.org (Fred L. Drake)
Date: Tue, 7 Nov 2000 22:23:37 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0000.txt,1.47,1.48
Message-ID: <200011080623.WAA20903@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv20894

Modified Files:
pep-0000.txt
Log Message:

Moved the "Weak References" PEP from empty to incomplete, even though
there is more than an abstract (not enough of the required parts are
in place still).


Index: pep-0000.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0000.txt,v
retrieving revision 1.47
retrieving revision 1.48
diff -C2 -r1.47 -r1.48
*** pep-0000.txt 2000/11/06 18:21:58 1.47
--- pep-0000.txt 2000/11/08 06:23:35 1.48
***************
*** 51,54 ****
--- 51,55 ----
Incomplete PEPs (only an abstract)

+ SD 205 pep-0205.txt Weak References Drake
SD 218 pep-0218.txt Adding a Built-In Set Object Type Wilson
SD 219 pep-0219.txt Stackless Python McMillan
***************
*** 57,61 ****
Empty PEPs (nothing written yet)

- SD 205 pep-0205.txt Weak References Drake
SD 209 pep-0209.txt Adding Multidimensional Arrays Ascher
SD 210 pep-0210.txt Decoupling the Interpreter Loop Ascher
--- 58,61 ----



From python-dev@python.org Wed Nov 8 06:47:08 2000
From: python-dev@python.org (Fred L. Drake)
Date: Tue, 7 Nov 2000 22:47:08 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0205.txt,1.3,1.4
Message-ID: <200011080647.WAA21933@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv21925

Modified Files:
pep-0205.txt
Log Message:

Slight update regarding Dianne Hackborn's vref() proposal from 1995;
there was never an implementation.


Index: pep-0205.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0205.txt,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** pep-0205.txt 2000/11/08 06:20:40 1.3
--- pep-0205.txt 2000/11/08 06:47:05 1.4
***************
*** 104,118 ****
Previous Weak Reference Work in Python

! Diane Hackborn's vref work. 'vref' objects were very similar to
! java.lang.ref.WeakReference objects, except there was no
equivalent to the invalidation queues. Implementing a "weak
dictionary" would be just as difficult as using only weak
references (without the invalidation queue) in Java. Information
! on this appears to have disappeared from the Web. Original
! discussion occurred in the comp.lang.python newsgroup; a good
! archive of that may turn up something more. Dianne's old Web
! pages at Oregon State University have disappeared. I've sent an
! email to what appears to be a recent email address for Dianne to
! see if any information is still available.

Marc-André Lemburg's mx.Proxy package. These Web pages appear to
--- 104,118 ----
Previous Weak Reference Work in Python

! Diane Hackborn's vref proposal. 'vref' objects were very similar
! to java.lang.ref.WeakReference objects, except there was no
equivalent to the invalidation queues. Implementing a "weak
dictionary" would be just as difficult as using only weak
references (without the invalidation queue) in Java. Information
! on this has disappeared from the Web. Original discussion
! occurred in the comp.lang.python newsgroup; a good archive of that
! may turn up something more.
!
! Dianne doesn't have any record of her proposal, and doesn't recall
! doing an implementation.

Marc-André Lemburg's mx.Proxy package. These Web pages appear to



From python-dev@python.org Wed Nov 8 15:17:51 2000
From: python-dev@python.org (Guido van Rossum)
Date: Wed, 8 Nov 2000 07:17:51 -0800
Subject: [Python-checkins] CVS: python/dist/src/Demo/threads Coroutine.py,NONE,1.1 fcmp.py,NONE,1.1 squasher.py,NONE,1.1 README,1.7,1.8
Message-ID: <200011081517.HAA16919@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Demo/threads
In directory slayer.i.sourceforge.net:/tmp/cvs-serv16912

Modified Files:
README
Added Files:
Coroutine.py fcmp.py squasher.py
Log Message:
Add 1994 Coroutine module by Tim Peters

--- NEW FILE ---
# Coroutine implementation using Python threads.
#
# Combines ideas from Guido's Generator module, and from the coroutine
# features of Icon and Simula 67.
#
# To run a collection of functions as coroutines, you need to create
# a Coroutine object to control them:
# co = Coroutine()
# and then 'create' a subsidiary object for each function in the
# collection:
# cof1 = co.create(f1 [, arg1, arg2, ...]) # [] means optional,
# cof2 = co.create(f2 [, arg1, arg2, ...]) #... not list
# cof3 = co.create(f3 [, arg1, arg2, ...])
# etc. The functions need not be distinct; 'create'ing the same
# function multiple times gives you independent instances of the
# function.
#
# To start the coroutines running, use co.tran on one of the create'd
# functions; e.g., co.tran(cof2). The routine that first executes
# co.tran is called the "main coroutine". It's special in several
# respects: it existed before you created the Coroutine object; if any of
# the create'd coroutines exits (does a return, or suffers an unhandled
# exception), EarlyExit error is raised in the main coroutine; and the
# co.detach() method transfers control directly to the main coroutine
# (you can't use co.tran() for this because the main coroutine doesn't
# have a name ...).
#
# Coroutine objects support these methods:
#
# handle = .create(func [, arg1, arg2, ...])
# Creates a coroutine for an invocation of func(arg1, arg2, ...),
# and returns a handle ("name") for the coroutine so created. The
# handle can be used as the target in a subsequent .tran().
#
# .tran(target, data=None)
# Transfer control to the create'd coroutine "target", optionally
# passing it an arbitrary piece of data. To the coroutine A that does
# the .tran, .tran acts like an ordinary function call: another
# coroutine B can .tran back to it later, and if it does A's .tran
# returns the 'data' argument passed to B's tran. E.g.,
#
# in coroutine coA in coroutine coC in coroutine coB
# x = co.tran(coC) co.tran(coB) co.tran(coA,12)
# print x # 12
#
# The data-passing feature is taken from Icon, and greatly cuts
# the need to use global variables for inter-coroutine communication.
#
# .back( data=None )
# The same as .tran(invoker, data=None), where 'invoker' is the
# coroutine that most recently .tran'ed control to the coroutine
# doing the .back. This is akin to Icon's "&source".
#
# .detach( data=None )
# The same as .tran(main, data=None), where 'main' is the
# (unnameable!) coroutine that started it all. 'main' has all the
# rights of any other coroutine: upon receiving control, it can
# .tran to an arbitrary coroutine of its choosing, go .back to
# the .detach'er, or .kill the whole thing.
#
# .kill()
# Destroy all the coroutines, and return control to the main
# coroutine. None of the create'ed coroutines can be resumed after a
# .kill(). An EarlyExit exception does a .kill() automatically. It's
# a good idea to .kill() coroutines you're done with, since the
# current implementation consumes a thread for each coroutine that
# may be resumed.

import thread
import sync

class _CoEvent:
def __init__(self, func):
self.f = func
self.e = sync.event()

def __repr__(self):
if self.f is None:
return 'main coroutine'
else:
return 'coroutine for func ' + self.f.func_name

def __hash__(self):
return id(self)

def __cmp__(x,y):
return cmp(id(x), id(y))

def resume(self):
self.e.post()

def wait(self):
self.e.wait()
self.e.clear()

Killed = 'Coroutine.Killed'
EarlyExit = 'Coroutine.EarlyExit'

class Coroutine:
def __init__(self):
self.active = self.main = _CoEvent(None)
self.invokedby = {self.main: None}
self.killed = 0
self.value = None
self.terminated_by = None

def create(self, func, *args):
me = _CoEvent(func)
self.invokedby[me] = None
thread.start_new_thread(self._start, (me,) + args)
return me

def _start(self, me, *args):
me.wait()
if not self.killed:
try:
try:
apply(me.f, args)
except Killed:
pass
finally:
if not self.killed:
self.terminated_by = me
self.kill()

def kill(self):
if self.killed:
raise TypeError, 'kill() called on dead coroutines'
self.killed = 1
for coroutine in self.invokedby.keys():
coroutine.resume()

def back(self, data=None):
return self.tran( self.invokedby[self.active], data )

def detach(self, data=None):
return self.tran( self.main, data )

def tran(self, target, data=None):
if not self.invokedby.has_key(target):
raise TypeError, '.tran target ' + `target` + \
' is not an active coroutine'
if self.killed:
raise TypeError, '.tran target ' + `target` + ' is killed'
self.value = data
me = self.active
self.invokedby[target] = me
self.active = target
target.resume()

me.wait()
if self.killed:
if self.main is not me:
raise Killed
if self.terminated_by is not None:
raise EarlyExit, `self.terminated_by` + ' terminated early'

return self.value

# end of module

--- NEW FILE ---
# Coroutine example: controlling multiple instances of a single function

from Coroutine import *

# fringe visits a nested list in inorder, and detaches for each non-list
# element; raises EarlyExit after the list is exhausted
def fringe( co, list ):
for x in list:
if type(x) is type([]):
fringe(co, x)
else:
co.detach(x)

def printinorder( list ):
co = Coroutine()
f = co.create(fringe, co, list)
try:
while 1:
print co.tran(f),
except EarlyExit:
pass
print

printinorder([1,2,3]) # 1 2 3
printinorder([[[[1,[2]]],3]]) # ditto
x = [0, 1, [2, [3]], [4,5], [[[6]]] ]
printinorder(x) # 0 1 2 3 4 5 6

# fcmp lexicographically compares the fringes of two nested lists
def fcmp( l1, l2 ):
co1 = Coroutine(); f1 = co1.create(fringe, co1, l1)
co2 = Coroutine(); f2 = co2.create(fringe, co2, l2)
while 1:
try:
v1 = co1.tran(f1)
except EarlyExit:
try:
v2 = co2.tran(f2)
except EarlyExit:
return 0
co2.kill()
return -1
try:
v2 = co2.tran(f2)
except EarlyExit:
co1.kill()
return 1
if v1 != v2:
co1.kill(); co2.kill()
return cmp(v1,v2)

print fcmp(range(7), x) # 0; fringes are equal
print fcmp(range(6), x) # -1; 1st list ends early
print fcmp(x, range(6)) # 1; 2nd list ends early
print fcmp(range(8), x) # 1; 2nd list ends early
print fcmp(x, range(8)) # -1; 1st list ends early
print fcmp([1,[[2],8]],
[[[1],2],8]) # 0
print fcmp([1,[[3],8]],
[[[1],2],8]) # 1
print fcmp([1,[[2],8]],
[[[1],2],9]) # -1

# end of example

--- NEW FILE ---
# Coroutine example: general coroutine transfers
#
# The program is a variation of a Simula 67 program due to Dahl & Hoare,
# who in turn credit the original example to Conway.
#
# We have a number of input lines, terminated by a 0 byte. The problem
# is to squash them together into output lines containing 72 characters
# each. A semicolon must be added between input lines. Runs of blanks
# and tabs in input lines must be squashed into single blanks.
# Occurrences of "**" in input lines must be replaced by "^".
#
# Here's a test case:

test = """\
d = sqrt(b**2 - 4*a*c)
twoa = 2*a
L = -b/twoa
R = d/twoa
A1 = L + R
A2 = L - R\0
"""

# The program should print:

# d = sqrt(b^2 - 4*a*c);twoa = 2*a; L = -b/twoa; R = d/twoa; A1 = L + R;
#A2 = L - R
#done

# getline: delivers the next input line to its invoker
# disassembler: grabs input lines from getline, and delivers them one
# character at a time to squasher, also inserting a semicolon into
# the stream between lines
# squasher: grabs characters from disassembler and passes them on to
# assembler, first replacing "**" with "^" and squashing runs of
# whitespace
# assembler: grabs characters from squasher and packs them into lines
# with 72 character each, delivering each such line to putline;
# when it sees a null byte, passes the last line to putline and
# then kills all the coroutines
# putline: grabs lines from assembler, and just prints them

from Coroutine import *

def getline(text):
for line in string.splitfields(text, '\n'):
co.back(line)

def disassembler():
while 1:
card = co.tran(cogetline)
for i in range(len(card)):
co.tran(cosquasher, card[i])
co.tran(cosquasher, ';')

def squasher():
while 1:
ch = co.tran(codisassembler)
if ch == '*':
ch2 = co.tran(codisassembler)
if ch2 == '*':
ch = '^'
else:
co.tran(coassembler, ch)
ch = ch2
if ch in ' \t':
while 1:
ch2 = co.tran(codisassembler)
if ch2 not in ' \t':
break
co.tran(coassembler, ' ')
ch = ch2
co.tran(coassembler, ch)

def assembler():
line = ''
while 1:
ch = co.tran(cosquasher)
if ch == '\0':
break
if len(line) == 72:
co.tran(coputline, line)
line = ''
line = line + ch
line = line + ' ' * (72 - len(line))
co.tran(coputline, line)
co.kill()

def putline():
while 1:
line = co.tran(coassembler)
print line

import string
co = Coroutine()
cogetline = co.create(getline, test)
coputline = co.create(putline)
coassembler = co.create(assembler)
codisassembler = co.create(disassembler)
cosquasher = co.create(squasher)

co.tran(coputline)
print 'done'

# end of example

Index: README
==================================================================RCS file: /cvsroot/python/python/dist/src/Demo/threads/README,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -r1.7 -r1.8
*** README 1998/02/14 03:11:36 1.7
--- README 2000/11/08 15:17:49 1.8
***************
*** 9,10 ****
--- 9,14 ----
telnet.py Version of ../sockets/telnet.py using threads.
wpi.py Version of ../scripts/pi.py using threads (needs stdwin).
+
+ Coroutine.py Coroutines using threads, by Tim Peters (22 May 94)
+ fcmp.py Example of above, by Tim
+ squasher.py Another example of above, also by Tim



From python-dev@python.org Wed Nov 8 18:37:07 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 8 Nov 2000 10:37:07 -0800
Subject: [Python-checkins] CVS: python/dist/src/Objects rangeobject.c,2.20,2.21
Message-ID: <200011081837.KAA03207@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Objects
In directory slayer.i.sourceforge.net:/tmp/cvs-serv3195/Objects

Modified Files:
rangeobject.c
Log Message:

In the containment test, get the boundary condition right. ">" was used
where ">=" should have been.

This closes bug #121965.


Index: rangeobject.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Objects/rangeobject.c,v
retrieving revision 2.20
retrieving revision 2.21
diff -C2 -r2.20 -r2.21
*** rangeobject.c 2000/09/01 23:29:27 2.20
--- rangeobject.c 2000/11/08 18:37:05 2.21
***************
*** 194,200 ****
return -1;

! if (num < r->start || (num - r->start) % r->step)
return 0;
! if (num > (r->start + (r->len * r->step)))
return 0;
return 1;
--- 194,200 ----
return -1;

! if ((num < r->start) || ((num - r->start) % r->step))
return 0;
! if (num >= (r->start + (r->len * r->step)))
return 0;
return 1;



From python-dev@python.org Wed Nov 8 19:42:46 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 8 Nov 2000 11:42:46 -0800
Subject: [Python-checkins] CVS: python/dist/src/Objects rangeobject.c,2.21,2.22
Message-ID: <200011081942.LAA08968@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Objects
In directory slayer.i.sourceforge.net:/tmp/cvs-serv8961/Objects

Modified Files:
rangeobject.c
Log Message:

Fixed support for containment test when a negative step is used; this
*really* closes bug #121965.

Added three attributes to the xrange object: start, stop, and step. These
are the same as for the slice objects.


Index: rangeobject.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Objects/rangeobject.c,v
retrieving revision 2.21
retrieving revision 2.22
diff -C2 -r2.21 -r2.22
*** rangeobject.c 2000/11/08 18:37:05 2.21
--- rangeobject.c 2000/11/08 19:42:43 2.22
***************
*** 3,6 ****
--- 3,8 ----

#include "Python.h"
+ #include "structmember.h"
+ #include <string.h>

typedef struct {
***************
*** 176,179 ****
--- 178,183 ----
range_getattr(rangeobject *r, char *name)
{
+ PyObject *result;
+
static PyMethodDef range_methods[] = {
{"tolist", (PyCFunction)range_tolist, METH_VARARGS,
***************
*** 182,187 ****
{NULL, NULL}
};

! return Py_FindMethod(range_methods, (PyObject *) r, name);
}

--- 186,205 ----
{NULL, NULL}
};
+ static struct memberlist range_members[] = {
+ {"step", T_LONG, offsetof(rangeobject, step), RO},
+ {"start", T_LONG, offsetof(rangeobject, start), RO},
+ {"stop", T_LONG, 0, RO},
+ {NULL, 0, 0, 0}
+ };

! result = Py_FindMethod(range_methods, (PyObject *) r, name);
! if (result == NULL) {
! PyErr_Clear();
! if (strcmp("stop", name) == 0)
! result = PyInt_FromLong(r->start + (r->len * r->step));
! else
! result = PyMember_Get((char *)r, range_members, name);
! }
! return result;
}

***************
*** 194,212 ****
return -1;

! if ((num < r->start) || ((num - r->start) % r->step))
! return 0;
! if (num >= (r->start + (r->len * r->step)))
! return 0;
return 1;
}

static PySequenceMethods range_as_sequence = {
! (inquiry)range_length, /*sq_length*/
(binaryfunc)range_concat, /*sq_concat*/
(intargfunc)range_repeat, /*sq_repeat*/
(intargfunc)range_item, /*sq_item*/
(intintargfunc)range_slice, /*sq_slice*/
! 0, /*sq_ass_item*/
! 0, /*sq_ass_slice*/
(objobjproc)range_contains, /*sq_contains*/
};
--- 212,238 ----
return -1;

! if (r->step > 0) {
! if ((num < r->start) || ((num - r->start) % r->step))
! return 0;
! if (num >= (r->start + (r->len * r->step)))
! return 0;
! }
! else {
! if ((num > r->start) || ((num - r->start) % r->step))
! return 0;
! if (num <= (r->start + (r->len * r->step)))
! return 0;
! }
return 1;
}

static PySequenceMethods range_as_sequence = {
! (inquiry)range_length, /*sq_length*/
(binaryfunc)range_concat, /*sq_concat*/
(intargfunc)range_repeat, /*sq_repeat*/
(intargfunc)range_item, /*sq_item*/
(intintargfunc)range_slice, /*sq_slice*/
! 0, /*sq_ass_item*/
! 0, /*sq_ass_slice*/
(objobjproc)range_contains, /*sq_contains*/
};



From python-dev@python.org Wed Nov 8 19:51:28 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 8 Nov 2000 11:51:28 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib/test test_b2.py,1.19,1.20
Message-ID: <200011081951.LAA09686@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib/test
In directory slayer.i.sourceforge.net:/tmp/cvs-serv9678/Lib/test

Modified Files:
test_b2.py
Log Message:

Added test cases to detect regression on SourceForge bug #121965.


Index: test_b2.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/test/test_b2.py,v
retrieving revision 1.19
retrieving revision 1.20
diff -C2 -r1.19 -r1.20
*** test_b2.py 2000/10/23 17:22:07 1.19
--- test_b2.py 2000/11/08 19:51:25 1.20
***************
*** 255,258 ****
--- 255,272 ----
if tuple(xrange(0,10,2)) <> tuple(range(0,10,2)):
raise TestFailed, 'xrange(0,10,2)'
+ # regression tests for SourceForge bug #121695
+ def _range_test(r):
+ assert r.start != r.stop, 'Test not valid for passed-in xrange object.'
+ if r.stop in r:
+ raise TestFailed, 'r.stop in ' + `r`
+ if r.stop-r.step not in r:
+ raise TestFailed, 'r.stop-r.step not in ' + `r`
+ if r.start not in r:
+ raise TestFailed, 'r.start not in ' + `r`
+ if r.stop+r.step in r:
+ raise TestFailed, 'r.stop+r.step in ' + `r`
+ _range_test(xrange(10))
+ _range_test(xrange(9, -1, -1))
+ _range_test(xrange(0, 10, 2))

print 'zip'



From python-dev@python.org Wed Nov 8 20:23:02 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 8 Nov 2000 12:23:02 -0800
Subject: [Python-checkins] CVS: python/dist/src configure.in,1.178,1.179 config.h.in,2.78,2.79
Message-ID: <200011082023.MAA12997@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src
In directory slayer.i.sourceforge.net:/tmp/cvs-serv12982

Modified Files:
configure.in config.h.in
Log Message:

Remove AC_C_INLINE test from configure.in, since the only place the symbol
occurs in the Python sources appears to be as text in comments. We do not
want to interfere with C++ keywords!

This closes bug #119851.


Index: configure.in
==================================================================RCS file: /cvsroot/python/python/dist/src/configure.in,v
retrieving revision 1.178
retrieving revision 1.179
diff -C2 -r1.178 -r1.179
*** configure.in 2000/11/07 15:44:21 1.178
--- configure.in 2000/11/08 20:22:59 1.179
***************
*** 1008,1012 ****
AC_C_CHAR_UNSIGNED
AC_C_CONST
- AC_C_INLINE

works=no
--- 1008,1011 ----

Index: config.h.in
==================================================================RCS file: /cvsroot/python/python/dist/src/config.h.in,v
retrieving revision 2.78
retrieving revision 2.79
diff -C2 -r2.78 -r2.79
*** config.h.in 2000/10/09 21:48:02 2.78
--- config.h.in 2000/11/08 20:22:59 2.79
***************
*** 26,32 ****
#undef HAVE_TZNAME

- /* Define as __inline if that's what the C compiler calls it. */
- #undef inline
-
/* Define if on MINIX. */
#undef _MINIX
--- 26,29 ----



From python-dev@python.org Wed Nov 8 22:19:54 2000
From: python-dev@python.org (Barry Warsaw)
Date: Wed, 8 Nov 2000 14:19:54 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib smtplib.py,1.29,1.30
Message-ID: <200011082219.OAA01283@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv1265

Modified Files:
smtplib.py
Log Message:
SMTP.connect(): If the socket.connect() raises a socket.error, be sure
to call self.close() to reclaim some file descriptors, the reraise the
exception. Closes SF patch #102185 and SF bug #119833.


Index: smtplib.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/smtplib.py,v
retrieving revision 1.29
retrieving revision 1.30
diff -C2 -r1.29 -r1.30
*** smtplib.py 2000/09/01 06:40:07 1.29
--- smtplib.py 2000/11/08 22:19:47 1.30
***************
*** 215,219 ****
self.sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
if self.debuglevel > 0: print 'connect:', (host, port)
! self.sock.connect((host, port))
(code,msg)=self.getreply()
if self.debuglevel >0 : print "connect:", msg
--- 215,223 ----
self.sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
if self.debuglevel > 0: print 'connect:', (host, port)
! try:
! self.sock.connect((host, port))
! except socket.error:
! self.close()
! raise
(code,msg)=self.getreply()
if self.debuglevel >0 : print "connect:", msg



From python-dev@python.org Thu Nov 9 18:05:26 2000
From: python-dev@python.org (Guido van Rossum)
Date: Thu, 9 Nov 2000 10:05:26 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib rfc822.py,1.49,1.50
Message-ID: <200011091805.KAA26538@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv26530

Modified Files:
rfc822.py
Log Message:
Implement the suggestion of bug_id2070: surround tell() call with
try/except.


Index: rfc822.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/rfc822.py,v
retrieving revision 1.49
retrieving revision 1.50
diff -C2 -r1.49 -r1.50
*** rfc822.py 2000/09/25 15:08:27 1.49
--- rfc822.py 2000/11/09 18:05:24 1.50
***************
*** 133,137 ****
while 1:
if tell:
! startofline = tell()
line = self.fp.readline()
if not line:
--- 133,141 ----
while 1:
if tell:
! try:
! startofline = tell()
! except IOError:
! startofline = tell = None
! self.seekable = 0
line = self.fp.readline()
if not line:



From python-dev@python.org Thu Nov 9 21:14:43 2000
From: python-dev@python.org (Guido van Rossum)
Date: Thu, 9 Nov 2000 13:14:43 -0800
Subject: [Python-checkins] CVS: python/dist/src configure,1.170,1.171
Message-ID: <200011092114.NAA11286@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src
In directory slayer.i.sourceforge.net:/tmp/cvs-serv11273

Modified Files:
configure
Log Message:
Committing autoconf output for
Fred.

Index: configure
==================================================================RCS file: /cvsroot/python/python/dist/src/configure,v
retrieving revision 1.170
retrieving revision 1.171
diff -C2 -r1.170 -r1.171
*** configure 2000/11/07 15:44:21 1.170
--- configure 2000/11/09 21:14:40 1.171
***************
*** 1,5 ****
#! /bin/sh

! # From configure.in Revision: 1.178

# Guess values for system-dependent variables and create Makefiles.
--- 1,5 ----
#! /bin/sh

! # From configure.in Revision: 1.179

# Guess values for system-dependent variables and create Makefiles.
***************
*** 4903,4952 ****
fi

- echo $ac_n "checking for inline""... $ac_c" 1>&6
- echo "configure:4907: checking for inline" >&5
- if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
- ac_cv_c_inline=no
- for ac_kw in inline __inline__ __inline; do
- cat > conftest.$ac_ext <<EOF
- #line 4914 "configure"
- #include "confdefs.h"
-
- int main() {
- } $ac_kw foo() {
- ; return 0; }
- EOF
- if { (eval echo configure:4921: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
- rm -rf conftest*
- ac_cv_c_inline=$ac_kw; break
- else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- fi
- rm -f conftest*
- done
-
- fi
-
- echo "$ac_t""$ac_cv_c_inline" 1>&6
- case "$ac_cv_c_inline" in
- inline | yes) ;;
- no) cat >> confdefs.h <<\EOF
- #define inline
- EOF
- ;;
- *) cat >> confdefs.h <<EOF
- #define inline $ac_cv_c_inline
- EOF
- ;;
- esac

-
works=no
echo $ac_n "checking for working volatile""... $ac_c" 1>&6
! echo "configure:4949: checking for working volatile" >&5
cat > conftest.$ac_ext <<EOF
! #line 4951 "configure"
#include "confdefs.h"

--- 4903,4912 ----
fi


works=no
echo $ac_n "checking for working volatile""... $ac_c" 1>&6
! echo "configure:4909: checking for working volatile" >&5
cat > conftest.$ac_ext <<EOF
! #line 4911 "configure"
#include "confdefs.h"

***************
*** 4955,4959 ****
; return 0; }
EOF
! if { (eval echo configure:4958: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
works=yes
--- 4915,4919 ----
; return 0; }
EOF
! if { (eval echo configure:4918: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
works=yes
***************
*** 4972,4978 ****
works=no
echo $ac_n "checking for working signed char""... $ac_c" 1>&6
! echo "configure:4975: checking for working signed char" >&5
cat > conftest.$ac_ext <<EOF
! #line 4977 "configure"
#include "confdefs.h"

--- 4932,4938 ----
works=no
echo $ac_n "checking for working signed char""... $ac_c" 1>&6
! echo "configure:4935: checking for working signed char" >&5
cat > conftest.$ac_ext <<EOF
! #line 4937 "configure"
#include "confdefs.h"

***************
*** 4981,4985 ****
; return 0; }
EOF
! if { (eval echo configure:4984: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
works=yes
--- 4941,4945 ----
; return 0; }
EOF
! if { (eval echo configure:4944: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
works=yes
***************
*** 4998,5004 ****
have_prototypes=no
echo $ac_n "checking for prototypes""... $ac_c" 1>&6
! echo "configure:5001: checking for prototypes" >&5
cat > conftest.$ac_ext <<EOF
! #line 5003 "configure"
#include "confdefs.h"
int foo(int x) { return 0; }
--- 4958,4964 ----
have_prototypes=no
echo $ac_n "checking for prototypes""... $ac_c" 1>&6
! echo "configure:4961: checking for prototypes" >&5
cat > conftest.$ac_ext <<EOF
! #line 4963 "configure"
#include "confdefs.h"
int foo(int x) { return 0; }
***************
*** 5007,5011 ****
; return 0; }
EOF
! if { (eval echo configure:5010: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
cat >> confdefs.h <<\EOF
--- 4967,4971 ----
; return 0; }
EOF
! if { (eval echo configure:4970: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
cat >> confdefs.h <<\EOF
***************
*** 5022,5028 ****
works=no
echo $ac_n "checking for variable length prototypes and stdarg.h""... $ac_c" 1>&6
! echo "configure:5025: checking for variable length prototypes and stdarg.h" >&5
cat > conftest.$ac_ext <<EOF
! #line 5027 "configure"
#include "confdefs.h"

--- 4982,4988 ----
works=no
echo $ac_n "checking for variable length prototypes and stdarg.h""... $ac_c" 1>&6
! echo "configure:4985: checking for variable length prototypes and stdarg.h" >&5
cat > conftest.$ac_ext <<EOF
! #line 4987 "configure"
#include "confdefs.h"

***************
*** 5041,5045 ****
; return 0; }
EOF
! if { (eval echo configure:5044: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
cat >> confdefs.h <<\EOF
--- 5001,5005 ----
; return 0; }
EOF
! if { (eval echo configure:5004: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
cat >> confdefs.h <<\EOF
***************
*** 5057,5063 ****
bad_prototypes=no
echo $ac_n "checking for bad exec* prototypes""... $ac_c" 1>&6
! echo "configure:5060: checking for bad exec* prototypes" >&5
cat > conftest.$ac_ext <<EOF
! #line 5062 "configure"
#include "confdefs.h"
#include <unistd.h>
--- 5017,5023 ----
bad_prototypes=no
echo $ac_n "checking for bad exec* prototypes""... $ac_c" 1>&6
! echo "configure:5020: checking for bad exec* prototypes" >&5
cat > conftest.$ac_ext <<EOF
! #line 5022 "configure"
#include "confdefs.h"
#include <unistd.h>
***************
*** 5066,5070 ****
; return 0; }
EOF
! if { (eval echo configure:5069: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
:
else
--- 5026,5030 ----
; return 0; }
EOF
! if { (eval echo configure:5029: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
:
else
***************
*** 5083,5092 ****
bad_forward=no
echo $ac_n "checking for bad static forward""... $ac_c" 1>&6
! echo "configure:5086: checking for bad static forward" >&5
if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
! #line 5091 "configure"
#include "confdefs.h"

--- 5043,5052 ----
bad_forward=no
echo $ac_n "checking for bad static forward""... $ac_c" 1>&6
! echo "configure:5046: checking for bad static forward" >&5
if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
! #line 5051 "configure"
#include "confdefs.h"

***************
*** 5104,5108 ****

EOF
! if { (eval echo configure:5107: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
:
--- 5064,5068 ----

EOF
! if { (eval echo configure:5067: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
:
***************
*** 5123,5129 ****
va_list_is_array=no
echo $ac_n "checking whether va_list is an array""... $ac_c" 1>&6
! echo "configure:5126: checking whether va_list is an array" >&5
cat > conftest.$ac_ext <<EOF
! #line 5128 "configure"
#include "confdefs.h"

--- 5083,5089 ----
va_list_is_array=no
echo $ac_n "checking whether va_list is an array""... $ac_c" 1>&6
! echo "configure:5086: checking whether va_list is an array" >&5
cat > conftest.$ac_ext <<EOF
! #line 5088 "configure"
#include "confdefs.h"

***************
*** 5138,5142 ****
; return 0; }
EOF
! if { (eval echo configure:5141: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
:
else
--- 5098,5102 ----
; return 0; }
EOF
! if { (eval echo configure:5101: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
:
else
***************
*** 5154,5163 ****
# sigh -- gethostbyname_r is a mess; it can have 3, 5 or 6 arguments :-(
echo $ac_n "checking for gethostbyname_r""... $ac_c" 1>&6
! echo "configure:5157: checking for gethostbyname_r" >&5
if eval "test \"`echo '$''{'ac_cv_func_gethostbyname_r'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5162 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
--- 5114,5123 ----
# sigh -- gethostbyname_r is a mess; it can have 3, 5 or 6 arguments :-(
echo $ac_n "checking for gethostbyname_r""... $ac_c" 1>&6
! echo "configure:5117: checking for gethostbyname_r" >&5
if eval "test \"`echo '$''{'ac_cv_func_gethostbyname_r'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5122 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
***************
*** 5182,5186 ****
; return 0; }
EOF
! if { (eval echo configure:5185: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_gethostbyname_r=yes"
--- 5142,5146 ----
; return 0; }
EOF
! if { (eval echo configure:5145: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_gethostbyname_r=yes"
***************
*** 5202,5210 ****

echo $ac_n "checking gethostbyname_r with 6 args""... $ac_c" 1>&6
! echo "configure:5205: checking gethostbyname_r with 6 args" >&5
OLD_CFLAGS=$CFLAGS
CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS"
cat > conftest.$ac_ext <<EOF
! #line 5209 "configure"
#include "confdefs.h"

--- 5162,5170 ----

echo $ac_n "checking gethostbyname_r with 6 args""... $ac_c" 1>&6
! echo "configure:5165: checking gethostbyname_r with 6 args" >&5
OLD_CFLAGS=$CFLAGS
CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS"
cat > conftest.$ac_ext <<EOF
! #line 5169 "configure"
#include "confdefs.h"

***************
*** 5223,5227 ****
; return 0; }
EOF
! if { (eval echo configure:5226: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*

--- 5183,5187 ----
; return 0; }
EOF
! if { (eval echo configure:5186: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*

***************
*** 5243,5249 ****
echo "$ac_t""no" 1>&6
echo $ac_n "checking gethostbyname_r with 5 args""... $ac_c" 1>&6
! echo "configure:5246: checking gethostbyname_r with 5 args" >&5
cat > conftest.$ac_ext <<EOF
! #line 5248 "configure"
#include "confdefs.h"

--- 5203,5209 ----
echo "$ac_t""no" 1>&6
echo $ac_n "checking gethostbyname_r with 5 args""... $ac_c" 1>&6
! echo "configure:5206: checking gethostbyname_r with 5 args" >&5
cat > conftest.$ac_ext <<EOF
! #line 5208 "configure"
#include "confdefs.h"

***************
*** 5262,5266 ****
; return 0; }
EOF
! if { (eval echo configure:5265: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*

--- 5222,5226 ----
; return 0; }
EOF
! if { (eval echo configure:5225: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*

***************
*** 5282,5288 ****
echo "$ac_t""no" 1>&6
echo $ac_n "checking gethostbyname_r with 3 args""... $ac_c" 1>&6
! echo "configure:5285: checking gethostbyname_r with 3 args" >&5
cat > conftest.$ac_ext <<EOF
! #line 5287 "configure"
#include "confdefs.h"

--- 5242,5248 ----
echo "$ac_t""no" 1>&6
echo $ac_n "checking gethostbyname_r with 3 args""... $ac_c" 1>&6
! echo "configure:5245: checking gethostbyname_r with 3 args" >&5
cat > conftest.$ac_ext <<EOF
! #line 5247 "configure"
#include "confdefs.h"

***************
*** 5299,5303 ****
; return 0; }
EOF
! if { (eval echo configure:5302: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*

--- 5259,5263 ----
; return 0; }
EOF
! if { (eval echo configure:5262: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*

***************
*** 5335,5344 ****
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
! echo "configure:5338: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5343 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
--- 5295,5304 ----
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
! echo "configure:5298: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5303 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
***************
*** 5363,5367 ****
; return 0; }
EOF
! if { (eval echo configure:5366: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
--- 5323,5327 ----
; return 0; }
EOF
! if { (eval echo configure:5326: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
***************
*** 5401,5410 ****
# Linux requires this for correct f.p. operations
echo $ac_n "checking for __fpu_control""... $ac_c" 1>&6
! echo "configure:5404: checking for __fpu_control" >&5
if eval "test \"`echo '$''{'ac_cv_func___fpu_control'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5409 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
--- 5361,5370 ----
# Linux requires this for correct f.p. operations
echo $ac_n "checking for __fpu_control""... $ac_c" 1>&6
! echo "configure:5364: checking for __fpu_control" >&5
if eval "test \"`echo '$''{'ac_cv_func___fpu_control'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5369 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
***************
*** 5429,5433 ****
; return 0; }
EOF
! if { (eval echo configure:5432: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func___fpu_control=yes"
--- 5389,5393 ----
; return 0; }
EOF
! if { (eval echo configure:5392: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func___fpu_control=yes"
***************
*** 5447,5451 ****
echo "$ac_t""no" 1>&6
echo $ac_n "checking for __fpu_control in -lieee""... $ac_c" 1>&6
! echo "configure:5450: checking for __fpu_control in -lieee" >&5
ac_lib_var=`echo ieee'_'__fpu_control | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
--- 5407,5411 ----
echo "$ac_t""no" 1>&6
echo $ac_n "checking for __fpu_control in -lieee""... $ac_c" 1>&6
! echo "configure:5410: checking for __fpu_control in -lieee" >&5
ac_lib_var=`echo ieee'_'__fpu_control | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
***************
*** 5455,5459 ****
LIBS="-lieee $LIBS"
cat > conftest.$ac_ext <<EOF
! #line 5458 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
--- 5415,5419 ----
LIBS="-lieee $LIBS"
cat > conftest.$ac_ext <<EOF
! #line 5418 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
***************
*** 5466,5470 ****
; return 0; }
EOF
! if { (eval echo configure:5469: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
--- 5426,5430 ----
; return 0; }
EOF
! if { (eval echo configure:5429: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
***************
*** 5499,5503 ****
# Check for --with-fpectl
echo $ac_n "checking for --with-fpectl""... $ac_c" 1>&6
! echo "configure:5502: checking for --with-fpectl" >&5
# Check whether --with-fpectl or --without-fpectl was given.
if test "${with_fpectl+set}" = set; then
--- 5459,5463 ----
# Check for --with-fpectl
echo $ac_n "checking for --with-fpectl""... $ac_c" 1>&6
! echo "configure:5462: checking for --with-fpectl" >&5
# Check whether --with-fpectl or --without-fpectl was given.
if test "${with_fpectl+set}" = set; then
***************
*** 5525,5529 ****
esac
echo $ac_n "checking for --with-libm=STRING""... $ac_c" 1>&6
! echo "configure:5528: checking for --with-libm=STRING" >&5
# Check whether --with-libm or --without-libm was given.
if test "${with_libm+set}" = set; then
--- 5485,5489 ----
esac
echo $ac_n "checking for --with-libm=STRING""... $ac_c" 1>&6
! echo "configure:5488: checking for --with-libm=STRING" >&5
# Check whether --with-libm or --without-libm was given.
if test "${with_libm+set}" = set; then
***************
*** 5546,5550 ****

echo $ac_n "checking for --with-libc=STRING""... $ac_c" 1>&6
! echo "configure:5549: checking for --with-libc=STRING" >&5
# Check whether --with-libc or --without-libc was given.
if test "${with_libc+set}" = set; then
--- 5506,5510 ----

echo $ac_n "checking for --with-libc=STRING""... $ac_c" 1>&6
! echo "configure:5509: checking for --with-libc=STRING" >&5
# Check whether --with-libc or --without-libc was given.
if test "${with_libc+set}" = set; then
***************
*** 5570,5579 ****
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
! echo "configure:5573: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5578 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
--- 5530,5539 ----
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
! echo "configure:5533: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5538 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
***************
*** 5598,5602 ****
; return 0; }
EOF
! if { (eval echo configure:5601: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
--- 5558,5562 ----
; return 0; }
EOF
! if { (eval echo configure:5561: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
***************
*** 5628,5632 ****
# check whether malloc(0) returns NULL or not
echo $ac_n "checking what malloc(0) returns""... $ac_c" 1>&6
! echo "configure:5631: checking what malloc(0) returns" >&5
if eval "test \"`echo '$''{'ac_cv_malloc_zero'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
--- 5588,5592 ----
# check whether malloc(0) returns NULL or not
echo $ac_n "checking what malloc(0) returns""... $ac_c" 1>&6
! echo "configure:5591: checking what malloc(0) returns" >&5
if eval "test \"`echo '$''{'ac_cv_malloc_zero'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
***************
*** 5636,5640 ****
else
cat > conftest.$ac_ext <<EOF
! #line 5639 "configure"
#include "confdefs.h"
#include <stdio.h>
--- 5596,5600 ----
else
cat > conftest.$ac_ext <<EOF
! #line 5599 "configure"
#include "confdefs.h"
#include <stdio.h>
***************
*** 5655,5659 ****
}
EOF
! if { (eval echo configure:5658: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_malloc_zero=nonnull
--- 5615,5619 ----
}
EOF
! if { (eval echo configure:5618: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_malloc_zero=nonnull
***************
*** 5681,5695 ****
ac_safe=`echo "wchar.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for wchar.h""... $ac_c" 1>&6
! echo "configure:5684: checking for wchar.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5689 "configure"
#include "confdefs.h"
#include <wchar.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
! { (eval echo configure:5694: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
--- 5641,5655 ----
ac_safe=`echo "wchar.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for wchar.h""... $ac_c" 1>&6
! echo "configure:5644: checking for wchar.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5649 "configure"
#include "confdefs.h"
#include <wchar.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
! { (eval echo configure:5654: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
***************
*** 5721,5730 ****
usable_wchar_t="unkown"
echo $ac_n "checking for usable wchar_t""... $ac_c" 1>&6
! echo "configure:5724: checking for usable wchar_t" >&5
if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
! #line 5729 "configure"
#include "confdefs.h"

--- 5681,5690 ----
usable_wchar_t="unkown"
echo $ac_n "checking for usable wchar_t""... $ac_c" 1>&6
! echo "configure:5684: checking for usable wchar_t" >&5
if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
! #line 5689 "configure"
#include "confdefs.h"

***************
*** 5740,5744 ****

EOF
! if { (eval echo configure:5743: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
cat >> confdefs.h <<\EOF
--- 5700,5704 ----

EOF
! if { (eval echo configure:5703: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
cat >> confdefs.h <<\EOF
***************
*** 5759,5763 ****
# check for endianness
echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
! echo "configure:5762: checking whether byte ordering is bigendian" >&5
if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
--- 5719,5723 ----
# check for endianness
echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
! echo "configure:5722: checking whether byte ordering is bigendian" >&5
if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
***************
*** 5766,5770 ****
# See if sys/param.h defines the BYTE_ORDER macro.
cat > conftest.$ac_ext <<EOF
! #line 5769 "configure"
#include "confdefs.h"
#include <sys/types.h>
--- 5726,5730 ----
# See if sys/param.h defines the BYTE_ORDER macro.
cat > conftest.$ac_ext <<EOF
! #line 5729 "configure"
#include "confdefs.h"
#include <sys/types.h>
***************
*** 5777,5785 ****
; return 0; }
EOF
! if { (eval echo configure:5780: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
# It does; now see whether it defined to BIG_ENDIAN or not.
cat > conftest.$ac_ext <<EOF
! #line 5784 "configure"
#include "confdefs.h"
#include <sys/types.h>
--- 5737,5745 ----
; return 0; }
EOF
! if { (eval echo configure:5740: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
# It does; now see whether it defined to BIG_ENDIAN or not.
cat > conftest.$ac_ext <<EOF
! #line 5744 "configure"
#include "confdefs.h"
#include <sys/types.h>
***************
*** 5792,5796 ****
; return 0; }
EOF
! if { (eval echo configure:5795: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_bigendian=yes
--- 5752,5756 ----
; return 0; }
EOF
! if { (eval echo configure:5755: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_bigendian=yes
***************
*** 5812,5816 ****
else
cat > conftest.$ac_ext <<EOF
! #line 5815 "configure"
#include "confdefs.h"
main () {
--- 5772,5776 ----
else
cat > conftest.$ac_ext <<EOF
! #line 5775 "configure"
#include "confdefs.h"
main () {
***************
*** 5825,5829 ****
}
EOF
! if { (eval echo configure:5828: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_bigendian=no
--- 5785,5789 ----
}
EOF
! if { (eval echo configure:5788: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_bigendian=no
***************
*** 5852,5856 ****
# or fills with zeros (like the Cray J90, according to Tim Peters).
echo $ac_n "checking whether right shift extends the sign bit""... $ac_c" 1>&6
! echo "configure:5855: checking whether right shift extends the sign bit" >&5
if eval "test \"`echo '$''{'ac_cv_rshift_extends_sign'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
--- 5812,5816 ----
# or fills with zeros (like the Cray J90, according to Tim Peters).
echo $ac_n "checking whether right shift extends the sign bit""... $ac_c" 1>&6
! echo "configure:5815: checking whether right shift extends the sign bit" >&5
if eval "test \"`echo '$''{'ac_cv_rshift_extends_sign'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
***************
*** 5861,5865 ****
else
cat > conftest.$ac_ext <<EOF
! #line 5864 "configure"
#include "confdefs.h"

--- 5821,5825 ----
else
cat > conftest.$ac_ext <<EOF
! #line 5824 "configure"
#include "confdefs.h"

***************
*** 5870,5874 ****

EOF
! if { (eval echo configure:5873: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_rshift_extends_sign=yes
--- 5830,5834 ----

EOF
! if { (eval echo configure:5833: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_rshift_extends_sign=yes
***************
*** 5902,5911 ****
EOF
echo $ac_n "checking for socklen_t""... $ac_c" 1>&6
! echo "configure:5905: checking for socklen_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_socklen_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5910 "configure"
#include "confdefs.h"
#include <sys/types.h>
--- 5862,5871 ----
EOF
echo $ac_n "checking for socklen_t""... $ac_c" 1>&6
! echo "configure:5865: checking for socklen_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_socklen_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5870 "configure"
#include "confdefs.h"
#include <sys/types.h>
***************
*** 5936,5940 ****

echo $ac_n "checking for Modules/Setup""... $ac_c" 1>&6
! echo "configure:5939: checking for Modules/Setup" >&5
if test ! -f Modules/Setup ; then
if test ! -d Modules ; then
--- 5896,5900 ----

echo $ac_n "checking for Modules/Setup""... $ac_c" 1>&6
! echo "configure:5899: checking for Modules/Setup" >&5
if test ! -f Modules/Setup ; then
if test ! -d Modules ; then



From python-dev@python.org Fri Nov 10 00:06:42 2000
From: python-dev@python.org (Moshe Zadka)
Date: Thu, 9 Nov 2000 16:06:42 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0216.txt,1.4,1.5
Message-ID: <200011100006.QAA27456@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv27418

Modified Files:
pep-0216.txt
Log Message:
Adding more questions which sprang up in the doc-sig.


Index: pep-0216.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0216.txt,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -r1.4 -r1.5
*** pep-0216.txt 2000/11/07 09:11:04 1.4
--- pep-0216.txt 2000/11/10 00:06:39 1.5
***************
*** 98,101 ****
--- 98,107 ----
Unresolved Issues

+ Is there a way to escape characters in ST? If so, how?
+ (example: * at the beginning of a line without being bullet symbol)
+
+ Is my suggestion above for Python symbols compatible with ST-NG?
+ How hard would it be to extend ST-NG to support it?
+
How do we describe input and output types of functions?




From python-dev@python.org Fri Nov 10 13:17:51 2000
From: python-dev@python.org (Moshe Zadka)
Date: Fri, 10 Nov 2000 05:17:51 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0216.txt,1.5,1.6
Message-ID: <200011101317.FAA10169@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv9880

Modified Files:
pep-0216.txt
Log Message:
Added some examples.
Clarified the fact I'm talking about ST-NG.


Index: pep-0216.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0216.txt,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -r1.5 -r1.6
*** pep-0216.txt 2000/11/10 00:06:39 1.5
--- pep-0216.txt 2000/11/10 13:17:48 1.6
***************
*** 81,85 ****
--- 81,95 ----

a. A tag that means "this is a Python ``something'', guess what"
+
+ Example: In the sentence "The POP3 class", we need to markup "POP3"
+ so. The parser will be able to guess it is a class from the contents
+ of the poplib module, but we need to make it guess.
+
b. Tags that mean "this is a Python class/module/class var/instance var..."
+
+ Example: In the sentence "This can be a regular file or a StringIO object"
+ we need to markup "StringIO" as a Python class (the guesser might guess
+ it to be a module by mistake).
+
c. An easy way to include Python source code/Python interactive sessions
d. Emphasis/bold
***************
*** 88,92 ****
Docstring Basic Structure

! The documentation strings will be in StructuredText
(http://www.zope.org/Members/jim/StructuredTextWiki/StructuredTextNG)
Since StructuredText is not yet strong enough to handle (a) and (b)
--- 98,102 ----
Docstring Basic Structure

! The documentation strings will be in StructuredTextNG
(http://www.zope.org/Members/jim/StructuredTextWiki/StructuredTextNG)
Since StructuredText is not yet strong enough to handle (a) and (b)



From python-dev@python.org Fri Nov 10 19:04:22 2000
From: python-dev@python.org (Tim Peters)
Date: Fri, 10 Nov 2000 11:04:22 -0800
Subject: [Python-checkins] CVS: python/dist/src/Modules arraymodule.c,2.58,2.59
Message-ID: <200011101904.LAA21935@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Modules
In directory slayer.i.sourceforge.net:/tmp/cvs-serv21831/python/dist/src/modules

Modified Files:
arraymodule.c
Log Message:
Fix for SF bug 117402, crashes on str(array) and repr(array). This was an
unfortunate consequence of somebody switching from PyArg_Parse to
PyArg_ParseTuple but without changing the argument from a NULL to a tuple.


Index: arraymodule.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Modules/arraymodule.c,v
retrieving revision 2.58
retrieving revision 2.59
diff -C2 -r2.58 -r2.59
*** arraymodule.c 2000/09/26 05:46:01 2.58
--- arraymodule.c 2000/11/10 19:04:19 2.59
***************
*** 1192,1196 ****
int ok = 0;
int i, len;
- PyObject *t_empty = PyTuple_New(0);
PyObject *v;
len = a->ob_size;
--- 1192,1195 ----
***************
*** 1200,1206 ****
}
if (a->ob_descr->typecode == 'c') {
fprintf(fp, "array('c', ");
v = array_tostring(a, t_empty);
! Py_DECREF(t_empty);;
ok = PyObject_Print(v, fp, 0);
Py_XDECREF(v);
--- 1199,1206 ----
}
if (a->ob_descr->typecode == 'c') {
+ PyObject *t_empty = PyTuple_New(0);
fprintf(fp, "array('c', ");
v = array_tostring(a, t_empty);
! Py_DECREF(t_empty);
ok = PyObject_Print(v, fp, 0);
Py_XDECREF(v);
***************
*** 1232,1238 ****
}
if (a->ob_descr->typecode == 'c') {
sprintf(buf, "array('c', ");
s = PyString_FromString(buf);
! v = array_tostring(a, (PyObject *)NULL);
t = PyObject_Repr(v);
Py_XDECREF(v);
--- 1232,1240 ----
}
if (a->ob_descr->typecode == 'c') {
+ PyObject *t_empty = PyTuple_New(0);
sprintf(buf, "array('c', ");
s = PyString_FromString(buf);
! v = array_tostring(a, t_empty);
! Py_DECREF(t_empty);
t = PyObject_Repr(v);
Py_XDECREF(v);



From python-dev@python.org Sat Nov 11 02:47:13 2000
From: python-dev@python.org (Greg Ward)
Date: Fri, 10 Nov 2000 18:47:13 -0800
Subject: [Python-checkins] CVS: distutils/distutils dist.py,1.41,1.42
Message-ID: <200011110247.SAA07007@slayer.i.sourceforge.net>

Update of /cvsroot/python/distutils/distutils
In directory slayer.i.sourceforge.net:/tmp/cvs-serv6892/distutils

Modified Files:
dist.py
Log Message:
Jack Jansen: added 'get_command_list()' method, and Mac-specific code to
use it to generate a dialog for users to specify the command-line (because
providing a command-line with MacPython is so awkward).


Index: dist.py
==================================================================RCS file: /cvsroot/python/distutils/distutils/dist.py,v
retrieving revision 1.41
retrieving revision 1.42
diff -C2 -r1.41 -r1.42
*** dist.py 2000/10/14 04:06:40 1.41
--- dist.py 2000/11/11 02:47:11 1.42
***************
*** 173,176 ****
--- 173,182 ----
# It's only safe to query 'have_run' for a command class that has
# been instantiated -- a false value will be inserted when the
+ if sys.platform == 'mac':
+ import EasyDialogs
+ cmdlist = self.get_command_list()
+ self.script_args = EasyDialogs.GetArgv(
+ self.global_options + self.display_options, cmdlist)
+
# command object is created, and replaced with a true value when
# the command is successfully run. Thus it's probably best to use
***************
*** 658,661 ****
--- 664,699 ----
# print_commands ()

+ def get_command_list (self):
+ """Get a list of (command, description) tuples.
+ The list is divided into "standard commands" (listed in
+ distutils.command.__all__) and "extra commands" (mentioned in
+ self.cmdclass, but not a standard command). The descriptions come
+ from the command class attribute 'description'.
+ """
+ # Currently this is only used on Mac OS, for the Mac-only GUI
+ # Distutils interface (by Jack Jansen)
+
+ import distutils.command
+ std_commands = distutils.command.__all__
+ is_std = {}
+ for cmd in std_commands:
+ is_std[cmd] = 1
+
+ extra_commands = []
+ for cmd in self.cmdclass.keys():
+ if not is_std.get(cmd):
+ extra_commands.append(cmd)
+
+ rv = []
+ for cmd in (std_commands + extra_commands):
+ klass = self.cmdclass.get(cmd)
+ if not klass:
+ klass = self.get_command_class(cmd)
+ try:
+ description = klass.description
+ except AttributeError:
+ description = "(no description available)"
+ rv.append((cmd, description))
+ return rv

# -- Command class/object methods ----------------------------------



From python-dev@python.org Mon Nov 13 17:11:47 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 09:11:47 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib/dos-8x3 basehttp.py,1.7,NONE bastion.py,1.7,NONE cgihttps.py,1.9,NONE compilea.py,1.5,NONE configpa.py,1.10,NONE cookie.py,1.1,NONE fileinpu.py,1.4,NONE formatte.py,1.9,NONE gopherli.py,1.3,NONE htmlenti.py,1.2,NONE linecach.py,1.2,NONE macurl2p.py,1.6,NONE mimetool.py,1.8,NONE mimetype.py,1.6,NONE mimewrit.py,1.6,NONE multifil.py,1.6,NONE nturl2pa.py,1.5,NONE posixfil.py,1.10,NONE posixpat.py,1.13,NONE py_compi.py,1.10,NONE queue.py,1.8,NONE reconver.py,1.3,NONE regex_sy.py,1.3,NONE regex_te.py,1.1,NONE rlcomple.py,1.7,NONE robotpar.py,1.1,NONE simpleht.py,1.8,NONE socketse.py,1.11,NONE sre_comp.py,1.7,NONE sre_cons.py,1.5,NONE sre_pars.py,1.8,NONE statcach.py,1.2,NONE string_t.py,1.1,NONE stringio.py,1.7,NONE stringol.py,1.2,NONE telnetli.py,1.4,NONE test_arr.py,1.9,NONE test_ate.py,1.1,NONE test_aud.py,1.4,NONE test_aug.py,1.1,NONE test_bin.py,1.5,NONE test_bsd.py,1.3,NONE test_bui.py,1.1,NONE test_cfg.py,1.1,NONE test_cla.py,1.2,NONE tes!
t_cma.py,1.3,NONE test_com.py,1.1,NONE test_con.py,1.1,NONE test_coo.py,1.1,NONE test_cop.py,1.1,NONE test_cpi.py,1.3,NONE test_cry.py,1.2,NONE test_dos.py,1.1,NONE test_err.py,1.3,NONE test_exc.py,1.6,NONE test_ext.py,1.2,NONE test_fcn.py,1.9,NONE test_fil.py,1.1,NONE test_for.py,1.2,NONE test_gdb.py,1.2,NONE test_get.py,1.1,NONE test_gra.py,1.6,NONE test_gzi.py,1.2,NONE test_has.py,1.1,NONE test_ima.py,1.6,NONE test_img.py,1.4,NONE test_imp.py,1.1,NONE test_lar.py,1.1,NONE test_lin.py,1.3,NONE test_lon.py,1.2,NONE test_mat.py,1.6,NONE test_mim.py,1.1,NONE test_min.py,1.4,NONE test_mma.py,1.4,NONE test_ntp.py,1.3,NONE test_opc.py,1.4,NONE test_ope.py,1.5,NONE test_par.py,1.1,NONE test_pic.py,1.2,NONE test_pol.py,1.1,NONE test_pop.py,1.3,NONE test_pos.py,1.1,NONE test_pye.py,1.3,NONE test_reg.py,1.4,NONE test_rfc.py,1.3,NONE test_rgb.py,1.7,NONE test_rot.py,1.3,NONE test_sel.py,1.7,NONE test_sig.py,1.5,NONE test_soc.py,1.7,NONE test_str.py,1.13,NONE test_sun.py,1.3,NONE tes!
t_sup.py,1.4,NONE test_thr.py,1.4,NONE test_tim.py,1.7,NONE te!
st_tok.p
Message-ID: <200011131711.JAA18365@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib/dos-8x3
In directory slayer.i.sourceforge.net:/tmp/cvs-serv18354

Removed Files:
basehttp.py bastion.py cgihttps.py compilea.py configpa.py
cookie.py fileinpu.py formatte.py gopherli.py htmlenti.py
linecach.py macurl2p.py mimetool.py mimetype.py mimewrit.py
multifil.py nturl2pa.py posixfil.py posixpat.py py_compi.py
queue.py reconver.py regex_sy.py regex_te.py rlcomple.py
robotpar.py simpleht.py socketse.py sre_comp.py sre_cons.py
sre_pars.py statcach.py string_t.py stringio.py stringol.py
telnetli.py test_arr.py test_ate.py test_aud.py test_aug.py
test_bin.py test_bsd.py test_bui.py test_cfg.py test_cla.py
test_cma.py test_com.py test_con.py test_coo.py test_cop.py
test_cpi.py test_cry.py test_dos.py test_err.py test_exc.py
test_ext.py test_fcn.py test_fil.py test_for.py test_gdb.py
test_get.py test_gra.py test_gzi.py test_has.py test_ima.py
test_img.py test_imp.py test_lar.py test_lin.py test_lon.py
test_mat.py test_mim.py test_min.py test_mma.py test_ntp.py
test_opc.py test_ope.py test_par.py test_pic.py test_pol.py
test_pop.py test_pos.py test_pye.py test_reg.py test_rfc.py
test_rgb.py test_rot.py test_sel.py test_sig.py test_soc.py
test_str.py test_sun.py test_sup.py test_thr.py test_tim.py
test_tok.py test_typ.py test_uni.py test_unp.py test_url.py
test_use.py test_wav.py test_win.py test_xml.py test_zip.py
test_zli.py threadin.py tokenize.py tracebac.py userdict.py
userlist.py userstri.py webbrows.py
Log Message:
Removing DOS 8x3 support

--- basehttp.py DELETED ---

--- bastion.py DELETED ---

--- cgihttps.py DELETED ---

--- compilea.py DELETED ---

--- configpa.py DELETED ---

--- cookie.py DELETED ---

--- fileinpu.py DELETED ---

--- formatte.py DELETED ---

--- gopherli.py DELETED ---

--- htmlenti.py DELETED ---

--- linecach.py DELETED ---

--- macurl2p.py DELETED ---

--- mimetool.py DELETED ---

--- mimetype.py DELETED ---

--- mimewrit.py DELETED ---

--- multifil.py DELETED ---

--- nturl2pa.py DELETED ---

--- posixfil.py DELETED ---

--- posixpat.py DELETED ---

--- py_compi.py DELETED ---

--- queue.py DELETED ---

--- reconver.py DELETED ---

--- regex_sy.py DELETED ---

--- regex_te.py DELETED ---

--- rlcomple.py DELETED ---

--- robotpar.py DELETED ---

--- simpleht.py DELETED ---

--- socketse.py DELETED ---

--- sre_comp.py DELETED ---

--- sre_cons.py DELETED ---

--- sre_pars.py DELETED ---

--- statcach.py DELETED ---

--- string_t.py DELETED ---

--- stringio.py DELETED ---

--- stringol.py DELETED ---

--- telnetli.py DELETED ---

--- test_arr.py DELETED ---

--- test_ate.py DELETED ---

--- test_aud.py DELETED ---

--- test_aug.py DELETED ---

--- test_bin.py DELETED ---

--- test_bsd.py DELETED ---

--- test_bui.py DELETED ---

--- test_cfg.py DELETED ---

--- test_cla.py DELETED ---

--- test_cma.py DELETED ---

--- test_com.py DELETED ---

--- test_con.py DELETED ---

--- test_coo.py DELETED ---

--- test_cop.py DELETED ---

--- test_cpi.py DELETED ---

--- test_cry.py DELETED ---

--- test_dos.py DELETED ---

--- test_err.py DELETED ---

--- test_exc.py DELETED ---

--- test_ext.py DELETED ---

--- test_fcn.py DELETED ---

--- test_fil.py DELETED ---

--- test_for.py DELETED ---

--- test_gdb.py DELETED ---

--- test_get.py DELETED ---

--- test_gra.py DELETED ---

--- test_gzi.py DELETED ---

--- test_has.py DELETED ---

--- test_ima.py DELETED ---

--- test_img.py DELETED ---

--- test_imp.py DELETED ---

--- test_lar.py DELETED ---

--- test_lin.py DELETED ---

--- test_lon.py DELETED ---

--- test_mat.py DELETED ---

--- test_mim.py DELETED ---

--- test_min.py DELETED ---

--- test_mma.py DELETED ---

--- test_ntp.py DELETED ---

--- test_opc.py DELETED ---

--- test_ope.py DELETED ---

--- test_par.py DELETED ---

--- test_pic.py DELETED ---

--- test_pol.py DELETED ---

--- test_pop.py DELETED ---

--- test_pos.py DELETED ---

--- test_pye.py DELETED ---

--- test_reg.py DELETED ---

--- test_rfc.py DELETED ---

--- test_rgb.py DELETED ---

--- test_rot.py DELETED ---

--- test_sel.py DELETED ---

--- test_sig.py DELETED ---

--- test_soc.py DELETED ---

--- test_str.py DELETED ---

--- test_sun.py DELETED ---

--- test_sup.py DELETED ---

--- test_thr.py DELETED ---

--- test_tim.py DELETED ---

--- test_tok.py DELETED ---

--- test_typ.py DELETED ---

--- test_uni.py DELETED ---

--- test_unp.py DELETED ---

--- test_url.py DELETED ---

--- test_use.py DELETED ---

--- test_wav.py DELETED ---

--- test_win.py DELETED ---

--- test_xml.py DELETED ---

--- test_zip.py DELETED ---

--- test_zli.py DELETED ---

--- threadin.py DELETED ---

--- tokenize.py DELETED ---

--- tracebac.py DELETED ---

--- userdict.py DELETED ---

--- userlist.py DELETED ---

--- userstri.py DELETED ---

--- webbrows.py DELETED ---



From python-dev@python.org Mon Nov 13 17:22:01 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 09:22:01 -0800
Subject: [Python-checkins] CVS: python/dist/src/PC readme.txt,1.22,1.23 make8x3.py,1.3,NONE makesrc.exe,1.1,NONE pyth_w31.def,1.2,NONE python.wpj,1.7,NONE
Message-ID: <200011131722.JAA19441@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/PC
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19404

Modified Files:
readme.txt
Removed Files:
make8x3.py makesrc.exe pyth_w31.def python.wpj
Log Message:
Rip out Win3.1 and DOS support

Index: readme.txt
==================================================================RCS file: /cvsroot/python/python/dist/src/PC/readme.txt,v
retrieving revision 1.22
retrieving revision 1.23
diff -C2 -r1.22 -r1.23
*** readme.txt 2000/06/30 13:00:32 1.22
--- readme.txt 2000/11/13 17:21:58 1.23
***************
*** 2,6 ****
***********************************************************

! *** Note: the project files for MS VC++ 5.0 and 6.0 are now in the
*** PCbuild directory. See the file readme.txt there for build
*** instructions. There is some information below that might
--- 2,6 ----
***********************************************************

! *** Note: the project files for MS VC++ 6.0 are now in the
*** PCbuild directory. See the file readme.txt there for build
*** instructions. There is some information below that might
***************
*** 63,72 ****
skipped tests (these test unavailable optional features).

- src A subdirectory used only for VC++ version 1.5 Python
- source files. See below. The other compilers do not
- use it. They reference the actual distribution
- directories instead.

-
Additional files and subdirectories for 32-bit Windows
=====================================================--- 63,67 ----
***************
*** 86,131 ****


- Microsoft Visual C++ Version 1.5 (16-bit Windows)
- ================================================-
- Since VC++1.5 does not handle long file names, it is necessary
- to run the "makesrc.exe" program in this directory to copy
- Python files from the distribution to the directory "src"
- with shortened names. Included file names are shortened too.
- Do this before you attempt to build Python.
-
- The "makesrc.exe" program is a native NT program, and you must
- have NT, Windows 95 or Win32s to run it. Otherwise you will need
- to copy distribution files to src yourself.
-
- The makefiles are named *.mak and are located in directories
- starting with "vc15_". NOTE: When dependencies are scanned
- VC++ will create dependencies for directories which are not
- used because it fails to evaluate "#define" properly. You
- must manaully edit makefiles (*.mak) to remove references to
- "sys/" and other bad directories.
-
- vc15_lib A static Python library. Create this first because is
- is required for vc15_w31.
-
- vc15_w31 A Windows 3.1x Python QuickWin (console-mode)
- Python including sockets. Requires vc15_lib.
-
-
- Watcom C++ Version 10.6
- ======================-
- The project file for the Watcom compiler is ./python.wpj.
- It will build Watcom versions in the directories wat_*.
-
- wat_dos A 32-bit extended DOS Python (console-mode) using the
- dos4gw DOS extender. Sockets are not included.
-
- wat_os2 A 32-bit OS/2 Python (console-mode).
- Sockets are not included.
-
-
IBM VisualAge C/C++ for OS/2
===========================
See os2vacpp/readme.txt. This platform is supported by Jeff Rush.
--- 81,95 ----


IBM VisualAge C/C++ for OS/2
===========================
See os2vacpp/readme.txt. This platform is supported by Jeff Rush.
+
+
+ Note for Windows 3.x and DOS users
+ =================================+
+ Neither Windows 3.x nor DOS is supported any more. The last Python
+ version that supported these was Python 1.5.2; the support files were
+ present in Python 2.0 but weren't updated, and it is not our intention
+ to support these platforms for Python 2.x.

--- make8x3.py DELETED ---

--- makesrc.exe DELETED ---

--- pyth_w31.def DELETED ---

--- python.wpj DELETED ---



From python-dev@python.org Mon Nov 13 17:22:02 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 09:22:02 -0800
Subject: [Python-checkins] CVS: python/dist/src/PC/vc15_w31 _.c,1.2,NONE pyth_w31.mak,1.6,NONE pyth_w31.pdb,1.1,NONE pyth_w31.vcw,1.2,NONE pyth_w31.wsp,1.2,NONE
Message-ID: <200011131722.JAA19453@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/PC/vc15_w31
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19404/vc15_w31

Removed Files:
_.c pyth_w31.mak pyth_w31.pdb pyth_w31.vcw pyth_w31.wsp
Log Message:
Rip out Win3.1 and DOS support

--- _.c DELETED ---

--- pyth_w31.mak DELETED ---

--- pyth_w31.pdb DELETED ---

--- pyth_w31.vcw DELETED ---

--- pyth_w31.wsp DELETED ---



From python-dev@python.org Mon Nov 13 17:22:02 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 09:22:02 -0800
Subject: [Python-checkins] CVS: python/dist/src/PC/wat_os2 pyth_os2.lk1,1.3,NONE pyth_os2.mk1,1.4,NONE pyth_os2.tgt,1.5,NONE
Message-ID: <200011131722.JAA19463@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/PC/wat_os2
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19404/wat_os2

Removed Files:
pyth_os2.lk1 pyth_os2.mk1 pyth_os2.tgt
Log Message:
Rip out Win3.1 and DOS support

--- pyth_os2.lk1 DELETED ---

--- pyth_os2.mk1 DELETED ---

--- pyth_os2.tgt DELETED ---



From python-dev@python.org Mon Nov 13 17:22:02 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 09:22:02 -0800
Subject: [Python-checkins] CVS: python/dist/src/PC/vc15_lib _.c,1.2,NONE python.mak,1.7,NONE python.vcw,1.2,NONE python.wsp,1.3,NONE
Message-ID: <200011131722.JAA19448@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/PC/vc15_lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19404/vc15_lib

Removed Files:
_.c python.mak python.vcw python.wsp
Log Message:
Rip out Win3.1 and DOS support

--- _.c DELETED ---

--- python.mak DELETED ---

--- python.vcw DELETED ---

--- python.wsp DELETED ---



From python-dev@python.org Mon Nov 13 17:22:02 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 09:22:02 -0800
Subject: [Python-checkins] CVS: python/dist/src/PC/wat_dos pyth_dos.lk1,1.3,NONE pyth_dos.mk1,1.4,NONE pyth_dos.tgt,1.5,NONE
Message-ID: <200011131722.JAA19457@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/PC/wat_dos
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19404/wat_dos

Removed Files:
pyth_dos.lk1 pyth_dos.mk1 pyth_dos.tgt
Log Message:
Rip out Win3.1 and DOS support

--- pyth_dos.lk1 DELETED ---

--- pyth_dos.mk1 DELETED ---

--- pyth_dos.tgt DELETED ---



From python-dev@python.org Mon Nov 13 17:23:22 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 09:23:22 -0800
Subject: [Python-checkins] CVS: python/dist/src/PC/src readme.txt,1.1,NONE
Message-ID: <200011131723.JAA19606@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/PC/src
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19595

Removed Files:
readme.txt
Log Message:
Rip out Win3.1 and DOS support

--- readme.txt DELETED ---



From python-dev@python.org Mon Nov 13 17:24:15 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 09:24:15 -0800
Subject: [Python-checkins] CVS: python/dist/src/PC/utils makesrc.c,1.2,NONE makesrc.lk1,1.2,NONE makesrc.mk1,1.2,NONE makesrc.tgt,1.2,NONE utils.mk,1.2,NONE utils.wpj,1.2,NONE
Message-ID: <200011131724.JAA19715@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/PC/utils
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19707

Removed Files:
makesrc.c makesrc.lk1 makesrc.mk1 makesrc.tgt utils.mk
utils.wpj
Log Message:
Rip out Win3.1 and DOS support

--- makesrc.c DELETED ---

--- makesrc.lk1 DELETED ---

--- makesrc.mk1 DELETED ---

--- makesrc.tgt DELETED ---

--- utils.mk DELETED ---

--- utils.wpj DELETED ---



From python-dev@python.org Mon Nov 13 17:26:35 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 09:26:35 -0800
Subject: [Python-checkins] CVS: python/dist/src/Python import.c,2.153,2.154
Message-ID: <200011131726.JAA19973@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Python
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19962

Modified Files:
import.c
Log Message:
Rip out DOS-8x3 support.


Index: import.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Python/import.c,v
retrieving revision 2.153
retrieving revision 2.154
diff -C2 -r2.153 -r2.154
*** import.c 2000/10/03 16:02:05 2.153
--- import.c 2000/11/13 17:26:32 2.154
***************
*** 958,978 ****
)
buf[len++] = SEP;
! #ifdef IMPORT_8x3_NAMES
! /* see if we are searching in directory dos-8x3 */
! if (len > 7 && !strncmp(buf + len - 8, "dos-8x3", 7)){
! int j;
! char ch; /* limit name to 8 lower-case characters */
! for (j = 0; (ch = name[j]) && j < 8; j++)
! if (isupper(ch))
! buf[len++] = tolower(ch);
! else
! buf[len++] = ch;
! }
! else /* Not in dos-8x3, use the full name */
! #endif
! {
! strcpy(buf+len, name);
! len += namelen;
! }
#ifdef HAVE_STAT
if (stat(buf, &statbuf) == 0) {
--- 958,963 ----
)
buf[len++] = SEP;
! strcpy(buf+len, name);
! len += namelen;
#ifdef HAVE_STAT
if (stat(buf, &statbuf) == 0) {



From python-dev@python.org Mon Nov 13 17:29:34 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 09:29:34 -0800
Subject: [Python-checkins] CVS: python/dist/src/PC config.h,1.46,1.47
Message-ID: <200011131729.JAA20270@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/PC
In directory slayer.i.sourceforge.net:/tmp/cvs-serv20261

Modified Files:
config.h
Log Message:
Rip out DOS and Win16 support.


Index: config.h
==================================================================RCS file: /cvsroot/python/python/dist/src/PC/config.h,v
retrieving revision 1.46
retrieving revision 1.47
diff -C2 -r1.46 -r1.47
*** config.h 2000/08/31 19:23:01 1.46
--- config.h 2000/11/13 17:29:30 1.47
***************
*** 129,223 ****
#endif /* _MSC_VER && > 850 */

- #if defined(_MSC_VER) && _MSC_VER <= 850 /* presume this implies Win16 */
- /* Start of defines for 16-bit Windows using VC++ 1.5 */
- #define COMPILER "[MSC 16-bit]"
- #define PYTHONPATH ".;.\\lib;.\\lib\\plat-win;.\\lib\\dos-8x3"
- #define IMPORT_8x3_NAMES
- typedef int pid_t;
- #define WORD_BIT 16
- #define SIZEOF_INT 2
- #define SIZEOF_LONG 4
- #define SIZEOF_VOID_P 4
- #pragma warning(disable:4113)
- #define memcpy memmove /* memcpy dangerous pointer wrap in Win 3.1 */
- #define hypot _hypot
- #define SIGINT 2
- #include <stdio.h>
- /* Windows 3.1 will not tolerate any console io in a dll */
- #ifdef _USRDLL
- #include <time.h>
- #ifdef __cplusplus
- extern "C" {
- #endif
- #define stdin ((FILE *)0)
- #define stdout ((FILE *)1)
- #define stderr ((FILE *)2)
- #define fflush Py_fflush
- int Py_fflush(FILE *);
- #define fgets Py_fgets
- char *Py_fgets(char *, int, FILE *);
- #define fileno Py_fileno
- int Py_fileno(FILE *);
- #define fprintf Py_fprintf
- int Py_fprintf(FILE *, const char *, ...);
- #define printf Py_printf
- int Py_printf(const char *, ...);
- #define sscanf Py_sscanf
- int Py_sscanf(const char *, const char *, ...);
- clock_t clock();
- void _exit(int);
- void exit(int);
- int sscanf(const char *, const char *, ...);
- #ifdef __cplusplus
- }
- #endif
- #endif /* _USRDLL */
- #ifndef NETSCAPE_PI
- /* use sockets, but not in a Netscape dll */
- #define USE_SOCKET
- #endif
- #endif /* MS_WIN16 */
-
- /* The Watcom compiler defines __WATCOMC__ */
- #ifdef __WATCOMC__
- #define COMPILER "[Watcom]"
- #define PYTHONPATH ".;.\\lib;.\\lib\\plat-win;.\\lib\\dos-8x3"
- #define IMPORT_8x3_NAMES
- #include <ctype.h>
- #include <direct.h>
- typedef int mode_t;
- typedef int uid_t;
- typedef int gid_t;
- typedef int pid_t;
- #if defined(__NT__)
- #define NT /* NT is obsolete - please use MS_WIN32 instead */
- #define MS_WIN32
- #define MS_WINDOWS
- #define NT_THREADS
- #define USE_SOCKET
- #define WITH_THREAD
- #elif defined(__WINDOWS__)
- #define MS_WIN16
- #define MS_WINDOWS
- #endif
- #ifdef M_I386
- #define WORD_BIT 32
- #define SIZEOF_INT 4
- #define SIZEOF_LONG 4
- #define SIZEOF_VOID_P 4
- #else
- #define WORD_BIT 16
- #define SIZEOF_INT 2
- #define SIZEOF_LONG 4
- #define SIZEOF_VOID_P 4
- #endif
- #define VA_LIST_IS_ARRAY
- #define HAVE_CLOCK
- #define HAVE_STRFTIME
- #ifdef USE_DL_EXPORT
- #define DL_IMPORT(RTYPE) RTYPE __export
- #endif
- #endif /* __WATCOMC__ */
-
/* The Borland compiler defines __BORLANDC__ */
/* XXX These defines are likely incomplete, but should be easy to fix. */
--- 129,132 ----
***************
*** 269,280 ****

#else /* !_WIN32 */
! /* XXX These defines are likely incomplete, but should be easy to fix. */
!
! #define PYTHONPATH ".;.\\lib;.\\lib\\plat-win;.\\lib\\dos-8x3"
! #define IMPORT_8x3_NAMES
! #ifdef USE_DL_IMPORT
! #define DL_IMPORT(RTYPE) RTYPE __import
! #endif
!
#endif /* !_WIN32 */

--- 178,182 ----

#else /* !_WIN32 */
! #error "Only Win32 and later are supported"
#endif /* !_WIN32 */

***************
*** 416,423 ****
# define SIZEOF_HKEY 4
# endif
- #elif defined(MS_WIN16)
- # define PLATFORM "win16"
- #else
- # define PLATFORM "dos"
#endif

--- 318,321 ----



From python-dev@python.org Mon Nov 13 19:45:49 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 11:45:49 -0800
Subject: [Python-checkins] CVS: python/dist/src/Python thread_cthread.h,2.13,2.14
Message-ID: <200011131945.LAA04294@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Python
In directory slayer.i.sourceforge.net:/tmp/cvs-serv4274

Modified Files:
thread_cthread.h
Log Message:
Fix syntax error. Submitted by Bill Bumgarner. Apparently this is
still in use, for Apple Mac OSX.


Index: thread_cthread.h
==================================================================RCS file: /cvsroot/python/python/dist/src/Python/thread_cthread.h,v
retrieving revision 2.13
retrieving revision 2.14
diff -C2 -r2.13 -r2.14
*** thread_cthread.h 2000/09/01 23:29:28 2.13
--- thread_cthread.h 2000/11/13 19:45:45 2.14
***************
*** 16,20 ****
*/
int
! PyThread_start_new_thread(func, void (*func)(void *), void *arg)
{
int success = 0; /* init not needed when SOLARIS_THREADS and */
--- 16,20 ----
*/
int
! PyThread_start_new_thread(void (*func)(void *), void *arg)
{
int success = 0; /* init not needed when SOLARIS_THREADS and */



From python-dev@python.org Mon Nov 13 19:48:25 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 11:48:25 -0800
Subject: [Python-checkins] CVS: python/dist/src/Objects fileobject.c,2.91,2.92
Message-ID: <200011131948.LAA04697@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Objects
In directory slayer.i.sourceforge.net:/tmp/cvs-serv4689

Modified Files:
fileobject.c
Log Message:
Added _HAVE_BSDI and __APPLE__ to the list of platforms that require a
hack for TELL64()... Sounds like there's something else going on
really. Does anybody have a clue I can buy?


Index: fileobject.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Objects/fileobject.c,v
retrieving revision 2.91
retrieving revision 2.92
diff -C2 -r2.91 -r2.92
*** fileobject.c 2000/10/24 19:57:45 2.91
--- fileobject.c 2000/11/13 19:48:22 2.92
***************
*** 59,63 ****
#if defined(MS_WIN64)
#define TELL64 _telli64
! #elif defined(__NetBSD__) || defined(__OpenBSD__)
/* NOTE: this is only used on older
NetBSD prior to f*o() funcions */
--- 59,63 ----
#if defined(MS_WIN64)
#define TELL64 _telli64
! #elif defined(__NetBSD__) || defined(__OpenBSD__) || defined(_HAVE_BSDI) || defined(__APPLE__)
/* NOTE: this is only used on older
NetBSD prior to f*o() funcions */



From python-dev@python.org Mon Nov 13 20:21:11 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 12:21:11 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0042.txt,1.43,1.44
Message-ID: <200011132021.MAA09003@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv8993

Modified Files:
pep-0042.txt
Log Message:
Addtwo more wishes: kill thread, Python/python name conflict.


Index: pep-0042.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0042.txt,v
retrieving revision 1.43
retrieving revision 1.44
diff -C2 -r1.43 -r1.44
*** pep-0042.txt 2000/11/06 18:49:06 1.43
--- pep-0042.txt 2000/11/13 20:21:08 1.44
***************
*** 216,219 ****
--- 216,224 ----
<linuxqna@chollian.net>.]

+ - Killing a thread from another thread. Or maybe sending a
+ signal. Or maybe raising an asynchronous exception.
+
+ http://sourceforge.net/bugs/?funcÞtailbug&bug_id1115&group_idT70
+
Tools

***************
*** 253,256 ****
--- 258,270 ----

http://www.python.org/pipermail/python-dev/2000-October/016620.html
+
+ - There's a name conflict on case insensitive filesystems (in
+ particular Mac OSX) between the directory "Python" and the key
+ build target "python". That's currently solved by abusing the
+ --with-suffix option, but that's not ideal (since that also
+ causes the binary to be *installed* as python.exe). What should
+ be the solution?
+
+ http://sourceforge.net/bugs/?funcÞtailbug&bug_id2215&group_idT70





From python-dev@python.org Mon Nov 13 20:29:23 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 12:29:23 -0800
Subject: [Python-checkins] CVS: python/dist/src/Modules newmodule.c,2.28,2.29
Message-ID: <200011132029.MAA09988@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Modules
In directory slayer.i.sourceforge.net:/tmp/cvs-serv9978

Modified Files:
newmodule.c
Log Message:
Allow new.function() called with explicit 3rd arg of None, as
documented, and as is reasonable (since it is optional, but there's
another argument following it that may require you to specify a
value). This solves SF bug 121887.


Index: newmodule.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Modules/newmodule.c,v
retrieving revision 2.28
retrieving revision 2.29
diff -C2 -r2.28 -r2.29
*** newmodule.c 2000/10/10 22:07:18 2.28
--- newmodule.c 2000/11/13 20:29:20 2.29
***************
*** 71,75 ****
PyFunctionObject* newfunc;

! if (!PyArg_ParseTuple(args, "O!O!|SO!:function",
&PyCode_Type, &code,
&PyDict_Type, &globals,
--- 71,75 ----
PyFunctionObject* newfunc;

! if (!PyArg_ParseTuple(args, "O!O!|OO!:function",
&PyCode_Type, &code,
&PyDict_Type, &globals,
***************
*** 77,80 ****
--- 77,85 ----
&PyTuple_Type, &defaults))
return NULL;
+ if (name != Py_None && !PyString_Check(name)) {
+ PyErr_SetString(PyExc_TypeError,
+ "arg 3 (name) must be None or string");
+ return NULL;
+ }

newfunc = (PyFunctionObject *)PyFunction_New(code, globals);



From python-dev@python.org Mon Nov 13 20:31:00 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 12:31:00 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib webbrowser.py,1.4,1.5
Message-ID: <200011132031.MAA10222@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv10204

Modified Files:
webbrowser.py
Log Message:
Typo for Mac code, fixing SF bug 12195.


Index: webbrowser.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/webbrowser.py,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -r1.4 -r1.5
*** webbrowser.py 2000/10/02 03:40:51 1.4
--- webbrowser.py 2000/11/13 20:30:57 1.5
***************
*** 216,220 ****
class InternetConfig:
def open(self, url, new=0):
! ic.launcurl(url)

def open_new(self, url):
--- 216,220 ----
class InternetConfig:
def open(self, url, new=0):
! ic.launchurl(url)

def open_new(self, url):



From python-dev@python.org Mon Nov 13 21:16:26 2000
From: python-dev@python.org (Trent Mick)
Date: Mon, 13 Nov 2000 13:16:26 -0800
Subject: [Python-checkins] CVS: python/dist/src/Objects fileobject.c,2.91,2.92
In-Reply-To: <200011131948.LAA04697@slayer.i.sourceforge.net>; from gvanrossum@users.sourceforge.net on Mon, Nov 13, 2000 at 11:48:25AM -0800
References: <200011131948.LAA04697@slayer.i.sourceforge.net>
Message-ID: <20001113131626.B4553@ActiveState.com>
On Mon, Nov 13, 2000 at 11:48:25AM -0800, Guido van Rossum wrote:
Update of /cvsroot/python/python/dist/src/Objects
In directory slayer.i.sourceforge.net:/tmp/cvs-serv4689

Modified Files:
fileobject.c
Log Message:
Added _HAVE_BSDI and __APPLE__ to the list of platforms that require a
hack for TELL64()... Sounds like there's something else going on
really. Does anybody have a clue I can buy?
Yes, there is. For all of these platforms HAVE_LARGEFILE_SUPPORT is defined
when it should not really be. Essentially, these platforms lie when they say
they support largefiles, at least according to the configure test for
HAVE_LARGEFILE_SUPPORT>

Trent


--
Trent Mick
TrentM@ActiveState.com


From python-dev@python.org Tue Nov 14 20:27:57 2000
From: python-dev@python.org (Tim Peters)
Date: Tue, 14 Nov 2000 12:27:57 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0042.txt,1.44,1.45
Message-ID: <200011142027.MAA26670@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv26632/python/nondist/peps

Modified Files:
pep-0042.txt
Log Message:
Added SF Feature Request 121963: threads and IDLE don't mix.


Index: pep-0042.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0042.txt,v
retrieving revision 1.44
retrieving revision 1.45
diff -C2 -r1.44 -r1.45
*** pep-0042.txt 2000/11/13 20:21:08 1.44
--- pep-0042.txt 2000/11/14 20:27:54 1.45
***************
*** 69,73 ****
be raised or removed. Removal would be hard because the
current compiler can overflow the C stack if the nesting is too
! deep.

http://sourceforge.net/bugs/?funcÞtailbug&bug_id5555&group_idT70
--- 69,73 ----
be raised or removed. Removal would be hard because the
current compiler can overflow the C stack if the nesting is too
! deep.

http://sourceforge.net/bugs/?funcÞtailbug&bug_id5555&group_idT70
***************
*** 184,188 ****

- urllib should support proxy definitions that contain just the
! host and port

http://sourceforge.net/bugs/?funcÞtailbug&bug_id0849&group_idT70
--- 184,188 ----

- urllib should support proxy definitions that contain just the
! host and port

http://sourceforge.net/bugs/?funcÞtailbug&bug_id0849&group_idT70
***************
*** 237,240 ****
--- 237,244 ----

http://sourceforge.net/bugs/?funcÞtailbug&bug_id0659&group_idT70
+
+ - IDLE has deep problems running threaded programs. Re-architect.
+
+ http://sourceforge.net/bugs/?funcÞtailbug&bug_id1963&group_idT70





From python-dev@python.org Tue Nov 14 20:44:57 2000
From: python-dev@python.org (Tim Peters)
Date: Tue, 14 Nov 2000 12:44:57 -0800
Subject: [Python-checkins] CVS: python/dist/src/Python compile.c,2.142,2.143 marshal.c,1.57,1.58
Message-ID: <200011142044.MAA27961@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Python
In directory slayer.i.sourceforge.net:/tmp/cvs-serv27853/python/dist/src/Python

Modified Files:
compile.c marshal.c
Log Message:
SF bug 119622: compile errors due to redundant atof decls. I don't understand
the bug report (for details, look at it), but agree there's no need for Python
to declare atof itself: we #include stdlib.h, and ANSI C sez atof is declared
there already.


Index: compile.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Python/compile.c,v
retrieving revision 2.142
retrieving revision 2.143
diff -C2 -r2.142 -r2.143
*** compile.c 2000/09/26 05:46:01 2.142
--- compile.c 2000/11/14 20:44:53 2.143
***************
*** 768,772 ****
parsenumber(struct compiling *co, char *s)
{
- extern double atof(const char *);
char *end;
long x;
--- 768,771 ----

Index: marshal.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Python/marshal.c,v
retrieving revision 1.57
retrieving revision 1.58
diff -C2 -r1.57 -r1.58
*** marshal.c 2000/09/19 08:54:13 1.57
--- marshal.c 2000/11/14 20:44:53 1.58
***************
*** 404,408 ****
case TYPE_FLOAT:
{
- extern double atof(const char *);
char buf[256];
double dx;
--- 404,407 ----
***************
*** 423,427 ****
case TYPE_COMPLEX:
{
- extern double atof(const char *);
char buf[256];
Py_complex c;
--- 422,425 ----



From python-dev@python.org Tue Nov 14 21:36:09 2000
From: python-dev@python.org (Tim Peters)
Date: Tue, 14 Nov 2000 13:36:09 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib/test test_array.py,1.10,1.11
Message-ID: <200011142136.NAA01848@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib/test
In directory slayer.i.sourceforge.net:/tmp/cvs-serv1768/python/dist/src/Lib/test

Modified Files:
test_array.py
Log Message:
Verify that str(a) and repr(a) don't blow up (part of SF patch 102068).


Index: test_array.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/test/test_array.py,v
retrieving revision 1.10
retrieving revision 1.11
diff -C2 -r1.10 -r1.11
*** test_array.py 2000/10/23 17:22:07 1.10
--- test_array.py 2000/11/14 21:36:07 1.11
***************
*** 85,90 ****
--- 85,95 ----
a.tofile(f)
f.close()
+
+ # This block is just to verify that the operations don't blow up.
a.tolist()
a.tostring()
+ repr(a)
+ str(a)
+
if verbose:
print 'array of %s converted to a list: ' % a.typecode, a.tolist()



From python-dev@python.org Tue Nov 14 21:43:04 2000
From: python-dev@python.org (Tim Peters)
Date: Tue, 14 Nov 2000 13:43:04 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib librotor.tex,1.16,1.17
Message-ID: <200011142143.NAA02618@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv2579/python/dist/src/doc/lib

Modified Files:
librotor.tex
Log Message:
Fix for SF bug 122176: Error in rotor module documentation.


Index: librotor.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/librotor.tex,v
retrieving revision 1.16
retrieving revision 1.17
diff -C2 -r1.16 -r1.17
*** librotor.tex 2000/10/10 17:03:45 1.16
--- librotor.tex 2000/11/14 21:43:01 1.17
***************
*** 55,59 ****
\begin{methoddesc}[rotor]{decrypt}{ciphertext}
Reset the rotor object to its initial state and decrypt \var{ciphertext},
! returning a string containing the ciphertext. The plaintext string will
always be the same length as the ciphertext.
\end{methoddesc}
--- 55,59 ----
\begin{methoddesc}[rotor]{decrypt}{ciphertext}
Reset the rotor object to its initial state and decrypt \var{ciphertext},
! returning a string containing the plaintext. The plaintext string will
always be the same length as the ciphertext.
\end{methoddesc}
***************
*** 61,65 ****
\begin{methoddesc}[rotor]{decryptmore}{ciphertext}
Decrypt \var{ciphertext} without resetting the rotor object, and return a
! string containing the ciphertext.
\end{methoddesc}

--- 61,65 ----
\begin{methoddesc}[rotor]{decryptmore}{ciphertext}
Decrypt \var{ciphertext} without resetting the rotor object, and return a
! string containing the plaintext.
\end{methoddesc}




From python-dev@python.org Thu Nov 16 21:25:54 2000
From: python-dev@python.org (Guido van Rossum)
Date: Thu, 16 Nov 2000 13:25:54 -0800
Subject: [Python-checkins] CVS: python/dist/src/Demo/scripts queens.py,NONE,1.1
Message-ID: <200011162125.NAA19499@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Demo/scripts
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19493

Added Files:
queens.py
Log Message:
A solution to the classic N queens problem.


--- NEW FILE ---
#! /usr/bin/env python

"""N queens problem.

The (well-known) problem is due to Niklaus Wirth.

This solution is inspired by Dijkstra (Structured Programming). It is
a classic recursive backtracking approach.

"""

N = 8 # Default; command line overrides

class Queens:

def __init__(self, n=N):
self.n = n
self.reset()

def reset(self):
n = self.n
self.y = [None]*n # Where is the queen in column x
self.row = [0]*n # Is row[y] safe?
self.up = [0] * (2*n-1) # Is upward diagonal[x-y] safe?
self.down = [0] * (2*n-1) # Is downward diagonal[x+y] safe?
self.nfound = 0 # Instrumentation

def solve(self, x=0): # Recursive solver
for y in range(self.n):
if self.safe(x, y):
self.place(x, y)
if x+1 == self.n:
self.display()
else:
self.solve(x+1)
self.remove(x, y)

def safe(self, x, y):
return not self.row[y] and not self.up[x-y] and not self.down[x+y]

def place(self, x, y):
self.y[x] = y
self.row[y] = 1
self.up[x-y] = 1
self.down[x+y] = 1

def remove(self, x, y):
self.y[x] = None
self.row[y] = 0
self.up[x-y] = 0
self.down[x+y] = 0

silent = 0 # If set, count solutions only

def display(self):
self.nfound = self.nfound + 1
if self.silent:
return
print '+-' + '--'*self.n + '+'
for y in range(self.n-1, -1, -1):
print '|',
for x in range(self.n):
if self.y[x] == y:
print "Q",
else:
print ".",
print '|'
print '+-' + '--'*self.n + '+'

def main():
import sys
silent = 0
n = N
if sys.argv[1:2] == ['-n']:
silent = 1
del sys.argv[1]
if sys.argv[1:]:
n = int(sys.argv[1])
q = Queens(n)
q.silent = silent
q.solve()
print "Found", q.nfound, "solutions."

if __name__ == "__main__":
main()



From python-dev@python.org Fri Nov 17 18:04:09 2000
From: python-dev@python.org (Fred L. Drake)
Date: Fri, 17 Nov 2000 10:04:09 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib libhttplib.tex,1.21,1.22
Message-ID: <200011171804.KAA22174@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv22137/lib

Modified Files:
libhttplib.tex
Log Message:

Fixed typos and bug in the second example, reported by Scott Schram
<schram@users.sourceforge.net>.

This closes bug #122236.


Index: libhttplib.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/libhttplib.tex,v
retrieving revision 1.21
retrieving revision 1.22
diff -C2 -r1.21 -r1.22
*** libhttplib.tex 2000/06/28 22:09:20 1.21
--- libhttplib.tex 2000/11/17 18:04:03 1.22
***************
*** 138,148 ****
h = httplib.HTTP("www.musi-cal.com:80")
h.putrequest("POST", "/cgi-bin/query")
h.putheader("Content-length", "%d" % len(params))
h.putheader('Accept', 'text/plain')
h.putheader('Host', 'www.musi-cal.com')
h.endheaders()
! >>> h.send(paramstring)
reply, msg, hdrs = h.getreply()
! >>> print errcode # should be 200
data = h.getfile().read() # get the raw HTML
\end{verbatim}
--- 138,149 ----
h = httplib.HTTP("www.musi-cal.com:80")
h.putrequest("POST", "/cgi-bin/query")
+ >>> h.putheader("Content-type", "application/x-www-form-urlencoded")
h.putheader("Content-length", "%d" % len(params))
h.putheader('Accept', 'text/plain')
h.putheader('Host', 'www.musi-cal.com')
h.endheaders()
! >>> h.send(params)
reply, msg, hdrs = h.getreply()
! >>> print reply # should be 200
data = h.getfile().read() # get the raw HTML
\end{verbatim}



From python-dev@python.org Fri Nov 17 18:20:56 2000
From: python-dev@python.org (Fred L. Drake)
Date: Fri, 17 Nov 2000 10:20:56 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/ext ext.tex,1.88,1.89
Message-ID: <200011171820.KAA24075@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/ext
In directory slayer.i.sourceforge.net:/tmp/cvs-serv23994/ext

Modified Files:
ext.tex
Log Message:

Corrected a number of typos reported by Gilles Civario
<gcivario@users.sourceforge.net>.

This closes bug #122562.


Index: ext.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/ext/ext.tex,v
retrieving revision 1.88
retrieving revision 1.89
diff -C2 -r1.88 -r1.89
*** ext.tex 2000/11/02 21:49:17 1.88
--- ext.tex 2000/11/17 18:20:33 1.89
***************
*** 736,740 ****
This variant on \samp{s\#} is used for encoding Unicode and objects
convertible to Unicode into a character buffer. It reads one C
! variable and stores into two C variables, the first one a pointer to
an encoding name string (\var{encoding}), the second a pointer to a
pointer to a character buffer (\var{**buffer}, the buffer used for
--- 736,740 ----
This variant on \samp{s\#} is used for encoding Unicode and objects
convertible to Unicode into a character buffer. It reads one C
! variable and stores into three C variables, the first one a pointer to
an encoding name string (\var{encoding}), the second a pointer to a
pointer to a character buffer (\var{**buffer}, the buffer used for
***************
*** 887,892 ****

\item[\samp{;}]
! The list of format units ends here; the string after the colon is used
! as the error message \emph{instead} of the default error message.
Clearly, \samp{:} and \samp{;} mutually exclude each other.

--- 887,892 ----

\item[\samp{;}]
! The list of format units ends here; the string after the semicolon is
! used as the error message \emph{instead} of the default error message.
Clearly, \samp{:} and \samp{;} mutually exclude each other.

***************
*** 1101,1113 ****
Unicode object. If the Unicode buffer pointer is \NULL, the length
is ignored and \code{None} is returned.
-
- \item[\samp{u} (Unicode string) {[Py_UNICODE *]}]
- Convert a null-terminated buffer of Unicode (UCS-2) data to a Python Unicode
- object. If the Unicode buffer pointer is \NULL{}, \code{None} is returned.
-
- \item[\samp{u\#} (Unicode string) {[Py_UNICODE *, int]}]
- Convert a Unicode (UCS-2) data buffer and its length to a Python Unicode
- object. If the Unicode buffer pointer is \NULL{}, the length is ignored and
- \code{None} is returned.

\item[\samp{i} (integer) {[int]}]
--- 1101,1104 ----



From python-dev@python.org Fri Nov 17 19:05:14 2000
From: python-dev@python.org (Fred L. Drake)
Date: Fri, 17 Nov 2000 11:05:14 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/ref ref2.tex,1.19,1.20
Message-ID: <200011171905.LAA31784@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/ref
In directory slayer.i.sourceforge.net:/tmp/cvs-serv31740/ref

Modified Files:
ref2.tex
Log Message:

Note that readframes() returns data in linear format, even if the original
is encoded in u-LAW format. Based on suggestion from Anthony Baxter
<anthony_baxter@users.sourceforge.net>.

This closes bug #122273.


Index: ref2.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/ref/ref2.tex,v
retrieving revision 1.19
retrieving revision 1.20
diff -C2 -r1.19 -r1.20
*** ref2.tex 2000/08/24 20:06:04 1.19
--- ref2.tex 2000/11/17 19:05:11 1.20
***************
*** 396,399 ****
--- 396,405 ----
(even mixing raw strings and triple quoted strings).

+
+ \subsection{Unicode literals \label{unicode}}
+
+ XXX explain more here...
+
+
\subsection{Numeric literals\label{numbers}}




From python-dev@python.org Fri Nov 17 19:05:14 2000
From: python-dev@python.org (Fred L. Drake)
Date: Fri, 17 Nov 2000 11:05:14 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib liblocale.tex,1.18,1.19 libsunau.tex,1.3,1.4
Message-ID: <200011171905.LAA31780@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv31740/lib

Modified Files:
liblocale.tex libsunau.tex
Log Message:

Note that readframes() returns data in linear format, even if the original
is encoded in u-LAW format. Based on suggestion from Anthony Baxter
<anthony_baxter@users.sourceforge.net>.

This closes bug #122273.


Index: liblocale.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/liblocale.tex,v
retrieving revision 1.18
retrieving revision 1.19
diff -C2 -r1.18 -r1.19
*** liblocale.tex 2000/10/25 20:59:52 1.18
--- liblocale.tex 2000/11/17 19:05:11 1.19
***************
*** 62,65 ****
--- 62,99 ----
This dictionary has the following strings as keys:

+ \begin{tableiii}{l|l|l}{code}{Key}{Category}{Meaning}
+ \lineiii{'decimal_point'}{\constant{LC_NUMERIC}}
+ {Decimal point character.}
+ \lineiii{'grouping'}{\constant{LC_NUMERIC}}
+ {Sequence of numbers specifying which relative positions
+ the \code{'thousands_sep'} is expected. If the sequence is
+ terminated with \constant{CHAR_MAX}, no further grouping
+ is performed. If the sequence terminates with a \code{0},
+ the last group size is repeatedly used.}
+ \lineiii{'thousands_sep'}{\constant{LC_NUMERIC}}
+ {Character used between groups.}\hline
+ \lineiii{'int_curr_symbol'}{\constant{LC_MONETARY}}
+ {International currency symbol.}
+ \lineiii{'currency_symbol'}{\constant{LC_MONETARY}}
+ {Local currency symbol.}
+ \lineiii{'mon_decimal_point'}{\constant{LC_MONETARY}}
+ {Decimal point used for monetary values.}
+ \lineiii{'mon_thousands_sep'}{\constant{LC_MONETARY}}
+ {Group separator used for monetary values.}
+ \lineiii{'mon_grouping'}{\constant{LC_MONETARY}}
+ {Equivalent to \code{'grouping'}, used for monetary
+ values.}
+ \lineiii{'positive_sign'}{\constant{LC_MONETARY}}
+ {Symbol used to annotate a positive monetary value.}
+ \lineiii{'negative_sign'}{\constant{LC_MONETARY}}
+ {Symbol used to annotate a nnegative monetary value.}
+ \lineiii{'frac_digits'}{\constant{LC_MONETARY}}
+ {Number of fractional digits used in local formatting
+ of monetary values.}
+ \lineiii{'int_frac_digits'}{\constant{LC_MONETARY}}
+ {Number of fractional digits used in international
+ formatting of monetary values.}
+ \end{tableiii}
+
\begin{itemize}
\item

Index: libsunau.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/libsunau.tex,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** libsunau.tex 2000/10/06 21:07:14 1.3
--- libsunau.tex 2000/11/17 19:05:11 1.4
***************
*** 128,132 ****

\begin{methoddesc}[AU_read]{readframes}{n}
! Reads and returns at most \var{n} frames of audio, as a string of bytes.
\end{methoddesc}

--- 128,134 ----

\begin{methoddesc}[AU_read]{readframes}{n}
! Reads and returns at most \var{n} frames of audio, as a string of
! bytes. The data will be returned in linear format. If the original
! data is in u-LAW format, it will be converted.
\end{methoddesc}




From python-dev@python.org Fri Nov 17 19:05:14 2000
From: python-dev@python.org (Fred L. Drake)
Date: Fri, 17 Nov 2000 11:05:14 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc ACKS,1.8,1.9
Message-ID: <200011171905.LAA31775@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc
In directory slayer.i.sourceforge.net:/tmp/cvs-serv31740

Modified Files:
ACKS
Log Message:

Note that readframes() returns data in linear format, even if the original
is encoded in u-LAW format. Based on suggestion from Anthony Baxter
<anthony_baxter@users.sourceforge.net>.

This closes bug #122273.


Index: ACKS
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/ACKS,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -r1.8 -r1.9
*** ACKS 2000/11/07 16:09:53 1.8
--- ACKS 2000/11/17 19:05:10 1.9
***************
*** 23,26 ****
--- 23,27 ----
Chris Barker
Don Bashford
+ Anthony Baxter
Bennett Benson
Jonathan Black
***************
*** 31,34 ****
--- 32,36 ----
Lorenzo M. Catucci
Mauro Cicognini
+ Gilles Civario
Steve Clift
Andrew Dalke
***************
*** 127,130 ****
--- 129,133 ----
Hugh Sasse
Bob Savage
+ Scott Schram
Neil Schemenauer
Barry Scott



From python-dev@python.org Fri Nov 17 19:05:14 2000
From: python-dev@python.org (Fred L. Drake)
Date: Fri, 17 Nov 2000 11:05:14 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/texinputs boilerplate.tex,1.50,1.51 howto.cls,1.11,1.12
Message-ID: <200011171905.LAA31791@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/texinputs
In directory slayer.i.sourceforge.net:/tmp/cvs-serv31740/texinputs

Modified Files:
boilerplate.tex howto.cls
Log Message:

Note that readframes() returns data in linear format, even if the original
is encoded in u-LAW format. Based on suggestion from Anthony Baxter
<anthony_baxter@users.sourceforge.net>.

This closes bug #122273.


Index: boilerplate.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/texinputs/boilerplate.tex,v
retrieving revision 1.50
retrieving revision 1.51
diff -C2 -r1.50 -r1.51
*** boilerplate.tex 2000/10/13 15:35:27 1.50
--- boilerplate.tex 2000/11/17 19:05:12 1.51
***************
*** 6,10 ****
}

! \date{October 16, 2000} % XXX update before release!
\release{2.0} % software release, not documentation
\setshortversion{2.0} % major.minor only for software
--- 6,10 ----
}

! \date{\today} % XXX update before release!
\release{2.0} % software release, not documentation
\setshortversion{2.0} % major.minor only for software

Index: howto.cls
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/texinputs/howto.cls,v
retrieving revision 1.11
retrieving revision 1.12
diff -C2 -r1.11 -r1.12
*** howto.cls 2000/09/05 15:19:56 1.11
--- howto.cls 2000/11/17 19:05:12 1.12
***************
*** 7,10 ****
--- 7,11 ----
[1998/02/25 Document class (Python HOWTO)]

+ \RequirePackage{pypaper}

% Change the options here to get a different set of basic options, This



From python-dev@python.org Fri Nov 17 19:05:15 2000
From: python-dev@python.org (Fred L. Drake)
Date: Fri, 17 Nov 2000 11:05:15 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/tools listmodules,1.3,1.4
Message-ID: <200011171905.LAA31801@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/tools
In directory slayer.i.sourceforge.net:/tmp/cvs-serv31740/tools

Modified Files:
listmodules
Log Message:

Note that readframes() returns data in linear format, even if the original
is encoded in u-LAW format. Based on suggestion from Anthony Baxter
<anthony_baxter@users.sourceforge.net>.

This closes bug #122273.


Index: listmodules
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/tools/listmodules,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** listmodules 1999/06/17 18:49:18 1.3
--- listmodules 2000/11/17 19:05:12 1.4
***************
*** 9,24 ****
"""%(program)s - list modules in the Python standard library

! -a, --annotate Annotate the module names with the subdirectory they live in
-c, --categorize Group the modules by subdirectory
-i <file>,
- --ignore-from <file> Ignore the modules listed in <file>. <file> may contain
- a list of module names or a module index file as produced
- when formatting the Python documentation (.idx flavor).

! If neither -a nor -c are given, the modules are listed in alphabetical order.

Note that -a and -c are mutually exclusive.

- Limitation: Modules loadable as shared objects are not listed.
"""

--- 9,30 ----
"""%(program)s - list modules in the Python standard library

! -a, --annotate Annotate the module names with the subdirectory they
! live in
-c, --categorize Group the modules by subdirectory
-i <file>,

! --ignore-from <file> Ignore the modules listed in <file>. <file> may
! contain a list of module names or a module index file
! as produced when formatting the Python documentation
! (.idx or .html flavor).

+ If neither -a nor -c are given, the modules are listed in alphabetical
+ order.
+
Note that -a and -c are mutually exclusive.
+
+ Limitation: Modules loadable as shared objects may not be listed,
+ though this script attempts to locate such modules.

"""

***************
*** 33,37 ****


! REMOVE_DIRS = ["dos-8x3", "lib-old", "lib-stdwin", "test"]


--- 39,44 ----


! REMOVE_DIRS = ["dos-8x3", "encodings", "distutils",
! "lib-old", "lib-stdwin", "test"]


***************
*** 87,91 ****
modules_by_name[name] = "<built-in>"
l.append(name)
! rx = re.compile("Lib/plat-[a-z0-9]*/", re.IGNORECASE)
fp = os.popen("find Lib -name \*.py -print", "r")
while 1:
--- 94,98 ----
modules_by_name[name] = "<built-in>"
l.append(name)
! rx = re.compile("Lib/plat-[a-zA-Z0-9]*/")
fp = os.popen("find Lib -name \*.py -print", "r")
while 1:



From python-dev@python.org Fri Nov 17 19:05:15 2000
From: python-dev@python.org (Fred L. Drake)
Date: Fri, 17 Nov 2000 11:05:15 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/tools/sgmlconv conversion.xml,1.8,1.9
Message-ID: <200011171905.LAA31798@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/tools/sgmlconv
In directory slayer.i.sourceforge.net:/tmp/cvs-serv31740/tools/sgmlconv

Modified Files:
conversion.xml
Log Message:

Note that readframes() returns data in linear format, even if the original
is encoded in u-LAW format. Based on suggestion from Anthony Baxter
<anthony_baxter@users.sourceforge.net>.

This closes bug #122273.


Index: conversion.xml
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/tools/sgmlconv/conversion.xml,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -r1.8 -r1.9
*** conversion.xml 2000/07/01 06:26:44 1.8
--- conversion.xml 2000/11/17 19:05:12 1.9
***************
*** 79,82 ****
--- 79,84 ----
<content/>
</macro>
+ <macro name="unspecified"/>
+ <macro name="moreargs"/>
<environment name="classdesc">
<attribute name="name"/>
***************
*** 410,413 ****
--- 412,424 ----
<child name="entry"/>
</environment>
+ <environment name="longtableii" outputname="table">
+ <attribute name="cols">2</attribute>
+ <attribute name="colspec"/>
+ <attribute name="style"/>
+ <child name="entry"/>
+ <text>
+ </text>
+ <child name="entry"/>
+ </environment>
<macro name="lineii" outputname="row">
<child name="entry"/>
***************
*** 429,432 ****
--- 440,455 ----
<child name="entry"/>
</environment>
+ <environment name="longtableiii" outputname="table">
+ <attribute name="cols">3</attribute>
+ <attribute name="colspec"/>
+ <attribute name="style"/>
+ <child name="entry"/>
+ <text>
+ </text>
+ <child name="entry"/>
+ <text>
+ </text>
+ <child name="entry"/>
+ </environment>
<macro name="lineiii" outputname="row">
<child name="entry"/>
***************
*** 440,443 ****
--- 463,481 ----

<environment name="tableiv" outputname="table">
+ <attribute name="cols">4</attribute>
+ <attribute name="colspec"/>
+ <attribute name="style"/>
+ <child name="entry"/>
+ <text>
+ </text>
+ <child name="entry"/>
+ <text>
+ </text>
+ <child name="entry"/>
+ <text>
+ </text>
+ <child name="entry"/>
+ </environment>
+ <environment name="longtableiv" outputname="table">
<attribute name="cols">4</attribute>
<attribute name="colspec"/>



From python-dev@python.org Fri Nov 17 19:09:50 2000
From: python-dev@python.org (Fred L. Drake)
Date: Fri, 17 Nov 2000 11:09:50 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib liblocale.tex,1.19,1.20
Message-ID: <200011171909.LAA32569@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv32520/lib

Modified Files:
liblocale.tex
Log Message:

Oops, back out change committed by accident! This is not ready, and
breaks things.


Index: liblocale.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/liblocale.tex,v
retrieving revision 1.19
retrieving revision 1.20
diff -C2 -r1.19 -r1.20
*** liblocale.tex 2000/11/17 19:05:11 1.19
--- liblocale.tex 2000/11/17 19:09:34 1.20
***************
*** 62,99 ****
This dictionary has the following strings as keys:

- \begin{tableiii}{l|l|l}{code}{Key}{Category}{Meaning}
- \lineiii{'decimal_point'}{\constant{LC_NUMERIC}}
- {Decimal point character.}
- \lineiii{'grouping'}{\constant{LC_NUMERIC}}
- {Sequence of numbers specifying which relative positions
- the \code{'thousands_sep'} is expected. If the sequence is
- terminated with \constant{CHAR_MAX}, no further grouping
- is performed. If the sequence terminates with a \code{0},
- the last group size is repeatedly used.}
- \lineiii{'thousands_sep'}{\constant{LC_NUMERIC}}
- {Character used between groups.}\hline
- \lineiii{'int_curr_symbol'}{\constant{LC_MONETARY}}
- {International currency symbol.}
- \lineiii{'currency_symbol'}{\constant{LC_MONETARY}}
- {Local currency symbol.}
- \lineiii{'mon_decimal_point'}{\constant{LC_MONETARY}}
- {Decimal point used for monetary values.}
- \lineiii{'mon_thousands_sep'}{\constant{LC_MONETARY}}
- {Group separator used for monetary values.}
- \lineiii{'mon_grouping'}{\constant{LC_MONETARY}}
- {Equivalent to \code{'grouping'}, used for monetary
- values.}
- \lineiii{'positive_sign'}{\constant{LC_MONETARY}}
- {Symbol used to annotate a positive monetary value.}
- \lineiii{'negative_sign'}{\constant{LC_MONETARY}}
- {Symbol used to annotate a nnegative monetary value.}
- \lineiii{'frac_digits'}{\constant{LC_MONETARY}}
- {Number of fractional digits used in local formatting
- of monetary values.}
- \lineiii{'int_frac_digits'}{\constant{LC_MONETARY}}
- {Number of fractional digits used in international
- formatting of monetary values.}
- \end{tableiii}
-
\begin{itemize}
\item
--- 62,65 ----



From python-dev@python.org Fri Nov 17 19:44:17 2000
From: python-dev@python.org (Fred L. Drake)
Date: Fri, 17 Nov 2000 11:44:17 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib libstdtypes.tex,1.41,1.42 libfuncs.tex,1.71,1.72
Message-ID: <200011171944.LAA04434@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv4419/lib

Modified Files:
libstdtypes.tex libfuncs.tex
Log Message:

Added information about the %r string formatting conversion. Added note
about the interpretation of radix 0 for int(), and added description of
the optional radix argument for long(). Based on comments from Reuben
Sumner <rasumner@users.sourceforge.net>.

This closes bug #121672.


Index: libstdtypes.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/libstdtypes.tex,v
retrieving revision 1.41
retrieving revision 1.42
diff -C2 -r1.41 -r1.42
*** libstdtypes.tex 2000/11/06 20:17:37 1.41
--- libstdtypes.tex 2000/11/17 19:44:14 1.42
***************
*** 602,608 ****
argument, the right argument may also be a single non-tuple
object.\footnote{A tuple object in this case should be a singleton.
! } The following format characters are understood:
! \code{\%}, \code{c}, \code{s}, \code{i}, \code{d}, \code{u}, \code{o},
! \code{x}, \code{X}, \code{e}, \code{E}, \code{f}, \code{g}, \code{G}.
Width and precision may be a \code{*} to specify that an integer argument
specifies the actual width or precision. The flag characters
--- 602,608 ----
argument, the right argument may also be a single non-tuple
object.\footnote{A tuple object in this case should be a singleton.
! } The following format characters are understood: \code{\%},
! \code{c}, \code{r}, \code{s}, \code{i}, \code{d}, \code{u}, \code{o},
! \code{x}, \code{X}, \code{e}, \code{E}, \code{f}, \code{g}, \code{G}.
Width and precision may be a \code{*} to specify that an integer argument
specifies the actual width or precision. The flag characters
***************
*** 610,614 ****
size specifiers \code{h}, \code{l} or \code{L} may be present but are
ignored. The \code{\%s} conversion takes any Python object and
! converts it to a string using \code{str()} before formatting it. The
ANSI features \code{\%p} and \code{\%n} are not supported. Since
Python strings have an explicit length, \code{\%s} conversions don't
--- 610,616 ----
size specifiers \code{h}, \code{l} or \code{L} may be present but are
ignored. The \code{\%s} conversion takes any Python object and
! converts it to a string using \code{str()} before formatting it; the
! \code{\%r} conversion is similar but applies the \function{repr()}
! function instead. The
ANSI features \code{\%p} and \code{\%n} are not supported. Since
Python strings have an explicit length, \code{\%s} conversions don't

Index: libfuncs.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/libfuncs.tex,v
retrieving revision 1.71
retrieving revision 1.72
diff -C2 -r1.71 -r1.72
*** libfuncs.tex 2000/09/12 16:23:48 1.71
--- libfuncs.tex 2000/11/17 19:44:14 1.72
***************
*** 332,337 ****
this behaves identical to \code{string.atoi(\var{x}\optional{,
\var{radix}})}. The \var{radix} parameter gives the base for the
! conversion and may be any integer in the range [2, 36]. If
! \var{radix} is specified and \var{x} is not a string,
\exception{TypeError} is raised.
Otherwise, the argument may be a plain or
--- 332,339 ----
this behaves identical to \code{string.atoi(\var{x}\optional{,
\var{radix}})}. The \var{radix} parameter gives the base for the
! conversion and may be any integer in the range [2, 36], or zero. If
! \var{radix} is zero, the proper radix is guessed based on the
! contents of string; the interpretation is the same as for integer
! literals. If \var{radix} is specified and \var{x} is not a string,
\exception{TypeError} is raised.
Otherwise, the argument may be a plain or
***************
*** 393,401 ****
\end{funcdesc}

! \begin{funcdesc}{long}{x}
Convert a string or number to a long integer. If the argument is a
string, it must contain a possibly signed decimal number of
arbitrary size, possibly embedded in whitespace;
! this behaves identical to \code{string.atol(\var{x})}.
Otherwise, the argument may be a plain or
long integer or a floating point number, and a long integer with
--- 395,405 ----
\end{funcdesc}

! \begin{funcdesc}{long}{x\optional{, radix}}
Convert a string or number to a long integer. If the argument is a
string, it must contain a possibly signed decimal number of
arbitrary size, possibly embedded in whitespace;
! this behaves identical to \code{string.atol(\var{x})}. The
! \var{radix} argument is interpreted in the same way as for
! \function{int()}, and may only be given when \var{x} is a string.
Otherwise, the argument may be a plain or
long integer or a floating point number, and a long integer with



From python-dev@python.org Fri Nov 17 22:54:49 2000
From: python-dev@python.org (Fred L. Drake)
Date: Fri, 17 Nov 2000 14:54:49 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0205.txt,1.4,1.5
Message-ID: <200011172254.OAA27822@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv27802

Modified Files:
pep-0205.txt
Log Message:

Updated information on Dianne Hackborn's old vref proposal. A copy of
her original proposal has been included as an appendix, since it is hard
to get since DejaNews lost their old archives.


Index: pep-0205.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0205.txt,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -r1.4 -r1.5
*** pep-0205.txt 2000/11/08 06:47:05 1.4
--- pep-0205.txt 2000/11/17 22:54:45 1.5
***************
*** 104,119 ****
Previous Weak Reference Work in Python

! Diane Hackborn's vref proposal. 'vref' objects were very similar
! to java.lang.ref.WeakReference objects, except there was no
! equivalent to the invalidation queues. Implementing a "weak
! dictionary" would be just as difficult as using only weak
! references (without the invalidation queue) in Java. Information
! on this has disappeared from the Web. Original discussion
! occurred in the comp.lang.python newsgroup; a good archive of that
! may turn up something more.

- Dianne doesn't have any record of her proposal, and doesn't recall
- doing an implementation.
-
Marc-André Lemburg's mx.Proxy package. These Web pages appear to
be unavailable at the moment.
--- 104,116 ----
Previous Weak Reference Work in Python

! Dianne Hackborn's proposed something called "virtual references".
! 'vref' objects were very similar to java.lang.ref.WeakReference
! objects, except there was no equivalent to the invalidation
! queues. Implementing a "weak dictionary" would be just as
! difficult as using only weak references (without the invalidation
! queue) in Java. Information on this has disappeared from the Web.
! Original discussion occurred in the comp.lang.python newsgroup; a
! good archive of that may turn up something more.

Marc-André Lemburg's mx.Proxy package. These Web pages appear to
be unavailable at the moment.
***************
*** 128,131 ****
--- 125,132 ----
http://www.handshake.de/~dieter/weakdict.html

+ PyWeakReference by Alex Shindich:
+
+ http://sourceforge.net/projects/pyweakreference/
+

Possible Applications
***************
*** 133,137 ****
PyGTK+ bindings?

! Tkinter?

DOM trees?
--- 134,143 ----
PyGTK+ bindings?

! Tkinter -- could avoid circular references by using weak
! references from widgets to their parents. Objects won't be
! discarded any sooner in the typical case, but there won't be so
! much dependence on the programmer calling .destroy() before
! releasing a reference. This would mostly benefit long-running
! applications.

DOM trees?
***************
*** 141,144 ****
--- 147,282 ----

XXX -- Not yet.
+
+
+ Appendix -- Dianne Hackborn's vref proposal (1995)
+
+ [This has been indented and paragraphs reflowed, but there have be
+ no content changes. --Fred]
+
+ Proposal: Virtual References
+
+ In an attempt to partly address the recurring discussion
+ concerning reference counting vs. garbage collection, I would like
+ to propose an extension to Python which should help in the
+ creation of "well structured" cyclic graphs. In particular, it
+ should allow at least trees with parent back-pointers and
+ doubly-linked lists to be created without worry about cycles.
+
+ The basic mechanism I'd like to propose is that of a "virtual
+ reference," or a "vref" from here on out. A vref is essentially a
+ handle on an object that does not increment the object's reference
+ count. This means that holding a vref on an object will not keep
+ the object from being destroyed. This would allow the Python
+ programmer, for example, to create the aforementioned tree
+ structure tree structure, which is automatically destroyed when it
+ is no longer in use -- by making all of the parent back-references
+ into vrefs, they no longer create reference cycles which keep the
+ tree from being destroyed.
+
+ In order to implement this mechanism, the Python core must ensure
+ that no -real- pointers are ever left referencing objects that no
+ longer exist. The implementation I would like to propose involves
+ two basic additions to the current Python system:
+
+ 1. A new "vref" type, through which the Python programmer creates
+ and manipulates virtual references. Internally, it is
+ basically a C-level Python object with a pointer to the Python
+ object it is a reference to. Unlike all other Python code,
+ however, it does not change the reference count of this object.
+ In addition, it includes two pointers to implement a
+ doubly-linked list, which is used below.
+
+ 2. The addition of a new field to the basic Python object
+ [PyObject_Head in object.h], which is either NULL, or points to
+ the head of a list of all vref objects that reference it. When
+ a vref object attaches itself to another object, it adds itself
+ to this linked list. Then, if an object with any vrefs on it
+ is deallocated, it may walk this list and ensure that all of
+ the vrefs on it point to some safe value, e.g. Nothing.
+
+
+ This implementation should hopefully have a minimal impact on the
+ current Python core -- when no vrefs exist, it should only add one
+ pointer to all objects, and a check for a NULL pointer every time
+ an object is deallocated.
+
+ Back at the Python language level, I have considered two possible
+ semantics for the vref object --
+
+ ==> Pointer semantics:
+
+ In this model, a vref behaves essentially like a Python-level
+ pointer; the Python program must explicitly dereference the vref
+ to manipulate the actual object it references.
+
+ An example vref module using this model could include the
+ function "new"; When used as 'MyVref = vref.new(MyObject)', it
+ returns a new vref object such that that MyVref.object =+ MyObject. MyVref.object would then change to Nothing if
+ MyObject is ever deallocated.
+
+ For a concrete example, we may introduce some new C-style syntax:
+
+ & -- unary operator, creates a vref on an object, same as vref.new().
+ * -- unary operator, dereference a vref, same as VrefObject.object.
+
+ We can then define:
+
+ 1. type(&MyObject) == vref.VrefType
+ 2. *(&MyObject) == MyObject
+ 3. (*(&MyObject)).attr == MyObject.attr
+ 4. &&MyObject == Nothing
+ 5. *MyObject -> exception
+
+ Rule #4 is subtle, but comes about because we have made a vref
+ to (a vref with no real references). Thus the outer vref is
+ cleared to Nothing when the inner one inevitably disappears.
+
+ ==> Proxy semantics:
+
+ In this model, the Python programmer manipulates vref objects
+ just as if she were manipulating the object it is a reference
+ of. This is accomplished by implementing the vref so that all
+ operations on it are redirected to its referenced object. With
+ this model, the dereference operator (*) no longer makes sense;
+ instead, we have only the reference operator (&), and define:
+
+ 1. type(&MyObject) == type(MyObject)
+ 2. &MyObject == MyObject
+ 3. (&MyObject).attr == MyObject.attr
+ 4. &&MyObject == MyObject
+
+ Again, rule #4 is important -- here, the outer vref is in fact a
+ reference to the original object, and -not- the inner vref.
+ This is because all operations applied to a vref actually apply
+ to its object, so that creating a vref of a vref actually
+ results in creating a vref of the latter's object.
+
+ The first, pointer semantics, has the advantage that it would be
+ very easy to implement; the vref type is extremely simple,
+ requiring at minimum a single attribute, object, and a function to
+ create a reference.
+
+ However, I really like the proxy semantics. Not only does it put
+ less of a burden on the Python programmer, but it allows you to do
+ nice things like use a vref anywhere you would use the actual
+ object. Unfortunately, it would probably an extreme pain, if not
+ practically impossible, to implement in the current Python
+ implementation. I do have some thoughts, though, on how to do
+ this, if it seems interesting; one possibility is to introduce new
+ type-checking functions which handle the vref. This would
+ hopefully older C modules which don't expect vrefs to simply
+ return a type error, until they can be fixed.
+
+ Finally, there are some other additional capabilities that this
+ system could provide. One that seems particularily interesting to
+ me involves allowing the Python programmer to add "destructor"
+ function to a vref -- this Python function would be called
+ immediately prior to the referenced object being deallocated,
+ allowing a Python program to invisibly attach itself to another
+ object and watch for it to disappear. This seems neat, though I
+ haven't actually come up with any practical uses for it, yet... :)
+
+ -- Dianne





From python-dev@python.org Sat Nov 18 17:46:02 2000
From: python-dev@python.org (A.M. Kuchling)
Date: Sat, 18 Nov 2000 09:46:02 -0800
Subject: [Python-checkins] CVS: python/dist/src/Modules _cursesmodule.c,2.41,2.42
Message-ID: <200011181746.JAA20958@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Modules
In directory slayer.i.sourceforge.net:/tmp/cvs-serv20498

Modified Files:
_cursesmodule.c
Log Message:
Patch #102412 from mwh: Add support for the setupterm() function, to
initialize the terminal without necessarily calling initscr()


Index: _cursesmodule.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Modules/_cursesmodule.c,v
retrieving revision 2.41
retrieving revision 2.42
diff -C2 -r2.41 -r2.42
*** _cursesmodule.c 2000/11/07 03:34:44 2.41
--- _cursesmodule.c 2000/11/18 17:45:59 2.42
***************
*** 45,54 ****
mvinchstr mvinnstr mmvwaddchnstr mvwaddchstr mvwchgat
mvwgetnstr mvwinchnstr mvwinchstr mvwinnstr napms newterm
! overlay overwrite resetty resizeterm restartterm ripoffline
! savetty scr_dump scr_init scr_restore scr_set scrl set_curterm
! set_term setterm setupterm tgetent tgetflag tgetnum tgetstr
! tgoto timeout tputs typeahead use_default_colors vidattr
! vidputs waddchnstr waddchstr wchgat wcolor_set winchnstr
! winchstr winnstr wmouse_trafo wredrawln wscrl wtimeout

Low-priority:
--- 45,53 ----
mvinchstr mvinnstr mmvwaddchnstr mvwaddchstr mvwchgat
mvwgetnstr mvwinchnstr mvwinchstr mvwinnstr napms newterm
! overlay overwrite resizeterm restartterm ripoffline scr_dump
! scr_init scr_restore scr_set scrl set_curterm set_term setterm
! tgetent tgetflag tgetnum tgetstr tgoto timeout tputs
! use_default_colors vidattr vidputs waddchnstr waddchstr wchgat
! wcolor_set winchnstr winchstr winnstr wmouse_trafo wscrl

Low-priority:
***************
*** 78,86 ****
#endif

#ifdef sgi
- /* This prototype is in <term.h>, but including this header #defines
- many common symbols (such as "lines") which breaks the curses
- module in other ways. So the code will just specify an explicit
- prototype here. */
extern char *tigetstr(char *);
#endif
--- 77,86 ----
#endif

+ /* These prototypes are in <term.h>, but including this header
+ #defines many common symbols (such as "lines") which breaks the
+ curses module in other ways. So the code will just specify
+ explicit prototypes here. */
+ extern int setupterm(char *,int,int *);
#ifdef sgi
extern char *tigetstr(char *);
#endif
***************
*** 99,102 ****
--- 99,105 ----
static char *catchall_NULL = "curses function returned NULL";

+ /* Tells whether setupterm() has been called to initialise terminfo. */
+ static int initialised_setupterm = FALSE;
+
/* Tells whether initscr() has been called to initialise curses. */
static int initialised = FALSE;
***************
*** 109,112 ****
--- 112,121 ----
(((X) == NULL) ? 0 : (PyTuple_Check(X) ? PyTuple_Size(X) : 1))

+ #define PyCursesSetupTermCalled \
+ if (initialised_setupterm != TRUE) { \
+ PyErr_SetString(PyCursesError, \
+ "must call (at least) setupterm() first"); \
+ return NULL; }
+
#define PyCursesInitialised \
if (initialised != TRUE) { \
***************
*** 1703,1707 ****
}

! initialised = TRUE;

/* This was moved from initcurses() because it core dumped on SGI,
--- 1712,1716 ----
}

! initialised = initialised_setupterm = TRUE;

/* This was moved from initcurses() because it core dumped on SGI,
***************
*** 1781,1784 ****
--- 1790,1844 ----
}

+ static PyObject *
+ PyCurses_setupterm(PyObject* self, PyObject *args, PyObject* keywds)
+ {
+ int fd = -1;
+ int err;
+ char* termstr = NULL;
+
+ static char *kwlist[] = {"term", "fd", NULL};
+
+ if (!PyArg_ParseTupleAndKeywords(
+ args,keywds,"|zi:setupterm",kwlist,&termstr,&fd)) {
+ return NULL;
+ }
+
+ if (fd == -1) {
+ PyObject* sys_stdout;
+
+ sys_stdout = PySys_GetObject("stdout");
+
+ if (sys_stdout == NULL) {
+ PyErr_SetString(
+ PyCursesError,
+ "lost sys.stdout");
+ return NULL;
+ }
+
+ fd = PyObject_AsFileDescriptor(sys_stdout);
+
+ if (fd == -1) {
+ return NULL;
+ }
+ }
+
+ if (setupterm(termstr,fd,&err) == ERR) {
+ char* s = "setupterm: unknown error";
+
+ if (err == 0) {
+ s = "setupterm: could not find terminal";
+ } else if (err == -1) {
+ s = "setupterm: could not find terminfo database";
+ }
+
+ PyErr_SetString(PyCursesError,s);
+ return NULL;
+ }
+
+ initialised_setupterm = TRUE;
+
+ Py_INCREF(Py_None);
+ return Py_None;
+ }

static PyObject *
***************
*** 2058,2062 ****
char *capname;

! PyCursesInitialised;

if (!PyArg_ParseTuple(args, "z", &capname))
--- 2118,2122 ----
char *capname;

! PyCursesSetupTermCalled;

if (!PyArg_ParseTuple(args, "z", &capname))
***************
*** 2071,2075 ****
char *capname;

! PyCursesInitialised;

if (!PyArg_ParseTuple(args, "z", &capname))
--- 2131,2135 ----
char *capname;

! PyCursesSetupTermCalled;

if (!PyArg_ParseTuple(args, "z", &capname))
***************
*** 2084,2088 ****
char *capname;

! PyCursesInitialised;

if (!PyArg_ParseTuple(args, "z", &capname))
--- 2144,2148 ----
char *capname;

! PyCursesSetupTermCalled;

if (!PyArg_ParseTuple(args, "z", &capname))
***************
*** 2104,2108 ****
int i1,i2,i3,i4,i5,i6,i7,i8,i9;

! PyCursesInitialised;

if (!PyArg_ParseTuple(args, "s|iiiiiiiii:tparm",
--- 2164,2168 ----
int i1,i2,i3,i4,i5,i6,i7,i8,i9;

! PyCursesSetupTermCalled;

if (!PyArg_ParseTuple(args, "s|iiiiiiiii:tparm",
***************
*** 2291,2294 ****
--- 2351,2355 ----
{"savetty", (PyCFunction)PyCurses_savetty},
{"setsyx", (PyCFunction)PyCurses_setsyx},
+ {"setupterm", (PyCFunction)PyCurses_setupterm, METH_VARARGS|METH_KEYWORDS},
{"start_color", (PyCFunction)PyCurses_Start_Color},
{"termattrs", (PyCFunction)PyCurses_termattrs},



From python-dev@python.org Sat Nov 18 17:57:37 2000
From: python-dev@python.org (A.M. Kuchling)
Date: Sat, 18 Nov 2000 09:57:37 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib libcurses.tex,1.21,1.22
Message-ID: <200011181757.JAA22407@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv22367

Modified Files:
libcurses.tex
Log Message:
Document the new setupterm() function


Index: libcurses.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/libcurses.tex,v
retrieving revision 1.21
retrieving revision 1.22
diff -C2 -r1.21 -r1.22
*** libcurses.tex 2000/11/07 03:35:24 1.21
--- libcurses.tex 2000/11/18 17:57:33 1.22
***************
*** 422,425 ****
--- 422,432 ----
\end{funcdesc}

+ \begin{funcdesc}{setupterm}{\optional{termstr, fd}}
+ Initializes the terminal. \var{termstr} is a string giving the
+ terminal name; if omitted, the value of the TERM environment variable
+ will be used. \var{fd} is the file descriptor to which any initialization sequences will be sent; if not supplied, the file descriptor for
+ \code{sys.stdout} will be used.
+ \end{funcdesc}
+
\begin{funcdesc}{start_color}{}
Must be called if the programmer wants to use colors, and before any



From python-dev@python.org Tue Nov 21 22:02:24 2000
From: python-dev@python.org (Fred L. Drake)
Date: Tue, 21 Nov 2000 14:02:24 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib/xml/dom minidom.py,1.13,1.14
Message-ID: <200011212202.OAA16186@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib/xml/dom
In directory slayer.i.sourceforge.net:/tmp/cvs-serv16177/Lib/xml/dom

Modified Files:
minidom.py
Log Message:
Reduce the visibility of imported modules for cleaner "from ... import *"
behavior.

Added support for the Attr.ownerElement attribute.

Everywhere: Define constant object attributes in the classes rather than
on the instances during object construction. This reduces the amount of
work needed for object construction and destruction; these need to be
lightweight operations on a DOM.

Node._get_firstChild(),
Node._get_lastChild(): Return None if there are no children (required for
compliance with DOM level 1).

Node.insertBefore(): If refChild is None, append the new node instead of
failing (required for compliance). Also, update the sibling
relationships. Return the inserted node (required for compliance).

Node.appendChild(): Update the parent of the appended node.

Node.replaceChild(): Actually replace the old child! Update the parent
and sibling relationships of both the old and new children. Return
the replaced child (required for compliance).

Node.normalize(): Implemented the normalize() method. Required for
compliance, but missing from the release. Useful for joining
adjacent Text nodes into a single node for easier processing.

Node.cloneNode(): Actually make this work. Don't let the new node share
the instance __dict__ with the original. Do proper recursion if
doing a "deep" clone. Move the attribute cloning out of the base
class, since only Element is supposed to have attributes.

Node.unlink(): Simplify handling of child nodes for efficiency, and
remove the attribute handling since only Element nodes support
attributes.

Attr.cloneNode(): Extend this to clear the ownerElement attribute in
the clone.

AttributeList.items(),
AttributeList.itemsNS(): Slight performance improvement (avoid lambda).

Element.cloneNode(): Extend Node.cloneNode() with support for the
attributes. Clone the Attr objects after creating the underlying
clone.

Element.unlink(): Clean out the attributes here instead of in the base
class, since this is the only class that will have them.

Element.toxml(): Adjust to create only one AttributeList instance; minor
efficiency improvement.

_nssplit(): No need to re-import string.

Document.__init__(): No longer needed once constant attributes are
initialized in the class itself.

Document.createElementNS(),
Document.createAttributeNS(): Use the defined constructors rather than
directly access the classes.

_get_StringIO(): New function. Create an output StringIO using the most
efficient available flavor.

parse(),
parseString(): Import pulldom here instead of in the public namespace of
the module.


Index: minidom.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/xml/dom/minidom.py,v
retrieving revision 1.13
retrieving revision 1.14
diff -C2 -r1.13 -r1.14
*** minidom.py 2000/10/23 18:09:50 1.13
--- minidom.py 2000/11/21 22:02:22 1.14
***************
*** 15,22 ****
"""

- import pulldom
import string
! from StringIO import StringIO
import types

class Node:
--- 15,31 ----
"""

import string
! _string = string
! del string
!
! # localize the types, and allow support for Unicode values if available:
import types
+ _TupleType = types.TupleType
+ try:
+ _StringTypes = (types.StringType, types.UnicodeType)
+ except AttributeError:
+ _StringTypes = (types.StringType,)
+ del types
+

class Node:
***************
*** 45,49 ****
Node.allnodes[index] = repr(self.__dict__)
if Node.debug is None:
! Node.debug = StringIO()
#open( "debug4.out", "w" )
Node.debug.write("create %s\n" % index)
--- 54,58 ----
Node.allnodes[index] = repr(self.__dict__)
if Node.debug is None:
! Node.debug = _get_StringIO()
#open( "debug4.out", "w" )
Node.debug.write("create %s\n" % index)
***************
*** 80,84 ****

def toxml(self):
! writer = StringIO()
self.writexml(writer)
return writer.getvalue()
--- 89,93 ----

def toxml(self):
! writer = _get_StringIO()
self.writexml(writer)
return writer.getvalue()
***************
*** 91,104 ****

def _get_firstChild(self):
! return self.childNodes[0]

def _get_lastChild(self):
! return self.childNodes[-1]

def insertBefore(self, newChild, refChild):
! index = self.childNodes.index(refChild)
! self.childNodes.insert(index, newChild)
! if self._makeParentNodes:
! newChild.parentNode = self

def appendChild(self, node):
--- 100,127 ----

def _get_firstChild(self):
! if self.childNodes:
! return self.childNodes[0]

def _get_lastChild(self):
! if self.childNodes:
! return self.childNodes[-1]

def insertBefore(self, newChild, refChild):
! if refChild is None:
! self.appendChild(newChild)
! else:
! index = self.childNodes.index(refChild)
! self.childNodes.insert(index, newChild)
! newChild.nextSibling = refChild
! refChild.previousSibling = newChild
! if index:
! node = self.childNodes[index-1]
! node.nextSibling = newChild
! newChild.previousSibling = node
! else:
! newChild.previousSibling = None
! if self._makeParentNodes:
! newChild.parentNode = self
! return newChild

def appendChild(self, node):
***************
*** 111,147 ****
node.nextSibling = None
self.childNodes.append(node)
return node

def replaceChild(self, newChild, oldChild):
index = self.childNodes.index(oldChild)
! self.childNodes[index] = oldChild

def removeChild(self, oldChild):
! index = self.childNodes.index(oldChild)
! del self.childNodes[index]

def cloneNode(self, deep):
import new
! clone = new.instance(self.__class__, self.__dict__)
! clone.attributes = self.attributes.copy()
! if not deep:
! clone.childNodes = []
! else:
! clone.childNodes = map(lambda x: x.cloneNode, self.childNodes)
return clone

def unlink(self):
self.parentNode = None
! while self.childNodes:
! self.childNodes[-1].unlink()
! del self.childNodes[-1] # probably not most efficient!
self.childNodes = None
self.previousSibling = None
self.nextSibling = None
- if self.attributes:
- for attr in self._attrs.values():
- self.removeAttributeNode(attr)
- assert not len(self._attrs)
- assert not len(self._attrsNS)
if Node._debug:
index = repr(id(self)) + repr(self.__class__)
--- 134,200 ----
node.nextSibling = None
self.childNodes.append(node)
+ if self._makeParentNodes:
+ node.parentNode = self
return node

def replaceChild(self, newChild, oldChild):
+ if newChild is oldChild:
+ return
index = self.childNodes.index(oldChild)
! self.childNodes[index] = newChild
! if self._makeParentNodes:
! newChild.parentNode = self
! oldChild.parentNode = None
! newChild.nextSibling = oldChild.nextSibling
! newChild.previousSibling = oldChild.previousSibling
! oldChild.newChild = None
! oldChild.previousSibling = None
! return oldChild

def removeChild(self, oldChild):
! self.childNodes.remove(oldChild)
! if self._makeParentNodes:
! oldChild.parentNode = None
! return oldChild

+ def normalize(self):
+ if len(self.childNodes) > 1:
+ L = [self.childNodes[0]]
+ for child in self.childNodes[1:]:
+ if ( child.nodeType == Node.TEXT_NODE
+ and L[-1].nodeType == child.nodeType):
+ # collapse text node
+ node = L[-1]
+ node.data = node.nodeValue = node.data + child.data
+ node.nextSibling = child.nextSibling
+ child.unlink()
+ else:
+ L[-1].nextSibling = child
+ child.previousSibling = L[-1]
+ L.append(child)
+ child.normalize()
+ self.childNodes = L
+ elif self.childNodes:
+ # exactly one child -- just recurse
+ self.childNodes[0].normalize()
+
def cloneNode(self, deep):
import new
! clone = new.instance(self.__class__, self.__dict__.copy())
! if self._makeParentNodes:
! clone.parentNode = None
! clone.childNodes = []
! if deep:
! for child in self.childNodes:
! clone.appendChild(child.cloneNode(1))
return clone

def unlink(self):
self.parentNode = None
! for child in self.childNodes:
! child.unlink()
self.childNodes = None
self.previousSibling = None
self.nextSibling = None
if Node._debug:
index = repr(id(self)) + repr(self.__class__)
***************
*** 151,158 ****
def _write_data(writer, data):
"Writes datachars to writer."
! data = string.replace(data, "&", "&amp;")
! data = string.replace(data, "<", "&lt;")
! data = string.replace(data, "\"", "&quot;")
! data = string.replace(data, ">", "&gt;")
writer.write(data)

--- 204,212 ----
def _write_data(writer, data):
"Writes datachars to writer."
! replace = _string.replace
! data = replace(data, "&", "&amp;")
! data = replace(data, "<", "&lt;")
! data = replace(data, "\"", "&quot;")
! data = replace(data, ">", "&gt;")
writer.write(data)

***************
*** 175,186 ****
class Attr(Node):
nodeType = Node.ATTRIBUTE_NODE

def __init__(self, qName, namespaceURI="", localName=None, prefix=None):
# skip setattr for performance
! self.__dict__["localName"] = localName or qName
! self.__dict__["nodeName"] = self.__dict__["name"] = qName
! self.__dict__["namespaceURI"] = namespaceURI
! self.__dict__["prefix"] = prefix
! self.attributes = None
Node.__init__(self)
# nodeValue and value are set elsewhere
--- 229,242 ----
class Attr(Node):
nodeType = Node.ATTRIBUTE_NODE
+ attributes = None
+ ownerElement = None

def __init__(self, qName, namespaceURI="", localName=None, prefix=None):
# skip setattr for performance
! d = self.__dict__
! d["localName"] = localName or qName
! d["nodeName"] = d["name"] = qName
! d["namespaceURI"] = namespaceURI
! d["prefix"] = prefix
Node.__init__(self)
# nodeValue and value are set elsewhere
***************
*** 192,203 ****
self.__dict__[name] = value

class AttributeList:
! """the attribute list is a transient interface to the underlying
! dictionaries. mutations here will change the underlying element's
dictionary"""
def __init__(self, attrs, attrsNS):
self._attrs = attrs
self._attrsNS = attrsNS
! self.length = len(self._attrs.keys())

def item(self, index):
--- 248,266 ----
self.__dict__[name] = value

+ def cloneNode(self, deep):
+ clone = Node.cloneNode(self, deep)
+ if clone.__dict__.has_key("ownerElement"):
+ del clone.ownerElement
+ return clone
+
class AttributeList:
! """The attribute list is a transient interface to the underlying
! dictionaries. Mutations here will change the underlying element's
dictionary"""
+
def __init__(self, attrs, attrsNS):
self._attrs = attrs
self._attrsNS = attrsNS
! self.length = len(self._attrs)

def item(self, index):
***************
*** 208,217 ****

def items(self):
! return map(lambda node: (node.tagName, node.value),
! self._attrs.values())

def itemsNS(self):
! return map(lambda node: ((node.URI, node.localName), node.value),
! self._attrs.values())

def keys(self):
--- 271,284 ----

def items(self):
! L = []
! for node in self._attrs.values():
! L.append((node.tagName, node.value))
! return L

def itemsNS(self):
! L = []
! for node in self._attrs.values():
! L.append(((node.URI, node.localName), node.value))
! return L

def keys(self):
***************
*** 235,239 ****
#FIXME: is it appropriate to return .value?
def __getitem__(self, attname_or_tuple):
! if type(attname_or_tuple) is types.TupleType:
return self._attrsNS[attname_or_tuple]
else:
--- 302,306 ----
#FIXME: is it appropriate to return .value?
def __getitem__(self, attname_or_tuple):
! if type(attname_or_tuple) is _TupleType:
return self._attrsNS[attname_or_tuple]
else:
***************
*** 242,250 ****
# same as set
def __setitem__(self, attname, value):
! if type(value) is types.StringType:
node = Attr(attname)
! node.value=value
else:
! assert isinstance(value, Attr) or type(value) is types.StringType
node = value
old = self._attrs.get(attname, None)
--- 309,318 ----
# same as set
def __setitem__(self, attname, value):
! if type(value) in _StringTypes:
node = Attr(attname)
! node.value = value
else:
! if not isinstance(value, Attr):
! raise TypeError, "value must be a string or Attr object"
node = value
old = self._attrs.get(attname, None)
***************
*** 262,265 ****
--- 330,335 ----
class Element(Node):
nodeType = Node.ELEMENT_NODE
+ nextSibling = None
+ previousSibling = None

def __init__(self, tagName, namespaceURI="", prefix="",
***************
*** 271,281 ****
self.namespaceURI = namespaceURI
self.nodeValue = None

! self._attrs={} # attributes are double-indexed:
! self._attrsNS={}# tagName -> Attribute
! # URI,localName -> Attribute
! # in the future: consider lazy generation of attribute objects
! # this is too tricky for now because of headaches
! # with namespaces.

def getAttribute(self, attname):
--- 341,370 ----
self.namespaceURI = namespaceURI
self.nodeValue = None
+
+ self._attrs = {} # attributes are double-indexed:
+ self._attrsNS = {} # tagName -> Attribute
+ # URI,localName -> Attribute
+ # in the future: consider lazy generation
+ # of attribute objects this is too tricky
+ # for now because of headaches with
+ # namespaces.

! def cloneNode(self, deep):
! clone = Node.cloneNode(self, deep)
! clone._attrs = {}
! clone._attrsNS = {}
! for attr in self._attrs.values():
! node = attr.cloneNode(1)
! clone._attrs[node.name] = node
! clone._attrsNS[(node.namespaceURI, node.localName)] = node
! node.ownerElement = clone
! return clone
!
! def unlink(self):
! for attr in self._attrs.values():
! attr.unlink()
! self._attrs = None
! self._attrsNS = None
! Node.unlink(self)

def getAttribute(self, attname):
***************
*** 297,301 ****
attr.__dict__["value"] = attr.__dict__["nodeValue"] = value
self.setAttributeNode(attr)
- # FIXME: return original node if something changed.

def getAttributeNode(self, attrname):
--- 386,389 ----
***************
*** 306,309 ****
--- 394,399 ----

def setAttributeNode(self, attr):
+ if attr.ownerElement not in (None, self):
+ raise ValueError, "attribute node already owned"
old = self._attrs.get(attr.name, None)
if old:
***************
*** 311,315 ****
self._attrs[attr.name] = attr
self._attrsNS[(attr.namespaceURI, attr.localName)] = attr
! # FIXME: return old value if something changed

def removeAttribute(self, name):
--- 401,414 ----
self._attrs[attr.name] = attr
self._attrsNS[(attr.namespaceURI, attr.localName)] = attr
!
! # This creates a circular reference, but Element.unlink()
! # breaks the cycle since the references to the attribute
! # dictionaries are tossed.
! attr.ownerElement = self
!
! if old is not attr:
! # It might have already been part of this node, in which case
! # it doesn't represent a change, and should not be returned.
! return old

def removeAttribute(self, name):
***************
*** 335,348 ****
return "<DOM Element: %s at %s>" % (self.tagName, id(self))

- # undocumented
def writexml(self, writer):
writer.write("<" + self.tagName)

! a_names = self._get_attributes().keys()
a_names.sort()

for a_name in a_names:
writer.write(" %s=\"" % a_name)
! _write_data(writer, self._get_attributes()[a_name].value)
writer.write("\"")
if self.childNodes:
--- 434,447 ----
return "<DOM Element: %s at %s>" % (self.tagName, id(self))

def writexml(self, writer):
writer.write("<" + self.tagName)

! attrs = self._get_attributes()
! a_names = attrs.keys()
a_names.sort()

for a_name in a_names:
writer.write(" %s=\"" % a_name)
! _write_data(writer, attrs[a_name].value)
writer.write("\"")
if self.childNodes:
***************
*** 359,368 ****
class Comment(Node):
nodeType = Node.COMMENT_NODE

def __init__(self, data):
Node.__init__(self)
self.data = self.nodeValue = data
- self.nodeName = "#comment"
- self.attributes = None

def writexml(self, writer):
--- 458,467 ----
class Comment(Node):
nodeType = Node.COMMENT_NODE
+ nodeName = "#comment"
+ attributes = None

def __init__(self, data):
Node.__init__(self)
self.data = self.nodeValue = data

def writexml(self, writer):
***************
*** 371,374 ****
--- 470,474 ----
class ProcessingInstruction(Node):
nodeType = Node.PROCESSING_INSTRUCTION_NODE
+ attributes = None

def __init__(self, target, data):
***************
*** 376,380 ****
self.target = self.nodeName = target
self.data = self.nodeValue = data
- self.attributes = None

def writexml(self, writer):
--- 476,479 ----
***************
*** 384,392 ****
nodeType = Node.TEXT_NODE
nodeName = "#text"

def __init__(self, data):
Node.__init__(self)
self.data = self.nodeValue = data
- self.attributes = None

def __repr__(self):
--- 483,491 ----
nodeType = Node.TEXT_NODE
nodeName = "#text"
+ attributes = None

def __init__(self, data):
Node.__init__(self)
self.data = self.nodeValue = data

def __repr__(self):
***************
*** 401,406 ****

def _nssplit(qualifiedName):
! import string
! fields = string.split(qualifiedName,':', 1)
if len(fields) == 2:
return fields
--- 500,504 ----

def _nssplit(qualifiedName):
! fields = _string.split(qualifiedName, ':', 1)
if len(fields) == 2:
return fields
***************
*** 410,421 ****
class Document(Node):
nodeType = Node.DOCUMENT_NODE
documentElement = None

- def __init__(self):
- Node.__init__(self)
- self.attributes = None
- self.nodeName = "#document"
- self.nodeValue = None
-
def appendChild(self, node):
if node.nodeType == Node.ELEMENT_NODE:
--- 508,516 ----
class Document(Node):
nodeType = Node.DOCUMENT_NODE
+ nodeName = "#document"
+ nodeValue = None
+ attributes = None
documentElement = None

def appendChild(self, node):
if node.nodeType == Node.ELEMENT_NODE:
***************
*** 424,429 ****
else:
self.documentElement = node
! Node.appendChild(self, node)
! return node

createElement = Element
--- 519,523 ----
else:
self.documentElement = node
! return Node.appendChild(self, node)

createElement = Element
***************
*** 438,447 ****

def createElementNS(self, namespaceURI, qualifiedName):
! prefix,localName = _nssplit(qualifiedName)
! return Element(qualifiedName, namespaceURI, prefix, localName)

def createAttributeNS(self, namespaceURI, qualifiedName):
! prefix,localName = _nssplit(qualifiedName)
! return Attr(qualifiedName, namespaceURI, localName, prefix)

def getElementsByTagNameNS(self, namespaceURI, localName):
--- 532,543 ----

def createElementNS(self, namespaceURI, qualifiedName):
! prefix, localName = _nssplit(qualifiedName)
! return self.createElement(qualifiedName, namespaceURI,
! prefix, localName)

def createAttributeNS(self, namespaceURI, qualifiedName):
! prefix, localName = _nssplit(qualifiedName)
! return self.createAttribute(qualifiedName, namespaceURI,
! localName, prefix)

def getElementsByTagNameNS(self, namespaceURI, localName):
***************
*** 461,464 ****
--- 557,567 ----
node.writexml(writer)

+ def _get_StringIO():
+ try:
+ from cStringIO import StringIO
+ except ImportError:
+ from StringIO import StringIO
+ return StringIO()
+
def _doparse(func, args, kwargs):
events = apply(func, args, kwargs)
***************
*** 469,475 ****
--- 572,580 ----
def parse(*args, **kwargs):
"Parse a file into a DOM by filename or file object"
+ from xml.dom import pulldom
return _doparse(pulldom.parse, args, kwargs)

def parseString(*args, **kwargs):
"Parse a file into a DOM from a string"
+ from xml.dom import pulldom
return _doparse(pulldom.parseString, args, kwargs)



From python-dev@python.org Tue Nov 21 22:02:46 2000
From: python-dev@python.org (Fred L. Drake)
Date: Tue, 21 Nov 2000 14:02:46 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib/test test_minidom.py,1.14,1.15
Message-ID: <200011212202.OAA16258@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib/test
In directory slayer.i.sourceforge.net:/tmp/cvs-serv16231/Lib/test

Modified Files:
test_minidom.py
Log Message:
testInsertBefore(): Rewritten to actually test insertBefore() somewhat.

testAAA(),
testAAB(): Added checks that the results are right.

testTooManyDocumentElements(): Added code to actually test this.

testCloneElementDeep()
testCloneElementShallow(): Filled these in with test code.

_testCloneElementCopiesAttributes(),
_setupCloneElement(): Helper functions used with the other
testCloneElement*() functions.

testCloneElementShallowCopiesAttributes(): No longer a separate test;
_setupCloneElement() uses _testCloneElementCopiesAttributes() to
test that this is always done.

testNormalize(): Added to check Node.normalize().


Index: test_minidom.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/test/test_minidom.py,v
retrieving revision 1.14
retrieving revision 1.15
diff -C2 -r1.14 -r1.15
*** test_minidom.py 2000/10/23 17:22:07 1.14
--- test_minidom.py 2000/11/21 22:02:43 1.15
***************
*** 38,51 ****

def testInsertBefore():
! dom = parse(tstfile)
! docel = dom.documentElement
! #docel.insertBefore( dom.createProcessingInstruction("a", "b"),
! # docel.childNodes[1])
!
! #docel.insertBefore( dom.createProcessingInstruction("a", "b"),
! # docel.childNodes[0])
!
! #confirm( docel.childNodes[0].tet == "a")
! #confirm( docel.childNodes[2].tet == "a")
dom.unlink()

--- 38,71 ----

def testInsertBefore():
! dom = parseString("<doc><foo/></doc>")
! root = dom.documentElement
! elem = root.childNodes[0]
! nelem = dom.createElement("element")
! root.insertBefore(nelem, elem)
! confirm(len(root.childNodes) == 2
! and root.childNodes[0] is nelem
! and root.childNodes[1] is elem
! and root.firstChild is nelem
! and root.lastChild is elem
! and root.toxml() == "<doc><element/><foo/></doc>"
! , "testInsertBefore -- node properly placed in tree")
! nelem = dom.createElement("element")
! root.insertBefore(nelem, None)
! confirm(len(root.childNodes) == 3
! and root.childNodes[1] is elem
! and root.childNodes[2] is nelem
! and root.lastChild is nelem
! and nelem.previousSibling is elem
! and root.toxml() == "<doc><element/><foo/><element/></doc>"
! , "testInsertBefore -- node properly placed in tree")
! nelem2 = dom.createElement("bar")
! root.insertBefore(nelem2, nelem)
! confirm(len(root.childNodes) == 4
! and root.childNodes[2] is nelem2
! and root.childNodes[3] is nelem
! and nelem2.nextSibling is nelem
! and nelem.previousSibling is nelem2
! and root.toxml() == "<doc><element/><foo/><bar/><element/></doc>"
! , "testInsertBefore -- node properly placed in tree")
dom.unlink()

***************
*** 78,81 ****
--- 98,102 ----
el = dom.documentElement
el.setAttribute("spam", "jam2")
+ confirm(el.toxml() == '<abc spam="jam2"/>', "testAAA")
dom.unlink()

***************
*** 85,88 ****
--- 106,110 ----
el.setAttribute("spam", "jam")
el.setAttribute("spam", "jam2")
+ confirm(el.toxml() == '<abc spam="jam2"/>', "testAAB")
dom.unlink()

***************
*** 243,247 ****
def testDocumentElement(): pass

! def testTooManyDocumentElements(): pass

def testCreateElementNS(): pass
--- 265,280 ----
def testDocumentElement(): pass

! def testTooManyDocumentElements():
! doc = parseString("<doc/>")
! elem = doc.createElement("extra")
! try:
! doc.appendChild(elem)
! except TypeError:
! print "Caught expected exception when adding extra document element."
! else:
! print "Failed to catch expected exception when" \
! " adding extra document element."
! elem.unlink()
! doc.unlink()

def testCreateElementNS(): pass
***************
*** 291,300 ****
def testHasChildNodes(): pass

! def testCloneElementShallow(): pass

- def testCloneElementShallowCopiesAttributes(): pass
-
- def testCloneElementDeep(): pass
-
def testCloneDocumentShallow(): pass

--- 324,376 ----
def testHasChildNodes(): pass

! def testCloneElementShallow():
! dom, clone = _setupCloneElement(0)
! confirm(len(clone.childNodes) == 0
! and clone.parentNode is None
! and clone.toxml() == '<doc attr="value"/>'
! , "testCloneElementShallow")
! dom.unlink()
!
! def testCloneElementDeep():
! dom, clone = _setupCloneElement(1)
! confirm(len(clone.childNodes) == 1
! and clone.parentNode is None
! and clone.toxml() == '<doc attr="value"><foo/></doc>'
! , "testCloneElementDeep")
! dom.unlink()
!
! def _setupCloneElement(deep):
! dom = parseString("<doc attr='value'><foo/></doc>")
! root = dom.documentElement
! clone = root.cloneNode(deep)
! _testCloneElementCopiesAttributes(
! root, clone, "testCloneElement" + (deep and "Deep" or "Shallow"))
! # mutilate the original so shared data is detected
! root.tagName = root.nodeName = "MODIFIED"
! root.setAttribute("attr", "NEW VALUE")
! root.setAttribute("added", "VALUE")
! return dom, clone
!
! def _testCloneElementCopiesAttributes(e1, e2, test):
! attrs1 = e1.attributes
! attrs2 = e2.attributes
! keys1 = attrs1.keys()
! keys2 = attrs2.keys()
! keys1.sort()
! keys2.sort()
! confirm(keys1 == keys2, "clone of element has same attribute keys")
! for i in range(len(keys1)):
! a1 = attrs1.item(i)
! a2 = attrs2.item(i)
! confirm(a1 is not a2
! and a1.value == a2.value
! and a1.nodeValue == a2.nodeValue
! and a1.namespaceURI == a2.namespaceURI
! and a1.localName == a2.localName
! , "clone of attribute node has proper attribute values")
! confirm(a2.ownerElement is e2,
! "clone of attribute node correctly owned")
!

def testCloneDocumentShallow(): pass

***************
*** 308,311 ****
--- 384,400 ----

def testClonePIDeep(): pass
+
+ def testNormalize():
+ doc = parseString("<doc/>")
+ root = doc.documentElement
+ root.appendChild(doc.createTextNode("first"))
+ root.appendChild(doc.createTextNode("second"))
+ confirm(len(root.childNodes) == 2, "testNormalize -- preparation")
+ doc.normalize()
+ confirm(len(root.childNodes) == 1
+ and root.firstChild is root.lastChild
+ and root.firstChild.data == "firstsecond"
+ , "testNormalize -- result")
+ doc.unlink()

def testSiblings():



From python-dev@python.org Tue Nov 21 22:03:11 2000
From: python-dev@python.org (Fred L. Drake)
Date: Tue, 21 Nov 2000 14:03:11 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib/test/output test_minidom,1.9,1.10
Message-ID: <200011212203.OAA16344@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib/test/output
In directory slayer.i.sourceforge.net:/tmp/cvs-serv16334/Lib/test/output

Modified Files:
test_minidom
Log Message:

Update test output.


Index: test_minidom
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/test/output/test_minidom,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -r1.9 -r1.10
*** test_minidom 2000/10/13 20:54:10 1.9
--- test_minidom 2000/11/21 22:03:09 1.10
***************
*** 1,5 ****
--- 1,7 ----
test_minidom
+ Passed testAAA
Test Succeeded testAAA
Passed assertion: len(Node.allnodes) == 0
+ Passed testAAB
Test Succeeded testAAB
Passed assertion: len(Node.allnodes) == 0
***************
*** 57,66 ****
Test Succeeded testCloneDocumentShallow
Passed assertion: len(Node.allnodes) == 0
Test Succeeded testCloneElementDeep
Passed assertion: len(Node.allnodes) == 0
Test Succeeded testCloneElementShallow
Passed assertion: len(Node.allnodes) == 0
- Test Succeeded testCloneElementShallowCopiesAttributes
- Passed assertion: len(Node.allnodes) == 0
Test Succeeded testClonePIDeep
Passed assertion: len(Node.allnodes) == 0
--- 59,74 ----
Test Succeeded testCloneDocumentShallow
Passed assertion: len(Node.allnodes) == 0
+ Passed clone of element has same attribute keys
+ Passed clone of attribute node has proper attribute values
+ Passed clone of attribute node correctly owned
+ Passed testCloneElementDeep
Test Succeeded testCloneElementDeep
Passed assertion: len(Node.allnodes) == 0
+ Passed clone of element has same attribute keys
+ Passed clone of attribute node has proper attribute values
+ Passed clone of attribute node correctly owned
+ Passed testCloneElementShallow
Test Succeeded testCloneElementShallow
Passed assertion: len(Node.allnodes) == 0
Test Succeeded testClonePIDeep
Passed assertion: len(Node.allnodes) == 0
***************
*** 109,112 ****
--- 117,123 ----
Test Succeeded testHasChildNodes
Passed assertion: len(Node.allnodes) == 0
+ Passed testInsertBefore -- node properly placed in tree
+ Passed testInsertBefore -- node properly placed in tree
+ Passed testInsertBefore -- node properly placed in tree
Test Succeeded testInsertBefore
Passed assertion: len(Node.allnodes) == 0
***************
*** 115,118 ****
--- 126,133 ----
Test Succeeded testNonZero
Passed assertion: len(Node.allnodes) == 0
+ Passed testNormalize -- preparation
+ Passed testNormalize -- result
+ Test Succeeded testNormalize
+ Passed assertion: len(Node.allnodes) == 0
Passed testParents
Test Succeeded testParents
***************
*** 164,167 ****
--- 179,183 ----
Test Succeeded testTextRepr
Passed assertion: len(Node.allnodes) == 0
+ Caught expected exception when adding extra document element.
Test Succeeded testTooManyDocumentElements
Passed assertion: len(Node.allnodes) == 0



From python-dev@python.org Wed Nov 22 16:06:19 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 22 Nov 2000 08:06:19 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/dist dist.tex,1.28,1.29
Message-ID: <200011221606.IAA00321@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/dist
In directory slayer.i.sourceforge.net:/tmp/cvs-serv305/dist

Modified Files:
dist.tex
Log Message:

Do not use \verb in the Python documentation -- it makes parsing the LaTeX
sources more difficult and other tools do not always work well with it.
Since we have better markup for this case, just fix it.


Index: dist.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/dist/dist.tex,v
retrieving revision 1.28
retrieving revision 1.29
diff -C2 -r1.28 -r1.29
*** dist.tex 2000/10/26 21:13:22 1.28
--- dist.tex 2000/11/22 16:06:16 1.29
***************
*** 606,612 ****
options that command supports. Any number of options can be supplied
for each command, and any number of command sections can be included in
! the file. Blank lines are ignored, as are comments (from a \verb+#+
! character to end-of-line). Long option values can be split across
! multiple lines simply by indenting the continuation lines.

You can find out the list of options supported by a particular command
--- 606,612 ----
options that command supports. Any number of options can be supplied
for each command, and any number of command sections can be included in
! the file. Blank lines are ignored, as are comments (from a
! \character{\#} character to end-of-line). Long option values can be
! split across multiple lines simply by indenting the continuation lines.

You can find out the list of options supported by a particular command



From python-dev@python.org Wed Nov 22 16:42:45 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 22 Nov 2000 08:42:45 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/mac .cvsignore,1.1,1.2
Message-ID: <200011221642.IAA05032@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/mac
In directory slayer.i.sourceforge.net:/tmp/cvs-serv4991/mac

Modified Files:
.cvsignore
Log Message:

Updates to reflect pending changes to the XML conversion process.


Index: .cvsignore
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/mac/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** .cvsignore 1998/12/01 18:58:24 1.1
--- .cvsignore 2000/11/22 16:42:37 1.2
***************
*** 1,3 ****
*.esis
! *.sgml
*.xml
--- 1,3 ----
*.esis
! *.esis1
*.xml



From python-dev@python.org Wed Nov 22 16:42:45 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 22 Nov 2000 08:42:45 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/ref .cvsignore,1.4,1.5
Message-ID: <200011221642.IAA05031@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/ref
In directory slayer.i.sourceforge.net:/tmp/cvs-serv4991/ref

Modified Files:
.cvsignore
Log Message:

Updates to reflect pending changes to the XML conversion process.


Index: .cvsignore
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/ref/.cvsignore,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -r1.4 -r1.5
*** .cvsignore 1998/12/01 18:58:26 1.4
--- .cvsignore 2000/11/22 16:42:37 1.5
***************
*** 1,3 ****
*.esis
! *.sgml
*.xml
--- 1,3 ----
*.esis
! *.esis1
*.xml



From python-dev@python.org Wed Nov 22 16:42:45 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 22 Nov 2000 08:42:45 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/ext .cvsignore,1.1,1.2
Message-ID: <200011221642.IAA05029@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/ext
In directory slayer.i.sourceforge.net:/tmp/cvs-serv4991/ext

Modified Files:
.cvsignore
Log Message:

Updates to reflect pending changes to the XML conversion process.


Index: .cvsignore
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/ext/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** .cvsignore 1998/12/01 18:58:18 1.1
--- .cvsignore 2000/11/22 16:42:36 1.2
***************
*** 1,3 ****
*.esis
! *.sgml
*.xml
--- 1,3 ----
*.esis
! *.esis1
*.xml



From python-dev@python.org Wed Nov 22 16:42:45 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 22 Nov 2000 08:42:45 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib .cvsignore,1.1,1.2
Message-ID: <200011221642.IAA05030@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv4991/lib

Modified Files:
.cvsignore
Log Message:

Updates to reflect pending changes to the XML conversion process.


Index: .cvsignore
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** .cvsignore 1998/12/01 18:58:21 1.1
--- .cvsignore 2000/11/22 16:42:37 1.2
***************
*** 1,3 ****
*.esis
! *.sgml
*.xml
--- 1,3 ----
*.esis
! *.esis1
*.xml



From python-dev@python.org Wed Nov 22 16:42:45 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 22 Nov 2000 08:42:45 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/api .cvsignore,1.1,1.2
Message-ID: <200011221642.IAA05033@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/api
In directory slayer.i.sourceforge.net:/tmp/cvs-serv4991/api

Modified Files:
.cvsignore
Log Message:

Updates to reflect pending changes to the XML conversion process.


Index: .cvsignore
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/api/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** .cvsignore 1998/12/01 18:58:15 1.1
--- .cvsignore 2000/11/22 16:42:36 1.2
***************
*** 1,3 ****
*.esis
! *.sgml
*.xml
--- 1,3 ----
*.esis
! *.esis1
*.xml



From python-dev@python.org Wed Nov 22 16:42:46 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 22 Nov 2000 08:42:46 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/tut .cvsignore,1.1,1.2
Message-ID: <200011221642.IAA05036@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/tut
In directory slayer.i.sourceforge.net:/tmp/cvs-serv4991/tut

Modified Files:
.cvsignore
Log Message:

Updates to reflect pending changes to the XML conversion process.


Index: .cvsignore
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/tut/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** .cvsignore 1998/12/01 18:58:28 1.1
--- .cvsignore 2000/11/22 16:42:37 1.2
***************
*** 1,3 ****
*.esis
! *.sgml
*.xml
--- 1,3 ----
*.esis
! *.esis1
*.xml



From python-dev@python.org Wed Nov 22 16:42:46 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 22 Nov 2000 08:42:46 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/dist .cvsignore,NONE,1.1
Message-ID: <200011221642.IAA05037@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/dist
In directory slayer.i.sourceforge.net:/tmp/cvs-serv4991/dist

Added Files:
.cvsignore
Log Message:

Updates to reflect pending changes to the XML conversion process.


--- NEW FILE ---
*.esis
*.esis1
*.xml



From python-dev@python.org Wed Nov 22 16:45:22 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 22 Nov 2000 08:45:22 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/tools/sgmlconv conversion.xml,1.9,1.10
Message-ID: <200011221645.IAA05213@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/tools/sgmlconv
In directory slayer.i.sourceforge.net:/tmp/cvs-serv5200

Modified Files:
conversion.xml
Log Message:

Add support for (relatively) recent additions and changes to python.sty,
and one more standard LaTeX macro.


Index: conversion.xml
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/tools/sgmlconv/conversion.xml,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -r1.9 -r1.10
*** conversion.xml 2000/11/17 19:05:12 1.9
--- conversion.xml 2000/11/22 16:45:19 1.10
***************
*** 46,52 ****
--- 46,57 ----
<attribute name="email"/>
</macro>
+ <macro name="shortversion"/>
<macro name="versionadded">
<attribute name="version"/>
</macro>
+ <!-- This is broken: we need to re-order the optional and required
+ parameters, making the optional parameter the content for the
+ element. The processor is not powerful enough to handle this.
+ -->
<macro name="versionchanged">
<attribute name="version"/>
***************
*** 68,71 ****
--- 73,77 ----
</environment>
<environment name="ctypedesc">
+ <attribute name="tag" optional="yes"/>
<attribute name="name"/>
</environment>
***************
*** 153,161 ****
<attribute name="ref" optional="yes"/>
<attribute name="name"/>
! <content/>
</macro>
<macro name="seetext">
! <content/>
</macro>

<!-- Index-generating markup. -->
--- 159,186 ----
<attribute name="ref" optional="yes"/>
<attribute name="name"/>
! <child name="description"/>
! </macro>
! <macro name="seepep">
! <attribute name="number"/>
! <child name="title"/>
! <child name="description"/>
! </macro>
! <macro name="seerfc">
! <attribute name="number"/>
! <child name="title"/>
! <child name="description"/>
</macro>
<macro name="seetext">
! <child name="description"/>
! </macro>
! <macro name="seetitle">
! <attribute name="href" optional="yes"/>
! <child name="title"/>
! <child name="description"/>
</macro>
+ <macro name="seeurl">
+ <attribute name="href"/>
+ <child name="description"/>
+ </macro>

<!-- Index-generating markup. -->
***************
*** 670,673 ****
--- 695,701 ----
<macro name="UNIX" outputname="">
<text>Unix</text>
+ </macro>
+ <macro name="textasciitilde" outputname="">
+ <text>~</text>
</macro>




From python-dev@python.org Wed Nov 22 16:54:22 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 22 Nov 2000 08:54:22 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/tools/sgmlconv Makefile,1.7,1.8 make.rules,1.8,1.9
Message-ID: <200011221654.IAA06015@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/tools/sgmlconv
In directory slayer.i.sourceforge.net:/tmp/cvs-serv6003

Modified Files:
Makefile make.rules
Log Message:

Update the rules to separate the two phases for the ESIS generation,
entirely so that debugging can be performed independently.


Index: Makefile
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/tools/sgmlconv/Makefile,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -r1.7 -r1.8
*** Makefile 1999/07/22 13:57:12 1.7
--- Makefile 2000/11/22 16:54:20 1.8
***************
*** 1,3 ****
! # Simple makefile to control SGML generation for the entire document tree.
# This should be used from the top-level directory (Doc/), not the directory
# that actually contains this file:
--- 1,3 ----
! # Simple makefile to control XML generation for the entire document tree.
# This should be used from the top-level directory (Doc/), not the directory
# that actually contains this file:
***************
*** 11,26 ****

SGMLRULES=../$(TOOLSDIR)/sgmlconv/make.rules
! SUBDIRS=api ext lib mac ref tut
SUBMAKE=$(MAKE) -f $(SGMLRULES) TOOLSDIR=../$(TOOLSDIR)

all: xml

! .PHONY: sgml xml
.PHONY: $(SUBDIRS)

- sgml:
- for DIR in $(SUBDIRS) ; do \
- (cd $$DIR; $(SUBMAKE) sgml) || exit $$? ; done
-
xml:
for DIR in $(SUBDIRS) ; do \
--- 11,23 ----

SGMLRULES=../$(TOOLSDIR)/sgmlconv/make.rules
! # The 'inst' directory breaks the conversion, so skip it for now.
! SUBDIRS=api dist ext lib mac ref tut
SUBMAKE=$(MAKE) -f $(SGMLRULES) TOOLSDIR=../$(TOOLSDIR)

all: xml

! .PHONY: esis xml
.PHONY: $(SUBDIRS)

xml:
for DIR in $(SUBDIRS) ; do \
***************
*** 30,42 ****
for DIR in $(SUBDIRS) ; do \
(cd $$DIR; $(SUBMAKE) esis) || exit $$? ; done

! tarball: sgml
! tar cf - sgml tools/sgmlconv */*.sgml | gzip -9 >sgml-1.5.2b2.tgz

api:
cd api; $(SUBMAKE)

ext:
cd ext; $(SUBMAKE)

lib:
--- 27,49 ----
for DIR in $(SUBDIRS) ; do \
(cd $$DIR; $(SUBMAKE) esis) || exit $$? ; done
+
+ esis1:
+ for DIR in $(SUBDIRS) ; do \
+ (cd $$DIR; $(SUBMAKE) esis1) || exit $$? ; done

! tarball: xml
! tar cf - tools/sgmlconv */*.xml | gzip -9 >xml-1.5.2b2.tgz

api:
cd api; $(SUBMAKE)

+ dist:
+ cd dist; $(SUBMAKE)
+
ext:
cd ext; $(SUBMAKE)
+
+ inst:
+ cd inst; $(SUBMAKE)

lib:

Index: make.rules
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/tools/sgmlconv/make.rules,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -r1.8 -r1.9
*** make.rules 1999/08/26 17:57:18 1.8
--- make.rules 2000/11/22 16:54:20 1.9
***************
*** 1,5 ****
# -*- makefile -*-
#
! # Extra magic needed by the LaTeX->SGML conversion process. This requires
# $(TOOLSDIR) to be properly defined.

--- 1,5 ----
# -*- makefile -*-
#
! # Extra magic needed by the LaTeX->XML conversion process. This requires
# $(TOOLSDIR) to be properly defined.

***************
*** 10,14 ****

ESISTARGETS= $(patsubst %.tex,%.esis,$(wildcard *.tex))
! SGMLTARGETS= $(patsubst %.tex,%.sgml,$(wildcard *.tex))
XMLTARGETS= $(patsubst %.tex,%.xml,$(wildcard *.tex))

--- 10,14 ----

ESISTARGETS= $(patsubst %.tex,%.esis,$(wildcard *.tex))
! ESIS1TARGETS= $(patsubst %.tex,%.esis1,$(wildcard *.tex))
XMLTARGETS= $(patsubst %.tex,%.xml,$(wildcard *.tex))

***************
*** 18,22 ****

esis: $(ESISTARGETS)
! sgml: $(SGMLTARGETS)
xml: $(XMLTARGETS)

--- 18,22 ----

esis: $(ESISTARGETS)
! esis1: $(ESIS1TARGETS)
xml: $(XMLTARGETS)

***************
*** 24,42 ****

$(ESISTARGETS): $(LATEX2ESIS) $(DOCFIXER) $(ESISTOOLS) $(CONVERSION)
# This variant is easier to work with while debugging the conversion spec:
#$(ESISTARGETS): $(LATEX2ESIS) $(DOCFIXER) $(ESISTOOLS)
- $(SGMLTARGETS): $(ESIS2ML)
$(XMLTARGETS): $(ESIS2ML)


! .SUFFIXES: .esis .sgml .tex .xml

! .tex.esis:
! $(LATEX2ESIS) $(L2EFLAGS) $< temp.esis
! $(DOCFIXER) temp.esis $@
! rm temp.esis

! .esis.sgml:
! $(ESIS2ML) --sgml --autoclose para $< $@

.esis.xml:
--- 24,40 ----

$(ESISTARGETS): $(LATEX2ESIS) $(DOCFIXER) $(ESISTOOLS) $(CONVERSION)
+ $(ESIS1TARGETS): $(LATEX2ESIS) $(CONVERSION)
# This variant is easier to work with while debugging the conversion spec:
#$(ESISTARGETS): $(LATEX2ESIS) $(DOCFIXER) $(ESISTOOLS)
$(XMLTARGETS): $(ESIS2ML)


! .SUFFIXES: .esis .esis1 .tex .xml

! .tex.esis1:
! $(LATEX2ESIS) $(L2EFLAGS) $< $@

! .esis1.esis:
! $(DOCFIXER) $< $@

.esis.xml:
***************
*** 45,50 ****

clean:
! rm -f *.esis

clobber: clean
! rm -f *.sgml *.xml
--- 43,48 ----

clean:
! rm -f *.esis *.esis1

clobber: clean
! rm -f *.xml



From python-dev@python.org Wed Nov 22 16:58:27 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 22 Nov 2000 08:58:27 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/tools/sgmlconv README,1.5,1.6
Message-ID: <200011221658.IAA06400@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/tools/sgmlconv
In directory slayer.i.sourceforge.net:/tmp/cvs-serv6393

Modified Files:
README
Log Message:

Update to reflect the process changes.
Remove the SGML aspects; there's too much XML momentum to worry about
the SGML flavor at this point.



Index: README
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/tools/sgmlconv/README,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -r1.5 -r1.6
*** README 1999/08/26 18:08:13 1.5
--- README 2000/11/22 16:58:25 1.6
***************
*** 1,19 ****
These scripts and Makefile fragment are used to convert the Python
! documentation in LaTeX format to SGML or XML. Though I originally
! thought that the XML was unlikely to be used, tool support for XML
! is increasing quickly enough that it may well be the final format.
! (It is the default output format when using the makefiles included
! here.)
!
! This material is preliminary and incomplete. The XML omnibus package
! developed by the Python XML-SIG is required; specifically, the version
! available in the public CVS repository. See
! http://www.python.org/sigs/xml-sig/ for more information on the
! package.

To convert all documents to XML:

cd Doc/
! make -f tools/sgmlconv/Makefile sgml

To convert one document to XML:
--- 1,11 ----
These scripts and Makefile fragment are used to convert the Python
! documentation in LaTeX format to XML.

+ This material is preliminary and incomplete. Python 2.0 is required.
+
To convert all documents to XML:

cd Doc/
! make -f tools/sgmlconv/Makefile

To convert one document to XML:
***************
*** 22,34 ****
make -f ../tools/sgmlconv/make.rules TOOLSDIR=../tools

- To generate SGML instead, use:
-
- cd Doc/<document-dir>
- make -f ../tools/sgmlconv/make.rules TOOLSDIR=../tools sgml
-
- Note that building the second target format is fast because both
- conversions use the same intermediate format (an ESIS event stream).
- This is true regardless of whether you build SGML or XML first.
-
Please send comments and bug reports to python-docs@python.org.

--- 14,17 ----
***************
*** 51,54 ****
--- 34,39 ----
the same level as the top-level content elements.

+ The output of latex2esis.py gets saved as <filename>.esis1.
+
docfixer.py
This is the really painful part of the conversion. Well, it's the
***************
*** 64,68 ****
After processing the fragment, a new ESIS data stream is written
out. Like the input, it may not represent a well-formed
! document.

The output of docfixer.py is what gets saved in <filename>.esis.
--- 49,53 ----
After processing the fragment, a new ESIS data stream is written
out. Like the input, it may not represent a well-formed
! document, but does represent a parsed entity.

The output of docfixer.py is what gets saved in <filename>.esis.



From python-dev@python.org Wed Nov 22 17:56:46 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 22 Nov 2000 09:56:46 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/tools/sgmlconv latex2esis.py,1.20,1.21
Message-ID: <200011221756.JAA12954@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/tools/sgmlconv
In directory slayer.i.sourceforge.net:/tmp/cvs-serv12942/tools/sgmlconv

Modified Files:
latex2esis.py
Log Message:

Convert the LaTeX "tie" (~) to a simple space.

Add support for some combining characters.

Remove unnecessary imports and dependencies on PyXML and esistools.


Index: latex2esis.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/tools/sgmlconv/latex2esis.py,v
retrieving revision 1.20
retrieving revision 1.21
diff -C2 -r1.20 -r1.21
*** latex2esis.py 1999/08/26 17:54:16 1.20
--- latex2esis.py 2000/11/22 17:56:43 1.21
***************
*** 17,21 ****
__version__ = '$Revision$'

- import copy
import errno
import getopt
--- 17,20 ----
***************
*** 23,31 ****
import re
import string
- import StringIO
import sys
import UserList

- from esistools import encode
from types import ListType, StringType, TupleType

--- 22,29 ----
import re
import string
import sys
import UserList
+ import xml.sax.saxutils

from types import ListType, StringType, TupleType

***************
*** 51,54 ****
--- 49,56 ----
LaTeXFormatError.__init__(self, msg)

+ def encode(s):
+ s = xml.sax.saxutils.escape(s)
+ return s.replace("\n", "\\n\n-")
+

_begin_env_rx = re.compile(r"[\\]begin{([^}]*)}")
***************
*** 56,60 ****
_begin_macro_rx = re.compile(r"[\\]([a-zA-Z]+[*]?) ?({|\s*\n?)")
_comment_rx = re.compile("%+ ?(.*)\n[ \t]*")
! _text_rx = re.compile(r"[^]%\\{}]+")
_optional_rx = re.compile(r"\s*[[]([^]]*)[]]")
# _parameter_rx is this complicated to allow {...} inside a parameter;
--- 58,62 ----
_begin_macro_rx = re.compile(r"[\\]([a-zA-Z]+[*]?) ?({|\s*\n?)")
_comment_rx = re.compile("%+ ?(.*)\n[ \t]*")
! _text_rx = re.compile(r"[^]~%\\{}]+")
_optional_rx = re.compile(r"\s*[[]([^]]*)[]]")
# _parameter_rx is this complicated to allow {...} inside a parameter;
***************
*** 113,116 ****
--- 115,121 ----
self.preamble = 1

+ def write_ordinal(self, ordinal):
+ self.write("-\\%%%d;\n" % ordinal)
+
def err_write(self, msg):
if DEBUG:
***************
*** 166,169 ****
--- 171,180 ----
# start of macro
macroname = m.group(1)
+ if macroname == "c":
+ # Ugh! This is a combining character...
+ endpos = m.end()
+ self.combining_char("c", line[endpos])
+ line = line[endpos + 1:]
+ continue
entry = self.get_entry(macroname)
if entry.verbatim:
***************
*** 291,294 ****
--- 302,310 ----
line = line[1:]
continue
+ if line[0] == "~":
+ # don't worry about the "tie" aspect of this command
+ line = line[1:]
+ self.write("- \n")
+ continue
if line[0] == "{":
stack.append("")
***************
*** 303,306 ****
--- 319,330 ----
line = line[2:]
continue
+ if line[:2] == r"\_":
+ line = "_" + line[2:]
+ continue
+ if line[:2] in (r"\'", r'\"'):
+ # combining characters...
+ self.combining_char(line[1], line[2])
+ line = line[3:]
+ continue
m = _text_rx.match(line)
if m:
***************
*** 332,335 ****
--- 356,371 ----
+ string.join(stack, ", "))
# otherwise we just ran out of input here...
+
+ # This is a really limited table of combinations, but it will have
+ # to do for now.
+ _combinations = {
+ ("c", "c"): 0x00E7,
+ ("'", "e"): 0x00E9,
+ ('"', "o"): 0x00F6,
+ }
+
+ def combining_char(self, prefix, char):
+ ordinal = self._combinations[(prefix, char)]
+ self.write("-\\%%%d;\n" % ordinal)

def start_macro(self, name):



From python-dev@python.org Wed Nov 22 17:59:35 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 22 Nov 2000 09:59:35 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/tools/sgmlconv latex2esis.py,1.21,1.22
Message-ID: <200011221759.JAA13313@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/tools/sgmlconv
In directory slayer.i.sourceforge.net:/tmp/cvs-serv13302/tools/sgmlconv

Modified Files:
latex2esis.py
Log Message:

Conversion.write_ordinal(): Not used, remove it.


Index: latex2esis.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/tools/sgmlconv/latex2esis.py,v
retrieving revision 1.21
retrieving revision 1.22
diff -C2 -r1.21 -r1.22
*** latex2esis.py 2000/11/22 17:56:43 1.21
--- latex2esis.py 2000/11/22 17:59:32 1.22
***************
*** 15,19 ****
to load an alternate table from an external file.
"""
- __version__ = '$Revision$'

import errno
--- 15,18 ----
***************
*** 114,120 ****
self.line = string.join(map(string.rstrip, ifp.readlines()), "\n")
self.preamble = 1
-
- def write_ordinal(self, ordinal):
- self.write("-\\%%%d;\n" % ordinal)

def err_write(self, msg):
--- 113,116 ----



From python-dev@python.org Wed Nov 22 19:17:08 2000
From: python-dev@python.org (Barry Warsaw)
Date: Wed, 22 Nov 2000 11:17:08 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0229.txt,NONE,1.1
Message-ID: <200011221917.LAA21433@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv21415

Added Files:
pep-0229.txt
Log Message:
PEP 229, Using Distutils to Build Python, Andrew Kuchling


--- NEW FILE ---
PEP: 229
Title: Using Distutils to Build Python
Version: $Revision: 1.1 $
Author: akuchlin@mems-exchange.org (A.M. Kuchling)
Status: Draft
Type: Standards
Created: 16-Nov-2000
Post-History:


Introduction

The Modules/Setup mechanism has some flaws:

* People have to remember to uncomment bits of Modules/Setup in
order to get all the possible modules.

* Moving Setup to a new version of Python is tedious; new modules
have been added, so you can't just copy the older version, but
have to reconcile the two versions.

* Users have to figure out where the needed libraries, such as
zlib, are installed.


Proposal

Use the Distutils to build the modules that come with Python.

The changes can be broken up into several pieces:

1. The Distutils needs some Python modules to be able to build
modules. Currently I believe the minimal list is posix, _sre,
and string.

These modules will have to be built before the Distutils can be
used, so they'll simply be hardwired into Modules/Makefile and
be automatically built.

2. A top-level setup.py script will be written that checks the
libraries installed on the system and compiles as many modules
as possible.

3. Modules/Setup will be kept and settings in it will override
setup.py's usual behavior, so you can disable a module known
to be buggy, or specify particular compilation or linker flags.
However, in the common case where setup.py works correctly,
everything in Setup will remain commented out. The other
Setup.* become unnecessary, since nothing will be generating
Setup automatically.


Unresolved Issues

Do we need to make it possible to disable the 3 hard-wired modules
without manually hacking the Makefiles? If yes, perhaps a
configure switch is sufficient.

The Distutils always compile modules as shared libraries. How do
we support compiling them statically into the resulting Python
binary?

makesetup and the other contents of $(LIBPL)/config need to be
preserved for compatibility with existing modules; for how many
versions do we need to keep them around?


Copyright

This document has been placed in the public domain.



Local Variables:
mode: indented-text
indent-tabs-mode: nil
End:



From python-dev@python.org Wed Nov 22 19:17:38 2000
From: python-dev@python.org (Barry Warsaw)
Date: Wed, 22 Nov 2000 11:17:38 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0000.txt,1.48,1.49
Message-ID: <200011221917.LAA21518@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv21506

Modified Files:
pep-0000.txt
Log Message:
PEP 229, Using Distutils to Build Python, Andrew Kuchling


Index: pep-0000.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0000.txt,v
retrieving revision 1.48
retrieving revision 1.49
diff -C2 -r1.48 -r1.49
*** pep-0000.txt 2000/11/08 06:23:35 1.48
--- pep-0000.txt 2000/11/22 19:17:36 1.49
***************
*** 38,41 ****
--- 38,42 ----
I 226 pep-0226.txt Python 2.1 Release Schedule Hylton
S 227 pep-0227.txt Statically Nested Scopes Hylton
+ S 229 pep-0229.txt Using Distutils to Build Python Kuchling

Pie-in-the-sky PEPs (not ready; may become active yet)
***************
*** 122,125 ****
--- 123,127 ----
S 227 pep-0227.txt Statically Nested Scopes Hylton
S 228 pep-0228.txt Reworking Python's Numeric Model Zadka
+ S 229 pep-0229.txt Using Distutils to Build Python Kuchling





From python-dev@python.org Wed Nov 22 22:01:50 2000
From: python-dev@python.org (Barry Warsaw)
Date: Wed, 22 Nov 2000 14:01:50 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0211.txt,1.3,1.4
Message-ID: <200011222201.OAA10433@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv10411

Modified Files:
pep-0211.txt
Log Message:
Greg's latest revision.


Index: pep-0211.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0211.txt,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** pep-0211.txt 2000/09/19 15:29:36 1.3
--- pep-0211.txt 2000/11/22 22:01:47 1.4
***************
*** 12,21 ****
Introduction

! This PEP describes a proposal to add linear algebra operators to
! Python 2.0. It discusses why such operators are desirable, and
! alternatives that have been considered and discarded. This PEP
! summarizes discussions held in mailing list forums, and provides
! URLs for further information, where appropriate. The CVS revision
! history of this file contains the definitive historical record.


--- 12,22 ----
Introduction

! This PEP describes a conservative proposal to add linear algebra
! operators to Python 2.0. It discusses why such operators are
! desirable, and why a minimalist approach should be adopted at this
! point. This PEP summarizes discussions held in mailing list
! forums, and provides URLs for further information, where
! appropriate. The CVS revision history of this file contains the
! definitive historical record.


***************
*** 23,83 ****

Add a single new infix binary operator '@' ("across"), and
! corresponding special methods "__across__()" and "__racross__()".
! This operator will perform mathematical matrix multiplication on
! NumPy arrays, and generate cross-products when applied to built-in
! sequence types. No existing operator definitions will be changed.


Background

! Computers were invented to do arithmetic, as was the first
! high-level programming language, Fortran. While Fortran was a
! great advance on its machine-level predecessors, there was still a
! very large gap between its syntax and the notation used by
! mathematicians. The most influential effort to close this gap was
! APL [1]:
!
! The language [APL] was invented by Kenneth E. Iverson while at
! Harvard University. The language, originally titled "Iverson
! Notation", was designed to overcome the inherent ambiguities
! and points of confusion found when dealing with standard
! mathematical notation. It was later described in 1962 in a
! book simply titled "A Programming Language" (hence APL).
! Towards the end of the sixties, largely through the efforts of
! IBM, the computer community gained its first exposure to
! APL. Iverson received the Turing Award in 1980 for this work.

APL's operators supported both familiar algebraic operations, such
as vector dot product and matrix multiplication, and a wide range
of structural operations, such as stitching vectors together to
! create arrays. Its notation was exceptionally cryptic: many of
! its symbols did not exist on standard keyboards, and expressions
! had to be read right to left.

! Most subsequent work on numerical languages, such as Fortran-90,
! MATLAB, and Mathematica, has tried to provide the power of APL
without the obscurity. Python's NumPy [2] has most of the
features that users of such languages expect, but these are
provided through named functions and methods, rather than
! overloaded operators. This makes NumPy clumsier than its
! competitors.

! One way to make NumPy more competitive is to provide greater
! syntactic support in Python itself for linear algebra. This
! proposal therefore examines the requirements that new linear
! algebra operators in Python must satisfy, and proposes a syntax
! and semantics for those operators.


Requirements

! The most important requirement is that there be minimal impact on
! the existing definition of Python. The proposal must not break
! existing programs, except possibly those that use NumPy.
!
! The second most important requirement is to be able to do both
! elementwise and mathematical matrix multiplication using infix
! notation. The nine cases that must be handled are:
5 6| * 9 = |45 54| MS: matrix-scalar multiplication
7 8| |63 72|
--- 24,91 ----

Add a single new infix binary operator '@' ("across"), and
! corresponding special methods "__across__()", "__racross__()", and
! "__iacross__()". This operator will perform mathematical matrix
! multiplication on NumPy arrays, and generate cross-products when
! applied to built-in sequence types. No existing operator
! definitions will be changed.


Background

! The first high-level programming language, Fortran, was invented
! to do arithmetic. While this is now just a small part of
! computing, there are still many programmers who need to express
! complex mathematical operations in code.
!
! The most influential of Fortran's successors was APL [1]. Its
! author, Kenneth Iverson, designed the language as a notation for
! expressing matrix algebra, and received the 1980 Turing Award for
! his work.

APL's operators supported both familiar algebraic operations, such
as vector dot product and matrix multiplication, and a wide range
of structural operations, such as stitching vectors together to
! create arrays. Even by programming's standards, APL is
! exceptionally cryptic: many of its symbols did not exist on
! standard keyboards, and expressions have to be read right to left.

! Most subsequent work numerical languages, such as Fortran-90,
! MATLAB, and Mathematica, have tried to provide the power of APL
without the obscurity. Python's NumPy [2] has most of the
features that users of such languages expect, but these are
provided through named functions and methods, rather than
! overloaded operators. This makes NumPy clumsier than most
! alternatives.

! The author of this PEP therefore consulted the developers of GNU
! Octave [3], an open source clone of MATLAB. When asked how
! important it was to have infix operators for matrix solution,
! Prof. James Rawlings replied [4]:
!
! I DON'T think it's a must have, and I do a lot of matrix
! inversion. I cannot remember if its A\b or b\A so I always
! write inv(A)*b instead. I recommend dropping \.
!
! Rawlings' feedback on other operators was similar. It is worth
! noting in this context that notations such as "/" and "\" for
! matrix solution were invented by programmers, not mathematicians,
! and have not been adopted by the latter.
!
! Based on this discussion, and feedback from classes at the US
! national laboratories and elsewhere, we recommend only adding a
! matrix multiplication operator to Python at this time. If there
! is significant user demand for syntactic support for other
! operations, these can be added in a later release.


Requirements

! The most important requirement is minimal impact on existing
! Python programs and users: the proposal must not break existing
! code (except possibly NumPy).

+ The second most important requirement is the ability to handle all
+ common cases cleanly and clearly. There are nine such cases:
+
5 6| * 9 = |45 54| MS: matrix-scalar multiplication
7 8| |63 72|
***************
*** 109,166 ****
Note that 1-dimensional vectors are treated as rows in VM, as
columns in MV, and as both in VD and VO. Both are special cases
! of 2-dimensional matrices (Nx1 and 1xN respectively). It may
! therefore be reasonable to define the new operator only for
! 2-dimensional arrays, and provide an easy (and efficient) way for
! users to convert 1-dimensional structures to 2-dimensional.
! Behavior of a new multiplication operator for built-in types may
! then:
!
! (a) be a parsing error (possible only if a constant is one of the
! arguments, since names are untyped in Python);
!
! (b) generate a runtime error; or
!
! (c) be derived by plausible extension from its behavior in the
! two-dimensional case.
!
! Third, syntactic support should be considered for three other
! operations:
!
! T
! (a) transposition: A => A[j, i] for A[i, j]
!
! -1
! (b) inverse: A => A' such that A' * A = I (the identity matrix)
!
! (c) solution: A/b => x such that A * x = b
! A\b => x such that x * A = b
!
! With regard to (c), it is worth noting that the two syntaxes used
! were invented by programmers, not mathematicians. Mathematicians
! do not have a standard, widely-used notation for matrix solution.
!
! It is also worth noting that dozens of matrix inversion and
! solution algorithms are widely used. MATLAB and its kin bind
! their inversion and/or solution operators to one which is
! reasonably robust in most cases, and require users to call
! functions or methods to access others.
!
! Fourth, confusion between Python's notation and those of MATLAB
! and Fortran-90 should be avoided. In particular, mathematical
! matrix multiplication (case MM) should not be represented as '.*',
! since:

(a) MATLAB uses prefix-'.' forms to mean 'elementwise', and raw
! forms to mean "mathematical" [4]; and

(b) even if the Python parser can be taught how to handle dotted
! forms, '1.*A' will still be visually ambiguous [4].

- One anti-requirement is that new operators are not needed for
- addition, subtraction, bitwise operations, and so on, since
- mathematicians already treat them elementwise.

!
! Proposal:

The meanings of all existing operators will be unchanged. In
--- 117,137 ----
Note that 1-dimensional vectors are treated as rows in VM, as
columns in MV, and as both in VD and VO. Both are special cases
! of 2-dimensional matrices (Nx1 and 1xN respectively). We will
! therefore define the new operator only for 2-dimensional arrays,
! and provide an easy (and efficient) way for users to treat
! 1-dimensional structures as 2-dimensional.
!
! Third, we must avoid confusion between Python's notation and those
! of MATLAB and Fortran-90. In particular, mathematical matrix
! multiplication (case MM) should not be represented as '.*', since:

(a) MATLAB uses prefix-'.' forms to mean 'elementwise', and raw
! forms to mean "mathematical"; and

(b) even if the Python parser can be taught how to handle dotted
! forms, '1.*A' will still be visually ambiguous.


! Proposal

The meanings of all existing operators will be unchanged. In
***************
*** 170,181 ****

A new operator '@' (pronounced "across") will be added to Python,
! along with two special methods, "__across__()" and
! "__racross__()", with the usual semantics.

NumPy will overload "@" to perform mathematical multiplication of
arrays where shapes permit, and to throw an exception otherwise.
! The matrix class's implementation of "@" will treat built-in
! sequence types as if they were column vectors. This takes care of
! the cases MM and MV.

An attribute "T" will be added to the NumPy array type, such that
--- 141,151 ----

A new operator '@' (pronounced "across") will be added to Python,
! along with special methods "__across__()", "__racross__()", and
! "__iacross__()", with the usual semantics.

NumPy will overload "@" to perform mathematical multiplication of
arrays where shapes permit, and to throw an exception otherwise.
! Its implementation of "@" will treat built-in sequence types as if
! they were column vectors. This takes care of the cases MM and MV.

An attribute "T" will be added to the NumPy array type, such that
***************
*** 205,224 ****
similar in spirit to NumPy's existing "newaxis" value.

! (Optional) When applied to sequences, the operator will return a
! list of tuples containing the cross-product of their elements in
! left-to-right order:
[1, 2] @ (3, 4)
! [(1, 3), (1, 4), (2, 3), (2, 4)]
[1, 2] @ (3, 4) @ (5, 6)
! [(1, 3, 5), (1, 3, 6),
(1, 4, 5), (1, 4, 6),
(2, 3, 5), (2, 3, 6),
! (2, 4, 5), (2, 4, 6)]

This will require the same kind of special support from the parser
! as chained comparisons (such as "a<b<c<=d"). However, it would
! permit the following:
for (i, j) in [1, 2] @ [3, 4]:
--- 175,194 ----
similar in spirit to NumPy's existing "newaxis" value.

! (Optional) When applied to sequences, the "@" operator will return
! a tuple of tuples containing the cross-product of their elements
! in left-to-right order:
[1, 2] @ (3, 4)
! ((1, 3), (1, 4), (2, 3), (2, 4))
[1, 2] @ (3, 4) @ (5, 6)
! ((1, 3, 5), (1, 3, 6),
(1, 4, 5), (1, 4, 6),
(2, 3, 5), (2, 3, 6),
! (2, 4, 5), (2, 4, 6))

This will require the same kind of special support from the parser
! as chained comparisons (such as "a<b<c<=d"). However, it will
! permit:
for (i, j) in [1, 2] @ [3, 4]:
***************
*** 240,282 ****
as implementing single-stage nesting).


! Alternatives:

! 01. Don't add new operators --- stick to functions and methods.

! Python is not primarily a numerical language. It is not worth
! complexifying the language for this special case --- NumPy's
! success is proof that users can and will use functions and methods
! for linear algebra.
!
! On the positive side, this maintains Python's simplicity. Its
! weakness is that support for real matrix multiplication (and, to a
! lesser extent, other linear algebra operations) is frequently
! requested, as functional forms are cumbersome for lengthy
! formulas, and do not respect the operator precedence rules of
! conventional mathematics. In addition, the method form is
! asymmetric in its operands.
!
! 02. Introduce prefixed forms of existing operators, such as "@*"
! or "~*", or used boxed forms, such as "[*]" or "%*%".
!
! There are (at least) three objections to this. First, either form
! seems to imply that all operators exist in both forms. This is
! more new entities than the problem merits, and would require the
! addition of many new overloadable methods, such as __at_mul__.
!
! Second, while it is certainly possible to invent semantics for
! these new operators for built-in types, this would be a case of
! the tail wagging the dog, i.e. of letting the existence of a
! feature "create" a need for it.
!
! Finally, the boxed forms make human parsing more complex, e.g.:
!
! A[*] = B vs. A[:] = B
!
! 03. (From Moshe Zadka [7], and also considered by Huaiyu Zhou [8]
! in his proposal [9]) Retain the existing meaning of all
! operators, but create a behavioral accessor for arrays, such
! that:

A * B
--- 210,256 ----
as implementing single-stage nesting).

+
+ Alternatives
+
+ 01. Don't add new operators.

! Python is not primarily a numerical language; it may not be worth
! complexifying it for this special case. NumPy's success is proof
! that users can and will use functions and methods for linear
! algebra. However, support for real matrix multiplication is
! frequently requested, as:
!
! * functional forms are cumbersome for lengthy formulas, and do not
! respect the operator precedence rules of conventional mathematics;
! and
!
! * method forms are asymmetric in their operands.
!
! What's more, the proposed semantics for "@" for built-in sequence
! types would simplify expression of a very common idiom (nested
! loops). User testing during discussion of 'lockstep loops'
! indicated that both new and experienced users would understand
! this immediately.
!
! 02. Introduce prefixed forms of all existing operators, such as
! "~*" and "~+", as proposed in PEP 0225 [7].
!
! This proposal would duplicate all built-in mathematical operators
! with matrix equivalents, as in numerical languages such as
! MATLAB. Our objections to this are:
!
! * Python is not primarily a numerical programming language. While
! the (self-selected) participants in the discussions that led to
! PEP 0225 may want all of these new operators, the majority of
! Python users would be indifferent. The extra complexity they
! would introduce into the language therefore does not seem
! merited. (See also Rawlings' comments, quoted in the Background
! section, about these operators not being essential.)

! * The proposed syntax is difficult to read (i.e. passes the "low
! toner" readability test).

! 03. Retain the existing meaning of all operators, but create a
! behavioral accessor for arrays, such that:

A * B
***************
*** 290,329 ****
which had a different implementation of __mul__().

! The advantage of this method is that it has no effect on the
existing implementation of Python: changes are localized in the
! Numeric module. The disadvantages are:

! (a) The semantics of "A.m() * B", "A + B.m()", and so on would
! have to be defined, and there is no "obvious" choice for them.

! (b) Aliasing objects to trigger different operator behavior feels
! less Pythonic than either calling methods (as in the existing
! Numeric module) or using a different operator. This PEP is
! primarily about look and feel, and about making Python more
! attractive to people who are not already using it.
!
! 04. (From a proposal [9] by Huaiyu Zhou [8]) Introduce a "delayed
! inverse" attribute, similar to the "transpose" attribute
! advocated in the third part of this proposal. The expression
! "a.I" would be a delayed handle on the inverse of the matrix
! "a", which would be evaluated in context as required. For
! example, "a.I * b" and "b * a.I" would solve sets of linear
! equations, without actually calculating the inverse.
!
! The main drawback of this proposal it is reliance on lazy
! evaluation, and even more on "smart" lazy evaluation (i.e. the
! operation performed depends on the context in which the evaluation
! is done). The BDFL has so far resisted introducing LE into
! Python.


Related Proposals

- 0203 : Augmented Assignments
-
- If new operators for linear algebra are introduced, it may
- make sense to introduce augmented assignment forms for
- them.
-
0207 : Rich Comparisons

--- 264,284 ----
which had a different implementation of __mul__().

! This proposal was made by Moshe Zadka, and is also considered by
! PEP 0225 [7]. Its advantage is that it has no effect on the
existing implementation of Python: changes are localized in the
! Numeric module. The disadvantages are

! * The semantics of "A.m() * B", "A + B.m()", and so on would have
! to be defined, and there is no "obvious" choice for them.

! * Aliasing objects to trigger different operator behavior feels
! less Pythonic than either calling methods (as in the existing
! Numeric module) or using a different operator. This PEP is
! primarily about look and feel, and about making Python more
! attractive to people who are not already using it.


Related Proposals

0207 : Rich Comparisons

***************
*** 337,358 ****
Python, rather than a built-in type.


- Acknowledgments:

I am grateful to Huaiyu Zhu [8] for initiating this discussion,
and for some of the ideas and terminology included below.


! References:

[1] http://www.acm.org/sigapl/whyapl.htm
[2] http://numpy.sourceforge.net
! [3] PEP-0203.txt "Augmented Assignments".
! [4] http://bevo.che.wisc.edu/octave/doc/octave_9.html#SEC69
[5] http://www.python.org/pipermail/python-dev/2000-July/013139.html
[6] PEP-0201.txt "Lockstep Iteration"
! [7] Moshe Zadka is 'moshez@math.huji.ac.il'.
! [8] Huaiyu Zhu is 'hzhu@users.sourceforge.net'
! [9] http://www.python.org/pipermail/python-list/2000-August/112529.html


--- 292,331 ----
Python, rather than a built-in type.

+ 0225 : Elementwise/Objectwise Operators
+
+ A (much) larger proposal that addresses the same subject.


+ Acknowledgments
+
I am grateful to Huaiyu Zhu [8] for initiating this discussion,
and for some of the ideas and terminology included below.


! References

[1] http://www.acm.org/sigapl/whyapl.htm
[2] http://numpy.sourceforge.net
! [3] http://bevo.che.wisc.edu/octave/
! [4] http://www.egroups.com/message/python-numeric/4
[5] http://www.python.org/pipermail/python-dev/2000-July/013139.html
[6] PEP-0201.txt "Lockstep Iteration"
! [7] http://www.python.org/pipermail/python-list/2000-August/112529.html
!
!
! Appendix: Other Operations
!
!
! We considered syntactic support for three other operations:
!
! T
! (a) transposition: A => A[j, i] for A[i, j]
!
! -1
! (b) inverse: A => A' such that A' * A = I (the identity matrix)
!
! (c) solution: A/b => x such that A * x = b
! A\b => x such that x * A = b
!





From python-dev@python.org Mon Nov 27 04:10:08 2000
From: python-dev@python.org (Barry Warsaw)
Date: Sun, 26 Nov 2000 20:10:08 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0218.txt,1.2,1.3
Message-ID: <200011270410.UAA11979@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv11968

Modified Files:
pep-0218.txt
Log Message:
Greg Wilson's latest, with spell-checking by Barry.


Index: pep-0218.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0218.txt,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** pep-0218.txt 2000/08/23 05:51:13 1.2
--- pep-0218.txt 2000/11/27 04:10:06 1.3
***************
*** 10,21 ****


! Abstract

Sets are a fundamental mathematical structure, and are commonly
! used to both specify and implement programs. Sets are often
! implemented as dictionaries with "don't care" values, but this
! leaves the meaning of intersection, union, difference, and other
! basic operations are ambiguous. This PEP therefore proposes
! syntax and semantics for a concrete, built-in set type.


--- 10,121 ----


! Introduction

+ This PEP proposes adding sets as a built-in type in Python.
+
+
+ Rationale
+
Sets are a fundamental mathematical structure, and are commonly
! used to specify algorithms. They are much less frequently used in
! implementations, even when they are the "right" structure.
! Programmers frequently use lists instead, even when the ordering
! information in lists is irrelevant, and by-value lookups are
! frequent. (Most medium-sized C programs contain a depressing
! number of start-to-end searches through malloc'd vectors to
! determine whether particular items are present or not...)
!
! Programmers are often told that they can implement sets as
! dictionaries with "don't care" values. Items can be added to
! these "sets" by assigning the "don't care" value to them;
! membership can be tested using "dict.has_key"; and items can be
! deleted using "del". However, the three main binary operations
! on sets --- union, intersection, and difference --- are not
! directly supported by this representation, since their meaning is
! ambiguous for dictionaries containing key/value pairs.
!
!
! Proposal
!
! We propose adding a new built-in type to Python to represent sets.
! This type will be an unordered collection of unique values, just
! as a dictionary is an unordered collection of key/value pairs.
! Constant sets will be represented using the usual mathematical
! notation, so that "{1, 2, 3}" will be a set of three integers.
!
! In order to avoid ambiguity, the empty set will be written "{,}",
! rather than "{}" (which is already used to represent empty
! dictionaries). We feel that this notation is as reasonable as the
! use of "(3,)" to represent single-element tuples; a more radical
! alternative is discussed in the "Alternatives" section.
!
! Iteration and comprehension will be implemented in the obvious
! ways, so that:
!
! for x in S:
!
! will step through the elements of S in arbitrary order, while:
!
! {x**2 for x in S}
!
! will produce a set containing the squares of all elements in S,
!
! Membership will be tested using "in" and "not in".
!
! The binary operators '|', '&', '-', and "^" will implement set
! union, intersection, difference, and symmetric difference. Their
! in-place equivalents will have the obvious semantics.
!
! The method "add" will add an element to a set. This is different
! from set union, as the following example shows:
!
! >>> {1, 2, 3} | {4, 5, 6}
! {1, 2, 3, 4, 5, 6}
!
! >>> {1, 2, 3}.add({4, 5, 6})
! {1, 2, 3, {4, 5, 6}}
!
! Note that we expect that items can also be added to sets using
! in-place union of temporaries, i.e. "S |= {x}" instead of
! "S.add(x)".
!
! Elements will be deleted from sets using a "remove" method, or
! using "del":
!
! >>> S = {1, 2, 3}
! >>> del S[1]
! >>> S
! {2, 3}
! >>> S.remove(3)
! {2}
!
! The "KeyError" exception will be raised if an attempt is made to
! remove an element which is not in a set.
!
! A new method "dict.keyset" will return the keys of a dictionary as
! a set. A corresponding method "dict.valueset" will return the
! dictionary's values as a set.
!
! A built-in converter "set()" will convert any sequence type to a
! set; converters such as "list()" and "tuple()" will be extended to
! handle sets as input.
!
!
! Alternatives
!
! A radical alternative to the (admittedly clumsy) notation "{,}" is
! to re-define "{}" to be the empty collection, rather than the
! empty dictionary. Operations which made this object non-empty
! would silently convert it to either a dictionary or a set; it
! would then retain that type for the rest of its existence. This
! idea was rejected because of its potential impact on existing
! Python programs. A similar proposal to modify "dict.keys" and
! "dict.values" to return sets, rather than lists, was rejected for
! the same reasons.
!
!
! Copyright
!
! This document has been placed in the Public Domain.





From python-dev@python.org Mon Nov 27 05:41:48 2000
From: python-dev@python.org (Barry Warsaw)
Date: Sun, 26 Nov 2000 21:41:48 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0211.txt,1.4,1.5
Message-ID: <200011270541.VAA20603@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv20595

Modified Files:
pep-0211.txt
Log Message:
Greg Wilson's latest.


Index: pep-0211.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0211.txt,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -r1.4 -r1.5
*** pep-0211.txt 2000/11/22 22:01:47 1.4
--- pep-0211.txt 2000/11/27 05:41:46 1.5
***************
*** 21,25 ****


! Proposal

Add a single new infix binary operator '@' ("across"), and
--- 21,25 ----


! Summary

Add a single new infix binary operator '@' ("across"), and
***************
*** 142,177 ****
A new operator '@' (pronounced "across") will be added to Python,
along with special methods "__across__()", "__racross__()", and
! "__iacross__()", with the usual semantics.
!
! NumPy will overload "@" to perform mathematical multiplication of
! arrays where shapes permit, and to throw an exception otherwise.
! Its implementation of "@" will treat built-in sequence types as if
! they were column vectors. This takes care of the cases MM and MV.
!
! An attribute "T" will be added to the NumPy array type, such that
! "m.T" is:
!
! (a) the transpose of "m" for a 2-dimensional array
!
! (b) the 1xN matrix transpose of "m" if "m" is a 1-dimensional
! array; or
!
! (c) a runtime error for an array with rank >= 3.
!
! This attribute will alias the memory of the base object. NumPy's
! "transpose()" function will be extended to turn built-in sequence
! types into row vectors. This takes care of the VM, VD, and VO
! cases. We propose an attribute because:
!
! (a) the resulting notation is similar to the 'superscript T' (at
! least, as similar as ASCII allows), and

- (b) it signals that the transposition aliases the original object.
-
No new operators will be defined to mean "solve a set of linear
! equations", or "invert a matrix". Instead, NumPy will define a
! value "inv", which will be recognized by the exponentiation
! operator, such that "A ** inv" is the inverse of "A". This is
! similar in spirit to NumPy's existing "newaxis" value.

(Optional) When applied to sequences, the "@" operator will return
--- 142,151 ----
A new operator '@' (pronounced "across") will be added to Python,
along with special methods "__across__()", "__racross__()", and
! "__iacross__()", with the usual semantics. (We recommend using
! "@", rather than the times-like "><", because of the ease with
! which the latter could be mis-typed as inequality "<>".)

No new operators will be defined to mean "solve a set of linear
! equations", or "invert a matrix".

(Optional) When applied to sequences, the "@" operator will return
***************
*** 294,298 ****
0225 : Elementwise/Objectwise Operators

! A (much) larger proposal that addresses the same subject.


--- 268,273 ----
0225 : Elementwise/Objectwise Operators

! A larger proposal that addresses the same subject, but
! which proposes many more additions to the language.


***************
*** 313,330 ****
[7] http://www.python.org/pipermail/python-list/2000-August/112529.html


! Appendix: Other Operations


! We considered syntactic support for three other operations:

! T
! (a) transposition: A => A[j, i] for A[i, j]

! -1
! (b) inverse: A => A' such that A' * A = I (the identity matrix)

! (c) solution: A/b => x such that A * x = b
! A\b => x such that x * A = b


--- 288,323 ----
[7] http://www.python.org/pipermail/python-list/2000-August/112529.html

+
+ Appendix: NumPy

! NumPy will overload "@" to perform mathematical multiplication of
! arrays where shapes permit, and to throw an exception otherwise.
! Its implementation of "@" will treat built-in sequence types as if
! they were column vectors. This takes care of the cases MM and MV.

+ An attribute "T" will be added to the NumPy array type, such that
+ "m.T" is:

! (a) the transpose of "m" for a 2-dimensional array

! (b) the 1xN matrix transpose of "m" if "m" is a 1-dimensional
! array; or

! (c) a runtime error for an array with rank >= 3.
!
! This attribute will alias the memory of the base object. NumPy's
! "transpose()" function will be extended to turn built-in sequence
! types into row vectors. This takes care of the VM, VD, and VO
! cases. We propose an attribute because:
!
! (a) the resulting notation is similar to the 'superscript T' (at
! least, as similar as ASCII allows), and
!
! (b) it signals that the transposition aliases the original object.

! NumPy will define a value "inv", which will be recognized by the
! exponentiation operator, such that "A ** inv" is the inverse of
! "A". This is similar in spirit to NumPy's existing "newaxis"
! value.





From python-dev@python.org Mon Nov 27 06:38:06 2000
From: python-dev@python.org (Tim Peters)
Date: Sun, 26 Nov 2000 22:38:06 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/tut tut.tex,1.120,1.121
Message-ID: <200011270638.WAA25758@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/tut
In directory slayer.i.sourceforge.net:/tmp/cvs-serv25711/python/dist/src/doc/tut

Modified Files:
tut.tex
Log Message:
SF non-bug 123520: fleshed out the tutorial's lambda example a little more.


Index: tut.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/tut/tut.tex,v
retrieving revision 1.120
retrieving revision 1.121
diff -C2 -r1.120 -r1.121
*** tut.tex 2000/10/25 23:22:54 1.120
--- tut.tex 2000/11/27 06:38:04 1.121
***************
*** 1498,1503 ****

\begin{verbatim}
! def make_incrementor(n):
! return lambda x, incr=n: x+incr
\end{verbatim}

--- 1498,1510 ----

\begin{verbatim}
! >>> def make_incrementor(n):
! ... return lambda x, incr=n: x+incr
! ...
! >>> f = make_incrementor(42)
! >>> f(0)
! 42
! >>> f(1)
! 43
! >>>
\end{verbatim}




From python-dev@python.org Mon Nov 27 18:46:29 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 27 Nov 2000 10:46:29 -0800
Subject: [Python-checkins] CVS: python/dist/src/Objects stringobject.c,2.92,2.93
Message-ID: <200011271846.KAA22483@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Objects
In directory slayer.i.sourceforge.net:/tmp/cvs-serv22459

Modified Files:
stringobject.c
Log Message:
SF patch #102548, fix for bug #121013, by mwh@users.sourceforge.net.

Fixes a typo that caused "".join(u"this is a test") to dump core.


Index: stringobject.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Objects/stringobject.c,v
retrieving revision 2.92
retrieving revision 2.93
diff -C2 -r2.92 -r2.93
*** stringobject.c 2000/10/24 19:57:45 2.92
--- stringobject.c 2000/11/27 18:46:26 2.93
***************
*** 836,840 ****
Py_DECREF(res);
Py_DECREF(seq);
! return PyUnicode_Join((PyObject *)self, seq);
}
PyErr_Format(PyExc_TypeError,
--- 836,840 ----
Py_DECREF(res);
Py_DECREF(seq);
! return PyUnicode_Join((PyObject *)self, orig);
}
PyErr_Format(PyExc_TypeError,



From python-dev@python.org Mon Nov 27 20:10:26 2000
From: python-dev@python.org (Fred L. Drake)
Date: Mon, 27 Nov 2000 12:10:26 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/doc doc.tex,1.36,1.37
Message-ID: <200011272010.MAA32689@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/doc
In directory slayer.i.sourceforge.net:/tmp/cvs-serv32667/doc

Modified Files:
doc.tex
Log Message:

Minor typo: \subsubsections --> \subsubsection


Index: doc.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/doc/doc.tex,v
retrieving revision 1.36
retrieving revision 1.37
diff -C2 -r1.36 -r1.37
*** doc.tex 2000/10/28 04:08:38 1.36
--- doc.tex 2000/11/27 20:10:18 1.37
***************
*** 365,369 ****
\lineiii{2}{\macro{section}}{}
\lineiii{3}{\macro{subsection}}{}
! \lineiii{4}{\macro{subsubsections}}{}
\lineiii{5}{\macro{paragraph}}{(2)}
\lineiii{6}{\macro{subparagraph}}{}
--- 365,369 ----
\lineiii{2}{\macro{section}}{}
\lineiii{3}{\macro{subsection}}{}
! \lineiii{4}{\macro{subsubsection}}{}
\lineiii{5}{\macro{paragraph}}{(2)}
\lineiii{6}{\macro{subparagraph}}{}



From python-dev@python.org Mon Nov 27 21:53:18 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 27 Nov 2000 13:53:18 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib copy.py,1.16,1.17
Message-ID: <200011272153.NAA13347@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv13333

Modified Files:
copy.py
Log Message:
Patch by Finn Bock to support PyStringMap in Jython.


Index: copy.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/copy.py,v
retrieving revision 1.16
retrieving revision 1.17
diff -C2 -r1.16 -r1.17
*** copy.py 2000/09/07 11:00:03 1.16
--- copy.py 2000/11/27 21:53:14 1.17
***************
*** 57,60 ****
--- 57,65 ----
error = Error # backward compatibility

+ try:
+ from org.python.core import PyStringMap
+ except ImportError:
+ PyStringMap = None
+
def copy(x):
"""Shallow copy operation on arbitrary Python objects.
***************
*** 105,108 ****
--- 110,115 ----
return x.copy()
d[types.DictionaryType] = _copy_dict
+ if PyStringMap is not None:
+ d[PyStringMap] = _copy_dict

def _copy_inst(x):
***************
*** 201,204 ****
--- 208,213 ----
return y
d[types.DictionaryType] = _deepcopy_dict
+ if PyStringMap is not None:
+ d[PyStringMap] = _deepcopy_dict

def _keep_alive(x, memo):



From python-dev@python.org Mon Nov 27 22:22:39 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 27 Nov 2000 14:22:39 -0800
Subject: [Python-checkins] CVS: python/dist/src/Python compile.c,2.143,2.144
Message-ID: <200011272222.OAA17333@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Python
In directory slayer.i.sourceforge.net:/tmp/cvs-serv17324

Modified Files:
compile.c
Log Message:
Plug a memory leak in com_import_stmt(): the tuple created to hold the
"..." in "from M import ..." was never DECREFed. Leak reported by
James Slaughter and nailed by Barry, who also provided an earlier
version of this patch.


Index: compile.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Python/compile.c,v
retrieving revision 2.143
retrieving revision 2.144
diff -C2 -r2.143 -r2.144
*** compile.c 2000/11/14 20:44:53 2.143
--- compile.c 2000/11/27 22:22:36 2.144
***************
*** 2326,2334 ****
{
int i;
- PyObject *tup;
REQ(n, import_stmt);
/* 'import' dotted_name (',' dotted_name)* |
'from' dotted_name 'import' ('*' | NAME (',' NAME)*) */
if (STR(CHILD(n, 0))[0] == 'f') {
/* 'from' dotted_name 'import' ... */
REQ(CHILD(n, 1), dotted_name);
--- 2326,2334 ----
{
int i;
REQ(n, import_stmt);
/* 'import' dotted_name (',' dotted_name)* |
'from' dotted_name 'import' ('*' | NAME (',' NAME)*) */
if (STR(CHILD(n, 0))[0] == 'f') {
+ PyObject *tup;
/* 'from' dotted_name 'import' ... */
REQ(CHILD(n, 1), dotted_name);
***************
*** 2345,2348 ****
--- 2345,2349 ----
}
com_addoparg(c, LOAD_CONST, com_addconst(c, tup));
+ Py_DECREF(tup);
com_push(c, 1);
com_addopname(c, IMPORT_NAME, CHILD(n, 1));



From python-dev@python.org Tue Nov 28 06:38:26 2000
From: python-dev@python.org (Fred L. Drake)
Date: Mon, 27 Nov 2000 22:38:26 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib libpyexpat.tex,1.7,1.8
Message-ID: <200011280638.WAA30155@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv30139/lib

Modified Files:
libpyexpat.tex
Log Message:

Two minor nits.


Index: libpyexpat.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/libpyexpat.tex,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -r1.7 -r1.8
*** libpyexpat.tex 2000/10/29 05:10:30 1.7
--- libpyexpat.tex 2000/11/28 06:38:22 1.8
***************
*** 61,66 ****
the local part will be concatenated without any separator.

! For example, if \var{namespace_separator} is set to
! \character{ }, and the following document is parsed:

\begin{verbatim}
--- 61,66 ----
the local part will be concatenated without any separator.

! For example, if \var{namespace_separator} is set to a space character
! (\character{ }) and the following document is parsed:

\begin{verbatim}
***************
*** 86,90 ****
\class{xmlparser} objects have the following methods:

! \begin{methoddesc}[xmlparser]{Parse}{data \optional{, isfinal}}
Parses the contents of the string \var{data}, calling the appropriate
handler functions to process the parsed data. \var{isfinal} must be
--- 86,90 ----
\class{xmlparser} objects have the following methods:

! \begin{methoddesc}[xmlparser]{Parse}{data\optional{, isfinal}}
Parses the contents of the string \var{data}, calling the appropriate
handler functions to process the parsed data. \var{isfinal} must be



From python-dev@python.org Tue Nov 28 06:39:31 2000
From: python-dev@python.org (Fred L. Drake)
Date: Mon, 27 Nov 2000 22:39:31 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib libxmllib.tex,1.29,1.30
Message-ID: <200011280639.WAA30243@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv30233/lib

Modified Files:
libxmllib.tex
Log Message:

Added brief explanation of the \versionchanged for 1.5.2 (fixes formatting
for the HTML version).


Index: libxmllib.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/libxmllib.tex,v
retrieving revision 1.29
retrieving revision 1.30
diff -C2 -r1.29 -r1.30
*** libxmllib.tex 2000/10/10 22:00:03 1.29
--- libxmllib.tex 2000/11/28 06:39:28 1.30
***************
*** 14,18 ****
package includes full support for XML 1.0.}

! \versionchanged{1.5.2}

This module defines a class \class{XMLParser} which serves as the basis
--- 14,18 ----
package includes full support for XML 1.0.}

! \versionchanged[Added namespace support.]{1.5.2}

This module defines a class \class{XMLParser} which serves as the basis



From python-dev@python.org Tue Nov 28 12:09:04 2000
From: python-dev@python.org (Guido van Rossum)
Date: Tue, 28 Nov 2000 04:09:04 -0800
Subject: [Python-checkins] CVS: python/dist/src/Objects Makefile.in,2.13,2.14
Message-ID: <200011281209.EAA25271@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Objects
In directory slayer.i.sourceforge.net:/tmp/cvs-serv25257

Modified Files:
Makefile.in
Log Message:
Update dependencies per /F.


Index: Makefile.in
==================================================================RCS file: /cvsroot/python/python/dist/src/Objects/Makefile.in,v
retrieving revision 2.13
retrieving revision 2.14
diff -C2 -r2.13 -r2.14
*** Makefile.in 2000/03/10 22:55:40 2.13
--- Makefile.in 2000/11/28 12:09:00 2.14
***************
*** 98,102 ****
typeobject.o: typeobject.c
unicodeobject.o: unicodeobject.c
! unicodectype.o: unicodectype.c

# DO NOT DELETE THIS LINE -- mkdep uses it.
--- 98,102 ----
typeobject.o: typeobject.c
unicodeobject.o: unicodeobject.c
! unicodectype.o: unicodectype.c unicodetype_db.h

# DO NOT DELETE THIS LINE -- mkdep uses it.



From python-dev@python.org Tue Nov 28 12:09:21 2000
From: python-dev@python.org (Guido van Rossum)
Date: Tue, 28 Nov 2000 04:09:21 -0800
Subject: [Python-checkins] CVS: python/dist/src/Modules Makefile.pre.in,1.70,1.71
Message-ID: <200011281209.EAA25305@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Modules
In directory slayer.i.sourceforge.net:/tmp/cvs-serv25295

Modified Files:
Makefile.pre.in
Log Message:
Update dependencies per /F.


Index: Makefile.pre.in
==================================================================RCS file: /cvsroot/python/python/dist/src/Modules/Makefile.pre.in,v
retrieving revision 1.70
retrieving revision 1.71
diff -C2 -r1.70 -r1.71
*** Makefile.pre.in 2000/10/29 04:28:48 1.70
--- Makefile.pre.in 2000/11/28 12:09:18 1.71
***************
*** 227,231 ****
timingmodule.o: timingmodule.c
unicodedata.o: unicodedata.c unicodedatabase.o
! unicodedatabase.o: unicodedatabase.c unicodedatabase.h
ucnhash.o: ucnhash.c
xxmodule.o: xxmodule.c
--- 227,231 ----
timingmodule.o: timingmodule.c
unicodedata.o: unicodedata.c unicodedatabase.o
! unicodedatabase.o: unicodedatabase.c unicodedatabase.h unicodedata_db.h
ucnhash.o: ucnhash.c
xxmodule.o: xxmodule.c



From python-dev@python.org Tue Nov 28 13:43:03 2000
From: python-dev@python.org (Guido van Rossum)
Date: Tue, 28 Nov 2000 05:43:03 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0205.txt,1.5,1.6
Message-ID: <200011281343.FAA04001@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv3989

Modified Files:
pep-0205.txt
Log Message:
Slight grammar and spelling nits; updated mx.Proxy URL; added
reference to EST's pyweak.


Index: pep-0205.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0205.txt,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -r1.5 -r1.6
*** pep-0205.txt 2000/11/17 22:54:45 1.5
--- pep-0205.txt 2000/11/28 13:43:00 1.6
***************
*** 16,20 ****
Caches (weak dictionaries)

! There is a need to allow objects to be maintained to represent
external state, mapping a single instance to the external
reality, where allowing multiple instances to be mapped to the
--- 16,20 ----
Caches (weak dictionaries)

! There is a need to allow objects to be maintained that represent
external state, mapping a single instance to the external
reality, where allowing multiple instances to be mapped to the
***************
*** 39,43 ****
every use.

! - Objects which are expensive to create, but may be needed by
multiple internal consumers. Similar to the first case, but
not necessarily bound to external resources, and possibly
--- 39,43 ----
every use.

! - Objects that are expensive to create, but may be needed by
multiple internal consumers. Similar to the first case, but
not necessarily bound to external resources, and possibly
***************
*** 79,83 ****
the stored objects are infrequent.

! Java's "weak" references are most like Diane Hackborn's old vref
proposal: a reference object refers to a single Python object,
but does not own a reference to that object. When that object is
--- 79,83 ----
the stored objects are infrequent.

! Java's "weak" references are most like Dianne Hackborn's old vref
proposal: a reference object refers to a single Python object,
but does not own a reference to that object. When that object is
***************
*** 104,120 ****
Previous Weak Reference Work in Python

! Dianne Hackborn's proposed something called "virtual references".
! 'vref' objects were very similar to java.lang.ref.WeakReference
! objects, except there was no equivalent to the invalidation
queues. Implementing a "weak dictionary" would be just as
difficult as using only weak references (without the invalidation
! queue) in Java. Information on this has disappeared from the Web.
! Original discussion occurred in the comp.lang.python newsgroup; a
! good archive of that may turn up something more.

! Marc-André Lemburg's mx.Proxy package. These Web pages appear to
! be unavailable at the moment.

! http://starship.python.net/crew/lemburg/

The weakdict module by Dieter Maurer is implemented in C and
--- 104,118 ----
Previous Weak Reference Work in Python

! Dianne Hackborn has proposed something called "virtual references".
! 'vref' objects are very similar to java.lang.ref.WeakReference
! objects, except there is no equivalent to the invalidation
queues. Implementing a "weak dictionary" would be just as
difficult as using only weak references (without the invalidation
! queue) in Java. Information on this has disappeared from the Web,
! but is included below as an Appendix.

! Marc-André Lemburg's mx.Proxy package:

! http://www.lemburg.com/files/python/mxProxy.html

The weakdict module by Dieter Maurer is implemented in C and
***************
*** 128,131 ****
--- 126,133 ----

http://sourceforge.net/projects/pyweakreference/
+
+ Eric Tiedemann has a weak dictionary implementation:
+
+ http://www.hyperreal.org/~est/python/weak/





From python-dev@python.org Tue Nov 28 14:01:21 2000
From: python-dev@python.org (Guido van Rossum)
Date: Tue, 28 Nov 2000 06:01:21 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0000.txt,1.49,1.50 pep-0207.txt,1.2,1.3 pep-0208.txt,1.1,1.2
Message-ID: <200011281401.GAA05786@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv5725

Modified Files:
pep-0000.txt pep-0207.txt pep-0208.txt
Log Message:
Update status; fix Zadka's co-ownership of 207/208.


Index: pep-0000.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0000.txt,v
retrieving revision 1.49
retrieving revision 1.50
diff -C2 -r1.49 -r1.50
*** pep-0000.txt 2000/11/22 19:17:36 1.49
--- pep-0000.txt 2000/11/28 14:01:17 1.50
***************
*** 32,37 ****

I 42 pep-0042.txt Small Feature Requests Hylton
! S 207 pep-0207.txt Rich Comparisons Zadka, Lemburg
! S 208 pep-0208.txt Reworking the Coercion Model Ascher
S 217 pep-0217.txt Display Hook for Interactive Use Zadka
S 222 pep-0222.txt Web Library Enhancements Kuchling
--- 32,38 ----

I 42 pep-0042.txt Small Feature Requests Hylton
! SD 205 pep-0205.txt Weak References Drake
! S 207 pep-0207.txt Rich Comparisons Lemburg
! S 208 pep-0208.txt Reworking the Coercion Model Ascher, Zadka
S 217 pep-0217.txt Display Hook for Interactive Use Zadka
S 222 pep-0222.txt Web Library Enhancements Kuchling
***************
*** 39,42 ****
--- 40,44 ----
S 227 pep-0227.txt Statically Nested Scopes Hylton
S 229 pep-0229.txt Using Distutils to Build Python Kuchling
+ I 216 pep-0216.txt Docstring Format Zadka

Pie-in-the-sky PEPs (not ready; may become active yet)
***************
*** 46,49 ****
--- 48,52 ----
SD 212 pep-0212.txt Loop Counter Iteration Schneider-Kamp
SD 213 pep-0213.txt Attribute Access Handlers Prescod
+ SD 218 pep-0218.txt Adding a Built-In Set Object Type Wilson
SD 224 pep-0224.txt Attribute Docstrings Lemburg
SD 225 pep-0225.txt Elementwise/Objectwise Operators Zhu, Lielens
***************
*** 52,57 ****
Incomplete PEPs (only an abstract)

- SD 205 pep-0205.txt Weak References Drake
- SD 218 pep-0218.txt Adding a Built-In Set Object Type Wilson
SD 219 pep-0219.txt Stackless Python McMillan
I 220 pep-0220.txt Coroutines, Generators, Continuations McMillan
--- 55,58 ----
***************
*** 62,66 ****
SD 210 pep-0210.txt Decoupling the Interpreter Loop Ascher
SD 215 pep-0215.txt String Interpolation Yee
- I 216 pep-0216.txt Docstring Format Zadka

Finished PEPs (done, implemented)
--- 63,66 ----

Index: pep-0207.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0207.txt,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** pep-0207.txt 2000/11/06 18:21:58 1.2
--- pep-0207.txt 2000/11/28 14:01:17 1.3
***************
*** 2,6 ****
Title: Rich Comparisions
Version: $Revision$
! Owner: mal@lemburg.com (Marc-Andre Lemburg), pep@zadka.site.co.il (Moshe Zadka)
Python-Version: 2.1
Status: Incomplete
--- 2,6 ----
Title: Rich Comparisions
Version: $Revision$
! Owner: mal@lemburg.com (Marc-Andre Lemburg)
Python-Version: 2.1
Status: Incomplete

Index: pep-0208.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0208.txt,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** pep-0208.txt 2000/07/15 23:28:27 1.1
--- pep-0208.txt 2000/11/28 14:01:17 1.2
***************
*** 2,6 ****
Title: Reworking the Coercion Model
Version: $Revision$
! Owner: davida@activestate.com (David Ascher)
Python-Version: 2.1
Status: Incomplete
--- 2,6 ----
Title: Reworking the Coercion Model
Version: $Revision$
! Owner: davida@activestate.com (David Ascher), pep@zadka.site.co.il (Moshe Zadka)
Python-Version: 2.1
Status: Incomplete



From python-dev@python.org Tue Nov 28 16:20:55 2000
From: python-dev@python.org (Fred L. Drake)
Date: Tue, 28 Nov 2000 08:20:55 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/tools mkmodindex,1.8,1.9
Message-ID: <200011281620.IAA21023@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/tools
In directory slayer.i.sourceforge.net:/tmp/cvs-serv21012/tools

Modified Files:
mkmodindex
Log Message:

Use a subclass of buildindex.Node to clean up the HTML and get the
ordering fixed up (this makes sure that "xml.dom" comes before
"xml.dom.minidom" in the Module Index, which was not true before because
some HTML cruft crept into the data structures).


Index: mkmodindex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/tools/mkmodindex,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -r1.8 -r1.9
*** mkmodindex 2000/10/05 05:14:26 1.8
--- mkmodindex 2000/11/28 16:20:50 1.9
***************
*** 49,52 ****
--- 49,69 ----


+ class Node(buildindex.Node):
+ annotation = ""
+
+ def __init__(self, link, str, seqno):
+ parts = str.split(None, 1)
+ if parts[0].endswith("</tt>"):
+ self.modname = parts[0][:-5]
+ else:
+ self.modname = parts[0]
+ if len(parts) == 2:
+ self.annotation = parts[1]
+ buildindex.Node.__init__(self, link, self.modname, seqno)
+
+ def __str__(self):
+ return '<tt class="module">%s</tt> %s' \
+ % (self.modname, self.annotation)
+
_rx = re.compile(
"<dt><a href='(module-.*\.html)#l2h-\d+'><tt class='module'>"
***************
*** 84,91 ****
has_plat_flag = has_plat_flag or m.group(3)
linkfile = os.path.join(dirname, basename)
! nodes.append(buildindex.Node(
! '<a href="%s">' % linkfile,
! "<tt class=module>%s</tt>" % modname,
! seqno))
seqno = seqno + 1
ifp.close()
--- 101,105 ----
has_plat_flag = has_plat_flag or m.group(3)
linkfile = os.path.join(dirname, basename)
! nodes.append(Node('<a href="%s">' % linkfile, modname, seqno))
seqno = seqno + 1
ifp.close()



From python-dev@python.org Tue Nov 28 16:24:31 2000
From: python-dev@python.org (Fred L. Drake)
Date: Tue, 28 Nov 2000 08:24:31 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib libstringio.tex,1.4,1.5
Message-ID: <200011281624.IAA21387@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv21374/lib

Modified Files:
libstringio.tex
Log Message:

Added information on the use of Unicode with the StringIO and cStringIO
modules, otherwise the behavior is just plain confusing.


Index: libstringio.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/libstringio.tex,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -r1.4 -r1.5
*** libstringio.tex 1999/04/21 18:15:22 1.4
--- libstringio.tex 2000/11/28 16:24:28 1.5
***************
*** 8,12 ****
This module implements a file-like class, \class{StringIO},
that reads and writes a string buffer (also known as \emph{memory
! files}). See the description on file objects for operations (section
\ref{bltin-file-objects}).

--- 8,12 ----
This module implements a file-like class, \class{StringIO},
that reads and writes a string buffer (also known as \emph{memory
! files}). See the description of file objects for operations (section
\ref{bltin-file-objects}).

***************
*** 15,18 ****
--- 15,24 ----
to an existing string by passing the string to the constructor.
If no string is given, the \class{StringIO} will start empty.
+
+ The \class{StringIO} object can accept either Unicode or 8-bit
+ strings, but mixing the two may take some care. If both are used,
+ 8-bit strings that cannot be interpreted as 7-bit \ASCII{} (i.e., that
+ use the 8th bit) will cause a \exception{UnicodeError} to be raised
+ when \method{getvalue()} is called.
\end{classdesc}

***************
*** 22,26 ****
\begin{methoddesc}{getvalue}{}
Retrieve the entire contents of the ``file'' at any time before the
! \class{StringIO} object's \method{close()} method is called.
\end{methoddesc}

--- 28,34 ----
\begin{methoddesc}{getvalue}{}
Retrieve the entire contents of the ``file'' at any time before the
! \class{StringIO} object's \method{close()} method is called. See the
! note above for information about mixing Unicode and 8-bit strings;
! such mixing can cause this method to raise \exception{UnicodeError}.
\end{methoddesc}

***************
*** 47,50 ****
--- 55,62 ----
built-in types, there's no way to build your own version using
subclassing. Use the original \refmodule{StringIO} module in that case.
+
+ Unlike the memory files implemented by the \refmodule{StringIO}
+ module, those provided by this module are not able to accept Unicode
+ strings that cannot be encoded as plain \ASCII{} strings.

The following data objects are provided as well:



From python-dev@python.org Tue Nov 28 22:13:47 2000
From: python-dev@python.org (Guido van Rossum)
Date: Tue, 28 Nov 2000 14:13:47 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0000.txt,1.50,1.51 pep-0207.txt,1.3,1.4
Message-ID: <200011282213.OAA31146@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv30781

Modified Files:
pep-0000.txt pep-0207.txt
Log Message:
Demoted 216 (docstring format) and 229 (using distutils to build) to
pie-in-the-sky. Reasons: 216 is NOT the consensus of the doc-sig; 229
is not sufficiently worked out and doesn't seem a priority. (This can
still make it into 2.1 if the author does the work.)

Added GvR as co-author for 207 (rich comparisons).



Index: pep-0000.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0000.txt,v
retrieving revision 1.50
retrieving revision 1.51
diff -C2 -r1.50 -r1.51
*** pep-0000.txt 2000/11/28 14:01:17 1.50
--- pep-0000.txt 2000/11/28 22:13:44 1.51
***************
*** 33,37 ****
I 42 pep-0042.txt Small Feature Requests Hylton
SD 205 pep-0205.txt Weak References Drake
! S 207 pep-0207.txt Rich Comparisons Lemburg
S 208 pep-0208.txt Reworking the Coercion Model Ascher, Zadka
S 217 pep-0217.txt Display Hook for Interactive Use Zadka
--- 33,37 ----
I 42 pep-0042.txt Small Feature Requests Hylton
SD 205 pep-0205.txt Weak References Drake
! S 207 pep-0207.txt Rich Comparisons Lemburg, van Rossum
S 208 pep-0208.txt Reworking the Coercion Model Ascher, Zadka
S 217 pep-0217.txt Display Hook for Interactive Use Zadka
***************
*** 39,44 ****
I 226 pep-0226.txt Python 2.1 Release Schedule Hylton
S 227 pep-0227.txt Statically Nested Scopes Hylton
- S 229 pep-0229.txt Using Distutils to Build Python Kuchling
- I 216 pep-0216.txt Docstring Format Zadka

Pie-in-the-sky PEPs (not ready; may become active yet)
--- 39,42 ----
***************
*** 48,55 ****
--- 46,55 ----
SD 212 pep-0212.txt Loop Counter Iteration Schneider-Kamp
SD 213 pep-0213.txt Attribute Access Handlers Prescod
+ I 216 pep-0216.txt Docstring Format Zadka
SD 218 pep-0218.txt Adding a Built-In Set Object Type Wilson
SD 224 pep-0224.txt Attribute Docstrings Lemburg
SD 225 pep-0225.txt Elementwise/Objectwise Operators Zhu, Lielens
S 228 pep-0228.txt Reworking Python's Numeric Model Zadka
+ S 229 pep-0229.txt Using Distutils to Build Python Kuchling

Incomplete PEPs (only an abstract)
***************
*** 151,154 ****
--- 151,155 ----
Prescod, Paul paul@prescod.net
Raymond, Eric esr@snark.thyrsus.com
+ van Rossum, Guido guido@python.org
Schneider-Kamp, Peter nownder@nowonder.de
Warsaw, Barry barry@digicool.com

Index: pep-0207.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0207.txt,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** pep-0207.txt 2000/11/28 14:01:17 1.3
--- pep-0207.txt 2000/11/28 22:13:45 1.4
***************
*** 2,6 ****
Title: Rich Comparisions
Version: $Revision$
! Owner: mal@lemburg.com (Marc-Andre Lemburg)
Python-Version: 2.1
Status: Incomplete
--- 2,6 ----
Title: Rich Comparisions
Version: $Revision$
! Owner: mal@lemburg.com (Marc-Andre Lemburg), guido@python.org (Guido van Rossum)
Python-Version: 2.1
Status: Incomplete



From python-dev@python.org Tue Nov 28 22:23:31 2000
From: python-dev@python.org (Guido van Rossum)
Date: Tue, 28 Nov 2000 14:23:31 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0230.txt,NONE,1.1 pep-0000.txt,1.51,1.52 pep-0160.txt,1.7,1.8 pep-0200.txt,1.46,1.47 pep-0205.txt,1.6,1.7 pep-0206.txt,1.8,1.9 pep-0207.txt,1.4,1.5 pep-0208.txt,1.2,1.3
Message-ID: <200011282223.OAA32436@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv32367

Modified Files:
pep-0000.txt pep-0160.txt pep-0200.txt pep-0205.txt
pep-0206.txt pep-0207.txt pep-0208.txt
Added Files:
pep-0230.txt
Log Message:
Add PEP 230, Warning Framework.
Changed Owner: to Author: in a number of PEPs.


--- NEW FILE ---
PEP: 230
Title: Warning Framework
Version: $Revision: 1.1 $
Author: guido@python.org (Guido van Rossum)
Status: Draft
Type: Standards Track
Python-Version: 2.1
Status: Incomplete
Post-History: 05-Nov-2000


Abstract

This PEP proposes a C and Python level API, as well as command
line flags, to issue warning messages and control what happens to
them. This is mostly based on GvR's proposal posted to python-dev
on 05-Nov-2000, with some ideas (such as using classes to
categorize warnings) merged in from Paul Prescod's
counter-proposal posted on the same date.



Local Variables:
mode: indented-text
indent-tabs-mode: nil
End:

Index: pep-0000.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0000.txt,v
retrieving revision 1.51
retrieving revision 1.52
diff -C2 -r1.51 -r1.52
*** pep-0000.txt 2000/11/28 22:13:44 1.51
--- pep-0000.txt 2000/11/28 22:23:25 1.52
***************
*** 39,42 ****
--- 39,43 ----
I 226 pep-0226.txt Python 2.1 Release Schedule Hylton
S 227 pep-0227.txt Statically Nested Scopes Hylton
+ S 230 pep-0230.txt Warning Framework van Rossum

Pie-in-the-sky PEPs (not ready; may become active yet)
***************
*** 124,128 ****
S 228 pep-0228.txt Reworking Python's Numeric Model Zadka
S 229 pep-0229.txt Using Distutils to Build Python Kuchling
!

Key
--- 125,129 ----
S 228 pep-0228.txt Reworking Python's Numeric Model Zadka
S 229 pep-0229.txt Using Distutils to Build Python Kuchling
! S 230 pep-0230.txt Warning Framework van Rossum

Key

Index: pep-0160.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0160.txt,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -r1.7 -r1.8
*** pep-0160.txt 2000/10/30 20:48:44 1.7
--- pep-0160.txt 2000/11/28 22:23:25 1.8
***************
*** 2,6 ****
Title: Python 1.6 Release Schedule
Version: $Revision$
! Owner: Fred L. Drake, Jr. <fdrake@acm.org>
Python-Version: 1.6
Status: Complete
--- 2,6 ----
Title: Python 1.6 Release Schedule
Version: $Revision$
! Author: Fred L. Drake, Jr. <fdrake@acm.org>
Python-Version: 1.6
Status: Complete

Index: pep-0200.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0200.txt,v
retrieving revision 1.46
retrieving revision 1.47
diff -C2 -r1.46 -r1.47
*** pep-0200.txt 2000/11/02 16:44:04 1.46
--- pep-0200.txt 2000/11/28 22:23:25 1.47
***************
*** 2,6 ****
Title: Python 2.0 Release Schedule
Version: $Revision$
! Owner: Jeremy Hylton <jeremy@digicool.com>
Python-Version: 2.0
Status: Final
--- 2,6 ----
Title: Python 2.0 Release Schedule
Version: $Revision$
! Author: Jeremy Hylton <jeremy@digicool.com>
Python-Version: 2.0
Status: Final

Index: pep-0205.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0205.txt,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -r1.6 -r1.7
*** pep-0205.txt 2000/11/28 13:43:00 1.6
--- pep-0205.txt 2000/11/28 22:23:25 1.7
***************
*** 2,6 ****
Title: Weak References
Version: $Revision$
! Owner: Fred L. Drake, Jr. <fdrake@acm.org>
Python-Version: 2.1
Status: Incomplete
--- 2,6 ----
Title: Weak References
Version: $Revision$
! Author: Fred L. Drake, Jr. <fdrake@acm.org>
Python-Version: 2.1
Status: Incomplete

Index: pep-0206.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0206.txt,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -r1.8 -r1.9
*** pep-0206.txt 2000/08/11 03:54:16 1.8
--- pep-0206.txt 2000/11/28 22:23:25 1.9
***************
*** 2,6 ****
Title: 2.0 Batteries Included
Version: $Revision$
! Owner: moshez@math.huji.ac.il (Moshe Zadka)
Python-Version: 2.0
Status: Draft
--- 2,6 ----
Title: 2.0 Batteries Included
Version: $Revision$
! Author: moshez@math.huji.ac.il (Moshe Zadka)
Python-Version: 2.0
Status: Draft

Index: pep-0207.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0207.txt,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -r1.4 -r1.5
*** pep-0207.txt 2000/11/28 22:13:45 1.4
--- pep-0207.txt 2000/11/28 22:23:25 1.5
***************
*** 2,6 ****
Title: Rich Comparisions
Version: $Revision$
! Owner: mal@lemburg.com (Marc-Andre Lemburg), guido@python.org (Guido van Rossum)
Python-Version: 2.1
Status: Incomplete
--- 2,6 ----
Title: Rich Comparisions
Version: $Revision$
! Author: mal@lemburg.com (Marc-Andre Lemburg), guido@python.org (Guido van Rossum)
Python-Version: 2.1
Status: Incomplete

Index: pep-0208.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0208.txt,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** pep-0208.txt 2000/11/28 14:01:17 1.2
--- pep-0208.txt 2000/11/28 22:23:25 1.3
***************
*** 2,6 ****
Title: Reworking the Coercion Model
Version: $Revision$
! Owner: davida@activestate.com (David Ascher), pep@zadka.site.co.il (Moshe Zadka)
Python-Version: 2.1
Status: Incomplete
--- 2,6 ----
Title: Reworking the Coercion Model
Version: $Revision$
! Author: davida@activestate.com (David Ascher), pep@zadka.site.co.il (Moshe Zadka)
Python-Version: 2.1
Status: Incomplete



From python-dev@python.org Tue Nov 28 22:34:36 2000
From: python-dev@python.org (Fred L. Drake)
Date: Tue, 28 Nov 2000 14:34:36 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/api api.tex,1.97,1.98 refcounts.dat,1.18,1.19
Message-ID: <200011282234.OAA01509@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/api
In directory slayer.i.sourceforge.net:/tmp/cvs-serv1498/api

Modified Files:
api.tex refcounts.dat
Log Message:

Added documentation for the Py_InitModule*() family of functions.


Index: api.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/api/api.tex,v
retrieving revision 1.97
retrieving revision 1.98
diff -C2 -r1.97 -r1.98
*** api.tex 2000/10/23 16:00:54 1.97
--- api.tex 2000/11/28 22:34:32 1.98
***************
*** 4651,4655 ****
\end{cfuncdesc}

! Py_InitModule (!!!)

PyArg_ParseTupleAndKeywords, PyArg_ParseTuple, PyArg_Parse
--- 4651,4685 ----
\end{cfuncdesc}

! \begin{cfuncdesc}{PyObject*}{Py_InitModule}{char *name,
! PyMethodDef *methods}
! Create a new module object based on a name and table of functions,
! returning the new module object.
! \end{cfuncdesc}
!
! \begin{cfuncdesc}{PyObject*}{Py_InitModule3}{char *name,
! PyMethodDef *methods,
! char *doc}
! Create a new module object based on a name and table of functions,
! returning the new module object. If \var{doc} is non-\NULL, it will
! be used to define the docstring for the module.
! \end{cfuncdesc}
!
! \begin{cfuncdesc}{PyObject*}{Py_InitModule4}{char *name,
! PyMethodDef *methods,
! char *doc, PyObject *self,
! int apiver}
! Create a new module object based on a name and table of functions,
! returning the new module object. If \var{doc} is non-\NULL, it will
! be used to define the docstring for the module. If \var{self} is
! non-\NULL, it will passed to the functions of the module as their
! (otherwise \NULL) first parameter. (This was added as an
! experimental feature, and there are no known uses in the current
! version of Python.) For \var{apiver}, the only value which should
! be passed is defined by the constant \constant{PYTHON_API_VERSION}.
!
! \strong{Note:} Most uses of this function should probably be using
! the \cfunction{Py_InitModule3()} instead; only use this if you are
! sure you need it.
! \end{cfuncdesc}

PyArg_ParseTupleAndKeywords, PyArg_ParseTuple, PyArg_Parse

Index: refcounts.dat
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/api/refcounts.dat,v
retrieving revision 1.18
retrieving revision 1.19
diff -C2 -r1.18 -r1.19
*** refcounts.dat 2000/09/22 18:19:37 1.18
--- refcounts.dat 2000/11/28 22:34:32 1.19
***************
*** 275,278 ****
--- 275,294 ----
PyFloat_FromDouble:double:v::

+ Py_InitModule:PyObject*::0:
+ Py_InitModule:name:char*::
+ Py_InitModule:methods:PyMethodDef[]::
+
+ Py_InitModule3:PyObject*::0:
+ Py_InitModule3:name:char*::
+ Py_InitModule3:methods:PyMethodDef[]::
+ Py_InitModule3:doc:char*::
+
+ Py_InitModule4:PyObject*::0:
+ Py_InitModule4:name:char*::
+ Py_InitModule4:methods:PyMethodDef[]::
+ Py_InitModule4:doc:char*::
+ Py_InitModule4:self:PyObject*::
+ Py_InitModule4:apiver:int::usually provided by Py_InitModule or Py_InitModule3
+
PyImport_AddModule:PyObject*::0:reference borrowed from sys.modules
PyImport_AddModule:char*:name::



From python-dev@python.org Wed Nov 29 02:44:10 2000
From: python-dev@python.org (A.M. Kuchling)
Date: Tue, 28 Nov 2000 18:44:10 -0800
Subject: [Python-checkins] CVS: python/dist/src config.h.in,2.79,2.80 configure.in,1.179,1.180 configure,1.171,1.172
Message-ID: <200011290244.SAA16182@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src
In directory slayer.i.sourceforge.net:/tmp/cvs-serv15804

Modified Files:
config.h.in configure.in configure
Log Message:
Patch #102469: Check for glibc's getline() extension


Index: config.h.in
==================================================================RCS file: /cvsroot/python/python/dist/src/config.h.in,v
retrieving revision 2.79
retrieving revision 2.80
diff -C2 -r2.79 -r2.80
*** config.h.in 2000/11/08 20:22:59 2.79
--- config.h.in 2000/11/29 02:44:05 2.80
***************
*** 342,345 ****
--- 342,348 ----
#undef HAVE_GETHOSTBYNAME

+ /* Define if you have the getline function. */
+ #undef HAVE_GETLINE
+
/* Define if you have the getlogin function. */
#undef HAVE_GETLOGIN

Index: configure.in
==================================================================RCS file: /cvsroot/python/python/dist/src/configure.in,v
retrieving revision 1.179
retrieving revision 1.180
diff -C2 -r1.179 -r1.180
*** configure.in 2000/11/08 20:22:59 1.179
--- configure.in 2000/11/29 02:44:05 1.180
***************
*** 957,961 ****
AC_CHECK_FUNCS(alarm chown clock confstr ctermid ctermid_r execv \
flock fork fsync fdatasync fpathconf ftime ftruncate \
! getgroups getlogin getpeername getpid getpwent getwd \
kill link lstat mkfifo mktime mremap \
nice pathconf pause plock poll pthread_init \
--- 957,961 ----
AC_CHECK_FUNCS(alarm chown clock confstr ctermid ctermid_r execv \
flock fork fsync fdatasync fpathconf ftime ftruncate \
! getgroups getline getlogin getpeername getpid getpwent getwd \
kill link lstat mkfifo mktime mremap \
nice pathconf pause plock poll pthread_init \

Index: configure
==================================================================RCS file: /cvsroot/python/python/dist/src/configure,v
retrieving revision 1.171
retrieving revision 1.172
diff -C2 -r1.171 -r1.172
*** configure 2000/11/09 21:14:40 1.171
--- configure 2000/11/29 02:44:05 1.172
***************
*** 3963,3967 ****
for ac_func in alarm chown clock confstr ctermid ctermid_r execv \
flock fork fsync fdatasync fpathconf ftime ftruncate \
! getgroups getlogin getpeername getpid getpwent getwd \
kill link lstat mkfifo mktime mremap \
nice pathconf pause plock poll pthread_init \
--- 3963,3967 ----
for ac_func in alarm chown clock confstr ctermid ctermid_r execv \
flock fork fsync fdatasync fpathconf ftime ftruncate \
! getgroups getline getlogin getpeername getpid getpwent getwd \
kill link lstat mkfifo mktime mremap \
nice pathconf pause plock poll pthread_init \



From python-dev@python.org Wed Nov 29 02:53:26 2000
From: python-dev@python.org (A.M. Kuchling)
Date: Tue, 28 Nov 2000 18:53:26 -0800
Subject: [Python-checkins] CVS: python/dist/src/Objects fileobject.c,2.92,2.93
Message-ID: <200011290253.SAA19621@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Objects
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19411

Modified Files:
fileobject.c
Log Message:
Patch #102469: Use glibc's getline() extension when reading unbounded lines


Index: fileobject.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Objects/fileobject.c,v
retrieving revision 2.92
retrieving revision 2.93
diff -C2 -r2.92 -r2.93
*** fileobject.c 2000/11/13 19:48:22 2.92
--- fileobject.c 2000/11/29 02:53:22 2.93
***************
*** 646,656 ****
get_line(PyFileObject *f, int n)
{
! register FILE *fp;
register int c;
! register char *buf, *end;
size_t n1, n2;
PyObject *v;

! fp = f->f_fp;
n2 = n > 0 ? n : 100;
v = PyString_FromStringAndSize((char *)NULL, n2);
--- 646,683 ----
get_line(PyFileObject *f, int n)
{
! register FILE *fp = f->f_fp;
register int c;
! char *buf, *end;
size_t n1, n2;
PyObject *v;

! #ifdef HAVE_GETLINE
! /* Use GNU libc extension getline() for arbitrary-sized lines */
! if (n == 0) {
! size_t size = 0;
! buf = NULL;
! Py_BEGIN_ALLOW_THREADS
! n1 = getline(&buf, &size, fp);
! Py_END_ALLOW_THREADS
! if (n1 == -1) {
! clearerr(fp);
! if (PyErr_CheckSignals()) {
! return NULL;
! }
! if (n < 0 && feof(fp)) {
! PyErr_SetString(PyExc_EOFError,
! "EOF when reading a line");
! return NULL;
! }
! return PyString_FromStringAndSize(NULL, 0);
! }
! /* No error */
!
! v = PyString_FromStringAndSize(buf, n1);
! free(buf);
! return v;
! }
! #endif
!
n2 = n > 0 ? n : 100;
v = PyString_FromStringAndSize((char *)NULL, n2);



From python-dev@python.org Wed Nov 29 05:52:02 2000
From: python-dev@python.org (Tim Peters)
Date: Tue, 28 Nov 2000 21:52:02 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/tut tut.tex,1.121,1.122
Message-ID: <200011290552.VAA03882@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/tut
In directory slayer.i.sourceforge.net:/tmp/cvs-serv3842/python/dist/src/doc/tut

Modified Files:
tut.tex
Log Message:
Partial fix for SF bug 123730: extra backslash in tutorial.


Index: tut.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/tut/tut.tex,v
retrieving revision 1.121
retrieving revision 1.122
diff -C2 -r1.121 -r1.122
*** tut.tex 2000/11/27 06:38:04 1.121
--- tut.tex 2000/11/29 05:51:59 1.122
***************
*** 768,772 ****

\begin{verbatim}
! >>> u'Hello\\u0020World !'
u'Hello World !'
\end{verbatim}
--- 768,772 ----

\begin{verbatim}
! >>> u'Hello\u0020World !'
u'Hello World !'
\end{verbatim}



From python-dev@python.org Wed Nov 29 06:03:48 2000
From: python-dev@python.org (Fred L. Drake)
Date: Tue, 28 Nov 2000 22:03:48 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/tut tut.tex,1.122,1.123
Message-ID: <200011290603.WAA04837@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/tut
In directory slayer.i.sourceforge.net:/tmp/cvs-serv4830/tut

Modified Files:
tut.tex
Log Message:

Fix broken backslashes in Unicode strings section.

This closes bug #123730.


Index: tut.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/tut/tut.tex,v
retrieving revision 1.122
retrieving revision 1.123
diff -C2 -r1.122 -r1.123
*** tut.tex 2000/11/29 05:51:59 1.122
--- tut.tex 2000/11/29 06:03:45 1.123
***************
*** 772,776 ****
\end{verbatim}

! The escape sequence \code{\\u0020} indicates to insert the Unicode
character with the HEX ordinal 0x0020 (the space character) at the
given position.
--- 772,776 ----
\end{verbatim}

! The escape sequence \code{\e u0020} indicates to insert the Unicode
character with the HEX ordinal 0x0020 (the space character) at the
given position.
***************
*** 785,789 ****
strings. You have to prepend the string with a small 'r' to have
Python use the \emph{Raw-Unicode-Escape} encoding. It will only apply
! the above \code{\\uXXXX} conversion if there is an uneven number of
backslashes in front of the small 'u'.

--- 785,789 ----
strings. You have to prepend the string with a small 'r' to have
Python use the \emph{Raw-Unicode-Escape} encoding. It will only apply
! the above \code{\e uXXXX} conversion if there is an uneven number of
backslashes in front of the small 'u'.




From python-dev@python.org Wed Nov 29 06:10:25 2000
From: python-dev@python.org (Fred L. Drake)
Date: Tue, 28 Nov 2000 22:10:25 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib xmldomminidom.tex,NONE,1.1 xmldom.tex,1.1,1.2
Message-ID: <200011290610.WAA05331@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv5318/lib

Modified Files:
xmldom.tex
Added Files:
xmldomminidom.tex
Log Message:

Substantial re-organization of the DOM documentation. The abstract API
is now separated from the supplied standard implementation. Not all
interfaces are documented yet, but the structure is better set up to do
so.

There is still a lot to do here, but the shape of the documentation is
coming into line.


--- NEW FILE ---
\section{\module{xml.dom.minidom} ---
Lightweight DOM implementation}

\declaremodule{standard}{xml.dom.minidom}
\modulesynopsis{Lightweight Document Object Model (DOM) implementation.}
\moduleauthor{Paul Prescod}{paul@prescod.net}
\sectionauthor{Paul Prescod}{paul@prescod.net}
\sectionauthor{Martin v. L\"owis}{loewis@informatik.hu-berlin.de}

\versionadded{2.0}

\module{xml.dom.minidom} is a light-weight implementation of the
Document Object Model interface. It is intended to be
simpler than the full DOM and also significantly smaller.

DOM applications typically start by parsing some XML into a DOM. With
\module{xml.dom.minidom}, this is done through the parse functions:

\begin{verbatim}
from xml.dom.minidom import parse, parseString

dom1 = parse('c:\\temp\\mydata.xml') # parse an XML file by name

datasource = open('c:\\temp\\mydata.xml')
dom2 = parse(datasource) # parse an open file

dom3 = parseString('<myxml>Some data<empty/> some more data</myxml>')
\end{verbatim}

The parse function can take either a filename or an open file object.

\begin{funcdesc}{parse}{filename_or_file{, parser}}
Return a \class{Document} from the given input. \var{filename_or_file}
may be either a file name, or a file-like object. \var{parser}, if
given, must be a SAX2 parser object. This function will change the
document handler of the parser and activate namespace support; other
parser configuration (like setting an entity resolver) must have been
done in advance.
\end{funcdesc}

If you have XML in a string, you can use the
\function{parseString()} function instead:

\begin{funcdesc}{parseString}{string\optional{, parser}}
Return a \class{Document} that represents the \var{string}. This
method creates a \class{StringIO} object for the string and passes
that on to \function{parse}.
\end{funcdesc}

Both functions return a \class{Document} object representing the
content of the document.

You can also create a \class{Document} node merely by instantiating a
document object. Then you could add child nodes to it to populate
the DOM:

\begin{verbatim}
from xml.dom.minidom import Document

newdoc = Document()
newel = newdoc.createElement("some_tag")
newdoc.appendChild(newel)
\end{verbatim}

Once you have a DOM document object, you can access the parts of your
XML document through its properties and methods. These properties are
defined in the DOM specification. The main property of the document
object is the \member{documentElement} property. It gives you the
main element in the XML document: the one that holds all others. Here
is an example program:

\begin{verbatim}
dom3 = parseString("<myxml>Some data</myxml>")
assert dom3.documentElement.tagName == "myxml"
\end{verbatim}

When you are finished with a DOM, you should clean it up. This is
necessary because some versions of Python do not support garbage
collection of objects that refer to each other in a cycle. Until this
restriction is removed from all versions of Python, it is safest to
write your code as if cycles would not be cleaned up.

The way to clean up a DOM is to call its \method{unlink()} method:

\begin{verbatim}
dom1.unlink()
dom2.unlink()
dom3.unlink()
\end{verbatim}

\method{unlink()} is a \module{xml.dom.minidom}-specific extension to
the DOM API. After calling \method{unlink()} on a node, the node and
its descendents are essentially useless.

\begin{seealso}
\seetitle[http://www.w3.org/TR/REC-DOM-Level-1/]{Document Object
Model (DOM) Level 1 Specification}
{The W3C recommendation for the
DOM supported by \module{xml.dom.minidom}.}
\end{seealso}


\subsection{DOM objects \label{dom-objects}}

The definition of the DOM API for Python is given as part of the
\refmodule{xml.dom} module documentation. This section lists the
differences between the API and \refmodule{xml.dom.minidom}.


\begin{methoddesc}{unlink}{}
Break internal references within the DOM so that it will be garbage
collected on versions of Python without cyclic GC. Even when cyclic
GC is available, using this can make large amounts of memory available
sooner, so calling this on DOM objects as soon as they are no longer
needed is good practice. This only needs to be called on the
\class{Document} object, but may be called on child nodes to discard
children of that node.
\end{methoddesc}

\begin{methoddesc}{writexml}{writer}
Write XML to the writer object. The writer should have a
\method{write()} method which matches that of the file object
interface.
\end{methoddesc}

\begin{methoddesc}{toxml}{}
Return the XML that the DOM represents as a string.
\end{methoddesc}

The following standard DOM methods have special considerations with
\refmodule{xml.dom.minidom}:

\begin{methoddesc}{cloneNode}{deep}
Although this method was present in the version of
\refmodule{xml.dom.minidom} packaged with Python 2.0, it was seriously
broken. This has been corrected for subsequent releases.
\end{methoddesc}


\subsection{DOM Example \label{dom-example}}

This example program is a fairly realistic example of a simple
program. In this particular case, we do not take much advantage
of the flexibility of the DOM.

\begin{verbatim}
import xml.dom.minidom

document = """\
<slideshow>
<title>Demo slideshow</title>
<slide><title>Slide title</title>
<point>This is a demo</point>
<point>Of a program for processing slides</point>
</slide>

<slide><title>Another demo slide</title>
<point>It is important</point>
<point>To have more than</point>
<point>one slide</point>
</slide>
</slideshow>
"""

dom = xml.dom.minidom.parseString(document)

space = " "
def getText(nodelist):
rc = ""
for node in nodelist:
if node.nodeType == node.TEXT_NODE:
rc = rc + node.data
return rc

def handleSlideshow(slideshow):
print "<html>"
handleSlideshowTitle(slideshow.getElementsByTagName("title")[0])
slides = slideshow.getElementsByTagName("slide")
handleToc(slides)
handleSlides(slides)
print "</html>"

def handleSlides(slides):
for slide in slides:
handleSlide(slide)

def handleSlide(slide):
handleSlideTitle(slide.getElementsByTagName("title")[0])
handlePoints(slide.getElementsByTagName("point"))

def handleSlideshowTitle(title):
print "<title>%s</title>" % getText(title.childNodes)

def handleSlideTitle(title):
print "<h2>%s</h2>" % getText(title.childNodes)

def handlePoints(points):
print "<ul>"
for point in points:
handlePoint(point)
print "</ul>"

def handlePoint(point):
print "<li>%s</li>" % getText(point.childNodes)

def handleToc(slides):
for slide in slides:
title = slide.getElementsByTagName("title")[0]
print "<p>%s</p>" % getText(title.childNodes)

handleSlideshow(dom)
\end{verbatim}


\subsection{minidom and the DOM standard \label{minidom-and-dom}}

\refmodule{xml.dom.minidom} is basically a DOM 1.0-compatible DOM with
some DOM 2 features (primarily namespace features).

Usage of the DOM interface in Python is straight-forward. The
following mapping rules apply:

\begin{itemize}
\item Interfaces are accessed through instance objects. Applications
should not instantiate the classes themselves; they should use
the creator functions available on the \class{Document} object.
Derived interfaces support all operations (and attributes) from
the base interfaces, plus any new operations.

\item Operations are used as methods. Since the DOM uses only
\keyword{in} parameters, the arguments are passed in normal
order (from left to right). There are no optional
arguments. \keyword{void} operations return \code{None}.

\item IDL attributes map to instance attributes. For compatibility
with the OMG IDL language mapping for Python, an attribute
\code{foo} can also be accessed through accessor methods
\method{_get_foo()} and \method{_set_foo()}. \keyword{readonly}
attributes must not be changed; this is not enforced at
runtime.

\item The types \code{short int}, \code{unsigned int}, \code{unsigned
long long}, and \code{boolean} all map to Python integer
objects.

\item The type \code{DOMString} maps to Python strings.
\refmodule{xml.dom.minidom} supports either byte or Unicode
strings, but will normally produce Unicode strings. Attributes
of type \code{DOMString} may also be \code{None}.

\item \keyword{const} declarations map to variables in their
respective scope
(e.g. \code{xml.dom.minidom.Node.PROCESSING_INSTRUCTION_NODE});
they must not be changed.

\item \code{DOMException} is currently not supported in
\refmodule{xml.dom.minidom}. Instead,
\refmodule{xml.dom.minidom} uses standard Python exceptions such
as \exception{TypeError} and \exception{AttributeError}.

\item \class{NodeList} objects are implemented as Python's built-in
list type, so don't support the official API, but are much more
``Pythonic.''

\item \class{NamedNodeMap} is implemented by the class
\class{AttributeList}. This should not impact user code.
\end{itemize}


The following interfaces have no implementation in
\refmodule{xml.dom.minidom}:

\begin{itemize}
\item DOMTimeStamp

\item DocumentType (added for Python 2.1)

\item DOMImplementation (added for Python 2.1)

\item CharacterData

\item CDATASection

\item Notation

\item Entity

\item EntityReference

\item DocumentFragment
\end{itemize}

Most of these reflect information in the XML document that is not of
general utility to most DOM users.

Index: xmldom.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/xmldom.tex,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** xmldom.tex 2000/10/24 02:34:45 1.1
--- xmldom.tex 2000/11/29 06:10:22 1.2
***************
*** 1,8 ****
! \section{\module{xml.dom.minidom} ---
! The Document Object Model}

! \declaremodule{standard}{xml.dom.minidom}
! \modulesynopsis{Lightweight Document Object Model (DOM) implementation.}
! \moduleauthor{Paul Prescod}{paul@prescod.net}
\sectionauthor{Paul Prescod}{paul@prescod.net}
\sectionauthor{Martin v. L\"owis}{loewis@informatik.hu-berlin.de}
--- 1,7 ----
! \section{\module{xml.dom} ---
[...1058 lines suppressed...]
! \member{anotherValue} (\method{_get_anotherValue()} and
! \method{_set_anotherValue()}). The mapping, in particular, does not
! require that the IDL attributes are accessible as normal Python
! attributes: \code{\var{object}.someValue} is \emph{not} required to
! work, and may raise an \exception{AttributeError}.
!
! The Python DOM API, however, \emph{does} require that normal attribute
! access work. This means that the typical surrogates generated by
! Python IDL compilers are not likely to work, and wrapper objects may
! be needed on the client if the DOM objects are accessed via CORBA.
! While this does require some additional consideration for CORBA DOM
! clients, the implementers with experience using DOM over CORBA from
! Python do not consider this a problem. Attributes that are declared
! \keyword{readonly} may not restrict write access in all DOM
! implementations.
!
! Additionally, the accessor functions are not required. If provided,
! they should take the form defined by the Python IDL mapping, but
! these methods are considered unnecessary since the attributes are
! accessible directly from Python.



From python-dev@python.org Wed Nov 29 06:11:31 2000
From: python-dev@python.org (Fred L. Drake)
Date: Tue, 28 Nov 2000 22:11:31 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc Makefile.deps,1.49,1.50
Message-ID: <200011290611.WAA05501@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc
In directory slayer.i.sourceforge.net:/tmp/cvs-serv5488

Modified Files:
Makefile.deps
Log Message:

Added entries reflecting the separation of the abstract DOM documentation
and the implementation docs for xml.dom.minidom.


Index: Makefile.deps
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/Makefile.deps,v
retrieving revision 1.49
retrieving revision 1.50
diff -C2 -r1.49 -r1.50
*** Makefile.deps 2000/10/24 02:35:42 1.49
--- Makefile.deps 2000/11/29 06:11:28 1.50
***************
*** 172,175 ****
--- 172,176 ----
../lib/libpyexpat.tex \
../lib/xmldom.tex \
+ ../lib/xmldomminidom.tex \
../lib/xmlsax.tex \
../lib/xmlsaxhandler.tex \



From python-dev@python.org Wed Nov 29 06:11:32 2000
From: python-dev@python.org (Fred L. Drake)
Date: Tue, 28 Nov 2000 22:11:32 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib lib.tex,1.170,1.171
Message-ID: <200011290611.WAA05507@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv5488/lib

Modified Files:
lib.tex
Log Message:

Added entries reflecting the separation of the abstract DOM documentation
and the implementation docs for xml.dom.minidom.


Index: lib.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/lib.tex,v
retrieving revision 1.170
retrieving revision 1.171
diff -C2 -r1.170 -r1.171
*** lib.tex 2000/10/24 02:35:42 1.170
--- lib.tex 2000/11/29 06:11:29 1.171
***************
*** 236,239 ****
--- 236,240 ----
\input{libpyexpat}
\input{xmldom}
+ \input{xmldomminidom}
\input{xmlsax}
\input{xmlsaxhandler}



From python-dev@python.org Wed Nov 29 12:14:02 2000
From: python-dev@python.org (Guido van Rossum)
Date: Wed, 29 Nov 2000 04:14:02 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib/test test_unicode.py,1.22,1.23
Message-ID: <200011291214.EAA16730@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib/test
In directory slayer.i.sourceforge.net:/tmp/cvs-serv16711

Modified Files:
test_unicode.py
Log Message:
Slight improvement to Unicode test suite, inspired by patch #102563:
also test join method of 8-bit strings.

Also changed the test() function to (1) compare the types of the
expected and actual result, and (2) in verbose mode, print the repr()
of the output.


Index: test_unicode.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/test/test_unicode.py,v
retrieving revision 1.22
retrieving revision 1.23
diff -C2 -r1.22 -r1.23
*** test_unicode.py 2000/10/23 17:22:08 1.22
--- test_unicode.py 2000/11/29 12:13:59 1.23
***************
*** 11,15 ****
def test(method, input, output, *args):
if verbose:
! print '%s.%s%s =? %s... ' % (repr(input), method, args, output),
try:
f = getattr(input, method)
--- 11,15 ----
def test(method, input, output, *args):
if verbose:
! print '%s.%s%s =? %s... ' % (repr(input), method, args, repr(output)),
try:
f = getattr(input, method)
***************
*** 20,24 ****
else:
exc = None
! if value != output:
if verbose:
print 'no'
--- 20,24 ----
else:
exc = None
! if value != output or type(value) is not type(output):
if verbose:
print 'no'
***************
*** 71,87 ****
# join now works with any sequence type
class Sequence:
! def __init__(self): self.seq = 'wxyz'
def __len__(self): return len(self.seq)
def __getitem__(self, i): return self.seq[i]

test('join', u' ', u'a b c d', [u'a', u'b', u'c', u'd'])
test('join', u'', u'abcd', (u'a', u'b', u'c', u'd'))
! test('join', u' ', u'w x y z', Sequence())
test('join', u' ', TypeError, 7)
!
! class BadSeq(Sequence):
! def __init__(self): self.seq = [7, u'hello', 123L]
!
! test('join', u' ', TypeError, BadSeq())

result = u''
--- 71,89 ----
# join now works with any sequence type
class Sequence:
! def __init__(self, seq): self.seq = seq
def __len__(self): return len(self.seq)
def __getitem__(self, i): return self.seq[i]

test('join', u' ', u'a b c d', [u'a', u'b', u'c', u'd'])
+ test('join', u' ', u'a b c d', ['a', 'b', u'c', u'd'])
test('join', u'', u'abcd', (u'a', u'b', u'c', u'd'))
! test('join', u' ', u'w x y z', Sequence('wxyz'))
test('join', u' ', TypeError, 7)
! test('join', u' ', TypeError, Sequence([7, u'hello', 123L]))
! test('join', ' ', u'a b c d', [u'a', u'b', u'c', u'd'])
! test('join', ' ', u'a b c d', ['a', 'b', u'c', u'd'])
! test('join', '', u'abcd', (u'a', u'b', u'c', u'd'))
! test('join', ' ', u'w x y z', Sequence(u'wxyz'))
! test('join', ' ', TypeError, 7)

result = u''



From python-dev@python.org Wed Nov 29 15:35:37 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 29 Nov 2000 07:35:37 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0042.txt,1.45,1.46
Message-ID: <200011291535.HAA08224@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv8186

Modified Files:
pep-0042.txt
Log Message:

Added request that building from a source release should not attempt to
overwrite the distributed */graminit.* files.


Index: pep-0042.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0042.txt,v
retrieving revision 1.45
retrieving revision 1.46
diff -C2 -r1.45 -r1.46
*** pep-0042.txt 2000/11/14 20:27:54 1.45
--- pep-0042.txt 2000/11/29 15:35:24 1.46
***************
*** 272,275 ****
--- 272,283 ----
http://sourceforge.net/bugs/?funcÞtailbug&bug_id2215&group_idT70

+ - Building from source should not attempt to overwrite the
+ Include/graminit.h and Parser/graminit.c files, at least for
+ people downloading a source release rather than working from CVS
+ or snapshots. Some people find this a problem in unusual build
+ environments.
+
+ http://sourceforge.net/bugs/?funcÞtailbug&bug_id9221&group_idT70
+

Local Variables:



From python-dev@python.org Wed Nov 29 15:48:26 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 29 Nov 2000 07:48:26 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/api api.tex,1.98,1.99
Message-ID: <200011291548.HAA10168@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/api
In directory slayer.i.sourceforge.net:/tmp/cvs-serv10145/api

Modified Files:
api.tex
Log Message:

In the first discussion showing how to handle exceptions from C, make the
Python equivalent actually equivalent to the C code. Also, in the C code,
place the "goto" statements on a line by themselves for better visibility
of statements that affect control flow.

This closes bug #123398.


Index: api.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/api/api.tex,v
retrieving revision 1.98
retrieving revision 1.99
diff -C2 -r1.98 -r1.99
*** api.tex 2000/11/28 22:34:32 1.98
--- api.tex 2000/11/29 15:48:22 1.99
***************
*** 457,461 ****
except KeyError:
item = 0
! return item + 1
\end{verbatim}
\ttindex{incr_item()}
--- 457,461 ----
except KeyError:
item = 0
! dict[key] = item + 1
\end{verbatim}
\ttindex{incr_item()}
***************
*** 473,491 ****
if (item == NULL) {
/* Handle KeyError only: */
! if (!PyErr_ExceptionMatches(PyExc_KeyError)) goto error;

/* Clear the error and use zero: */
PyErr_Clear();
item = PyInt_FromLong(0L);
! if (item == NULL) goto error;
}
-
const_one = PyInt_FromLong(1L);
! if (const_one == NULL) goto error;

incremented_item = PyNumber_Add(item, const_one);
! if (incremented_item == NULL) goto error;

! if (PyObject_SetItem(dict, key, incremented_item) < 0) goto error;
rv = 0; /* Success */
/* Continue with cleanup code */
--- 473,495 ----
if (item == NULL) {
/* Handle KeyError only: */
! if (!PyErr_ExceptionMatches(PyExc_KeyError))
! goto error;

/* Clear the error and use zero: */
PyErr_Clear();
item = PyInt_FromLong(0L);
! if (item == NULL)
! goto error;
}
const_one = PyInt_FromLong(1L);
! if (const_one == NULL)
! goto error;

incremented_item = PyNumber_Add(item, const_one);
! if (incremented_item == NULL)
! goto error;

! if (PyObject_SetItem(dict, key, incremented_item) < 0)
! goto error;
rv = 0; /* Success */
/* Continue with cleanup code */



From python-dev@python.org Thu Nov 30 01:57:21 2000
From: python-dev@python.org (A.M. Kuchling)
Date: Wed, 29 Nov 2000 17:57:21 -0800
Subject: [Python-checkins] CVS: python/dist/src/Modules config.c.in,1.71,1.72
Message-ID: <200011300157.RAA12606@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Modules
In directory slayer.i.sourceforge.net:/tmp/cvs-serv12405

Modified Files:
config.c.in
Log Message:
Clarify two comments


Index: config.c.in
==================================================================RCS file: /cvsroot/python/python/dist/src/Modules/config.c.in,v
retrieving revision 1.71
retrieving revision 1.72
diff -C2 -r1.71 -r1.72
*** config.c.in 2000/07/23 00:02:15 1.71
--- config.c.in 2000/11/30 01:57:18 1.72
***************
*** 28,35 ****
/* -- ADDMODULE MARKER 2 -- */

! /* This module "lives in" with marshal.c */
{"marshal", PyMarshal_Init},

! /* This lives it with import.c */
{"imp", initimp},

--- 28,35 ----
/* -- ADDMODULE MARKER 2 -- */

! /* This module lives in marshal.c */
{"marshal", PyMarshal_Init},

! /* This lives in import.c */
{"imp", initimp},




From python-dev@python.org Thu Nov 30 05:22:47 2000
From: python-dev@python.org (Tim Peters)
Date: Wed, 29 Nov 2000 21:22:47 -0800
Subject: [Python-checkins] CVS: python/dist/src/Misc NEWS,1.81,1.82
Message-ID: <200011300522.VAA04955@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Misc
In directory slayer.i.sourceforge.net:/tmp/cvs-serv4750/python/dist/src/Misc

Modified Files:
NEWS
Log Message:
Fox for SF bug #123859: %[duxXo] long formats inconsistent.


Index: NEWS
==================================================================RCS file: /cvsroot/python/python/dist/src/Misc/NEWS,v
retrieving revision 1.81
retrieving revision 1.82
diff -C2 -r1.81 -r1.82
*** NEWS 2000/10/16 20:51:33 1.81
--- NEWS 2000/11/30 05:22:43 1.82
***************
*** 1,2 ****
--- 1,22 ----
+ What's New in Python 2.1 alpha 1?
+ ================================+
+ Core language, builtins, and interpreter
+
+ - %[duxXo] formats of negative Python longs now produce a sign
+ character. In 1.6 and earlier, they never produced a sign,
+ and raised an error if the value of the long was too large
+ to fit in a Python int. In 2.0, they produced a sign if and
+ only if too large to fit in an int. This was inconsistent
+ across platforms (because the size of an int varies across
+ platforms), and inconsistent with hex() and oct(). Example:
+
+ >>> "%x" % -0x42L
+ '-42' # in 2.1
+ 'ffffffbe' # in 2.0 and before, on 32-bit machines
+ >>> hex(-0x42L)
+ '-0x42L' # in all versions of Python
+
+
What's New in Python 2.0?
========================***************
*** 80,84 ****
Modules/main.c. This warning will be fixed for Python 2.1.

! - Fixed configure to add -threads argument during linking on OSF1.

Tools and other miscellany
--- 100,104 ----
Modules/main.c. This warning will be fixed for Python 2.1.

! - Fixed configure to add -threads argument during linking on OSF1.

Tools and other miscellany
***************
*** 89,93 ****
also be backwards compatible with Python 1.5.2; the compiler will
always generate code for the version of the interpreter it runs
! under.

What's new in 2.0 release candidate 1 (since beta 2)?
--- 109,113 ----
also be backwards compatible with Python 1.5.2; the compiler will
always generate code for the version of the interpreter it runs
! under.

What's new in 2.0 release candidate 1 (since beta 2)?
***************
*** 144,156 ****
performed on a closed object, an exception is raised. The truncate
method now accepts a position argument and readline accepts a size
! argument.

- There were many changes made to the linuxaudiodev module and its
test suite; as a result, a short, unexpected audio sample should now
! play when the regression test is run.

Note that this module is named poorly, because it should work
correctly on any platform that supports the Open Sound System
! (OSS).

The module now raises exceptions when errors occur instead of
--- 164,176 ----
performed on a closed object, an exception is raised. The truncate
method now accepts a position argument and readline accepts a size
! argument.

- There were many changes made to the linuxaudiodev module and its
test suite; as a result, a short, unexpected audio sample should now
! play when the regression test is run.

Note that this module is named poorly, because it should work
correctly on any platform that supports the Open Sound System
! (OSS).

The module now raises exceptions when errors occur instead of
***************
*** 201,205 ****
- configure now accepts a --with-suffix option that specifies the
executable suffix. This is useful for builds on Cygwin and Mac OS
! X, for example.

- The mmap.PAGESIZE constant is now initialized using sysconf when
--- 221,225 ----
- configure now accepts a --with-suffix option that specifies the
executable suffix. This is useful for builds on Cygwin and Mac OS
! X, for example.

- The mmap.PAGESIZE constant is now initialized using sysconf when
***************
*** 212,216 ****

- Darwin (Mac OS X): Initial support for static builds on this
! platform.

- BeOS: A number of changes were made to the build and installation
--- 232,236 ----

- Darwin (Mac OS X): Initial support for static builds on this
! platform.

- BeOS: A number of changes were made to the build and installation
***************
*** 255,259 ****

- Better error message when continue is found in try statement in a
! loop.


--- 275,279 ----

- Better error message when continue is found in try statement in a
! loop.


***************
*** 346,350 ****
is followed by whitespace.

! - StringIO: Size hint in readlines() is now supported as documented.

- struct: Check ranges for bytes and shorts.
--- 366,370 ----
is followed by whitespace.

! - StringIO: Size hint in readlines() is now supported as documented.

- struct: Check ranges for bytes and shorts.
***************
*** 420,424 ****
PyArg_Parse() special cases "s#" for Unicode objects; it returns a
pointer to the default encoded string data instead of to the raw
! UTF-16.

- Py_BuildValue accepts B format (for bgen-generated code).
--- 440,444 ----
PyArg_Parse() special cases "s#" for Unicode objects; it returns a
pointer to the default encoded string data instead of to the raw
! UTF-16.

- Py_BuildValue accepts B format (for bgen-generated code).
***************
*** 449,453 ****

- On Unix, create .pyc/.pyo files with O_EXCL flag to avoid a race
! condition.


--- 469,473 ----

- On Unix, create .pyc/.pyo files with O_EXCL flag to avoid a race
! condition.


***************
*** 476,480 ****
- freeze: The modulefinder now works with 2.0 opcodes.

! - IDLE:
Move hackery of sys.argv until after the Tk instance has been
created, which allows the application-specific Tkinter
--- 496,500 ----
- freeze: The modulefinder now works with 2.0 opcodes.

! - IDLE:
Move hackery of sys.argv until after the Tk instance has been
created, which allows the application-specific Tkinter



From python-dev@python.org Thu Nov 30 05:22:49 2000
From: python-dev@python.org (Tim Peters)
Date: Wed, 29 Nov 2000 21:22:49 -0800
Subject: [Python-checkins] CVS: python/dist/src/Objects stringobject.c,2.93,2.94 unicodeobject.c,2.66,2.67
Message-ID: <200011300522.VAA04974@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Objects
In directory slayer.i.sourceforge.net:/tmp/cvs-serv4750/python/dist/src/Objects

Modified Files:
stringobject.c unicodeobject.c
Log Message:
Fox for SF bug #123859: %[duxXo] long formats inconsistent.


Index: stringobject.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Objects/stringobject.c,v
retrieving revision 2.93
retrieving revision 2.94
diff -C2 -r2.93 -r2.94
*** stringobject.c 2000/11/27 18:46:26 2.93
--- stringobject.c 2000/11/30 05:22:44 2.94
***************
*** 2898,2905 ****
if (c == 'i')
c = 'd';
! if (PyLong_Check(v) && PyLong_AsLong(v) == -1
! && PyErr_Occurred()) {
! /* Too big for a C long. */
! PyErr_Clear();
temp = _PyString_FormatLong(v, flags,
prec, c, &pbuf, &len);
--- 2898,2902 ----
if (c == 'i')
c = 'd';
! if (PyLong_Check(v)) {
temp = _PyString_FormatLong(v, flags,
prec, c, &pbuf, &len);

Index: unicodeobject.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Objects/unicodeobject.c,v
retrieving revision 2.66
retrieving revision 2.67
diff -C2 -r2.66 -r2.67
*** unicodeobject.c 2000/10/03 20:45:26 2.66
--- unicodeobject.c 2000/11/30 05:22:44 2.67
***************
*** 5021,5027 ****
if (c == 'i')
c = 'd';
! if (PyLong_Check(v) && PyLong_AsLong(v) == -1
! && PyErr_Occurred()) {
! PyErr_Clear();
temp = formatlong(v, flags, prec, c);
if (!temp)
--- 5021,5025 ----
if (c == 'i')
c = 'd';
! if (PyLong_Check(v)) {
temp = formatlong(v, flags, prec, c);
if (!temp)



From python-dev@python.org Thu Nov 30 05:23:16 2000
From: python-dev@python.org (Tim Peters)
Date: Wed, 29 Nov 2000 21:23:16 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib/test test_format.py,1.2,1.3
Message-ID: <200011300523.VAA05050@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib/test
In directory slayer.i.sourceforge.net:/tmp/cvs-serv4750/python/dist/src/Lib/test

Modified Files:
test_format.py
Log Message:
Fox for SF bug #123859: %[duxXo] long formats inconsistent.


Index: test_format.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/test/test_format.py,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** test_format.py 2000/09/21 05:43:11 1.2
--- test_format.py 2000/11/30 05:22:41 1.3
***************
*** 64,72 ****
testboth("%d", 100000000000L, "100000000000")

- # Make sure big is too big to fit in a 64-bit int, else the unbounded
- # int formatting will be sidestepped on some machines. That's vital,
- # because bitwise (x, X, o) formats of regular Python ints never
- # produce a sign ("+" or "-").
-
big = 123456789012345678901234567890L
testboth("%d", big, "123456789012345678901234567890")
--- 64,67 ----
***************
*** 164,165 ****
--- 159,176 ----
# base marker shouldn't change that
testboth("%0#34.33o", big, "0012345670123456701234567012345670")
+
+ # Some small ints, in both Python int and long flavors).
+ testboth("%d", 42, "42")
+ testboth("%d", -42, "-42")
+ testboth("%d", 42L, "42")
+ testboth("%d", -42L, "-42")
+
+ testboth("%x", 0x42, "42")
+ # testboth("%x", -0x42, "ffffffbe") # Alas, that's specific to 32-bit machines
+ testboth("%x", 0x42L, "42")
+ testboth("%x", -0x42L, "-42")
+
+ testboth("%o", 042, "42")
+ # testboth("%o", -042, "37777777736") # Alas, that's specific to 32-bit machines
+ testboth("%o", 042L, "42")
+ testboth("%o", -042L, "-42")



From python-dev@python.org Thu Nov 30 07:10:03 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 29 Nov 2000 23:10:03 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc ACKS,1.9,1.10
Message-ID: <200011300710.XAA17837@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc
In directory slayer.i.sourceforge.net:/tmp/cvs-serv17811

Modified Files:
ACKS
Log Message:
Added name.

Index: ACKS
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/ACKS,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -r1.9 -r1.10
*** ACKS 2000/11/17 19:05:10 1.9
--- ACKS 2000/11/30 07:09:59 1.10
***************
*** 145,148 ****
--- 145,149 ----
Peter Stoehr
Mark Summerfield
+ Reuben Sumner
Martijn Vries
Charles G. Waldman



From python-dev@python.org Thu Nov 30 07:12:57 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 29 Nov 2000 23:12:57 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib libwinreg.tex,1.5,1.6
Message-ID: <200011300712.XAA18031@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv18017/lib

Modified Files:
libwinreg.tex
Log Message:

Use small tables instead of bare \item markers to describe the contents
of return tuples. The bare \item took advantage of an implementation
detail when formatting in LaTeX, and was just wrong when generating HTML.
It also broke the XML conversion scripts, since there was no enclosing
list-like environment to contain them.


Index: libwinreg.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/libwinreg.tex,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -r1.5 -r1.6
*** libwinreg.tex 2000/08/01 23:49:50 1.5
--- libwinreg.tex 2000/11/30 07:12:54 1.6
***************
*** 127,138 ****

The result is a tuple of 3 items:
- \item[value_name]
- A string that identifies the value name
- \item[value_data]
- An object that holds the value data, and whose type depends
- on the underlying registry type.
- \item[data_type] is an integer that identifies the type of the
- value data.

\end{funcdesc}

--- 127,138 ----

The result is a tuple of 3 items:

+ \begin{tableii}{c|p{3in}}{code}{Index}{Meaning}
+ \lineii{0}{A string that identifies the value name}
+ \lineii{1}{An object that holds the value data, and whose
+ type depends on the underlying registry type}
+ \lineii{2}{An integer that identifies the type of the value data}
+ \end{tableii}
+
\end{funcdesc}

***************
*** 219,229 ****

The result is a tuple of 3 items:
! \item[num_subkeys]
! An integer that identifies the number of sub keys this key has.
! \item[num_values]
! An integer that identifies the number of values this key has.
! \item [last_modified]
! A long integer that identifies when the key was last modified (if available)
! as 100's of nanoseconds since Jan 1, 1600.
\end{funcdesc}

--- 219,229 ----

The result is a tuple of 3 items:
!
! \begin{tableii}{c|p{3in}}{code}{Index}{Meaning}
! \lineii{0}{An integer giving the number of sub keys this key has.}
! \lineii{1}{An integer giving the number of values this key has.}
! \lineii{2}{A long integer giving when the key was last modified (if
! available) as 100's of nanoseconds since Jan 1, 1600.}
! \end{tableii}
\end{funcdesc}

***************
*** 257,264 ****

The result is a tuple of 2 items:
! \item [value]
! The value of the registry item.
! \item [type_id]
! An integer that identifies the registry type for this value.
\end{funcdesc}

--- 257,265 ----

The result is a tuple of 2 items:
!
! \begin{tableii}{c|p{3in}}{code}{Index}{Meaning}
! \lineii{0}{The value of the registry item.}
! \lineii{1}{An integer giving the registry type for this value.}
! \end{tableii}
\end{funcdesc}

***************
*** 295,310 ****
is associated.

! \var{type} is an integer that specifies the type of the data. Currently this
! must be \constant{REG_SZ}, meaning only strings are supported.
! Use the \function{SetValueEx()} function for support for other data types.

\var{value} is a string that specifies the new value.

! If the key specified by the \var{sub_key} parameter does not exist,
the SetValue function creates it.

Value lengths are limited by available memory. Long values (more than
! 2048 bytes) should be stored as files with the filenames stored in
! the configuration registry. This helps the registry perform efficiently.

The key identified by the \var{key} parameter must have been
--- 296,313 ----
is associated.

! \var{type} is an integer that specifies the type of the data.
! Currently this must be \constant{REG_SZ}, meaning only strings are
! supported. Use the \function{SetValueEx()} function for support for
! other data types.

\var{value} is a string that specifies the new value.

! If the key specified by the \var{sub_key} parameter does not exist,
the SetValue function creates it.

Value lengths are limited by available memory. Long values (more than
! 2048 bytes) should be stored as files with the filenames stored in
! the configuration registry. This helps the registry perform
! efficiently.

The key identified by the \var{key} parameter must have been
***************
*** 314,319 ****

\begin{funcdesc}{SetValueEx}{key, value_name, reserved, type, value}
! Stores data in the value field of an open registry key.
!
\var{key} is an already open key, or one of the predefined
\constant{HKEY_*} constants.
--- 317,322 ----

\begin{funcdesc}{SetValueEx}{key, value_name, reserved, type, value}
! Stores data in the value field of an open registry key.
!
\var{key} is an already open key, or one of the predefined
\constant{HKEY_*} constants.
***************
*** 321,354 ****
\var{sub_key} is a string that names the subkey with which the
value is associated.
!
\var{type} is an integer that specifies the type of the data.
! This should be one of:
! \item[\constant{REG_BINARY}]
! Binary data in any form.
! \item[\constant{REG_DWORD}]
! A 32-bit number.
! \item[\constant{REG_DWORD_LITTLE_ENDIAN}]
! A 32-bit number in little-endian format.
! \item[\constant{REG_DWORD_BIG_ENDIAN}]
! A 32-bit number in big-endian format.
! \item[\constant{REG_EXPAND_SZ}]
! A null-terminated string that contains unexpanded references
! to environment variables (for example, \code{\%PATH\%})
! \item[\constant{REG_LINK}]
! A Unicode symbolic link.
! \item[\constant{REG_MULTI_SZ}]
! A sequence (eg, list, sequence) of null-terminated strings,
! terminated by two null characters. (Note that Python handles
! this termination automatically)
! \item[\constant{REG_NONE}]
! No defined value type.
! \item[\constant{REG_RESOURCE_LIST}]
! A device-driver resource list.
! \item[\constant{REG_SZ}]
! A null-terminated string.

\var{reserved} can be anything - zero is always passed to the
API.
!
\var{value} is a string that specifies the new value.

--- 324,350 ----
\var{sub_key} is a string that names the subkey with which the
value is associated.
!
\var{type} is an integer that specifies the type of the data.
! This should be one of the following constants defined in this module:

+ \begin{tableii}{l|p{3in}}{constant}{Constant}{Meaning}
+ \lineii{REG_BINARY}{Binary data in any form.}
+ \lineii{REG_DWORD}{A 32-bit number.}
+ \lineii{REG_DWORD_LITTLE_ENDIAN}{A 32-bit number in little-endian format.}
+ \lineii{REG_DWORD_BIG_ENDIAN}{A 32-bit number in big-endian format.}
+ \lineii{REG_EXPAND_SZ}{Null-terminated string containing references
+ to environment variables (\samp{\%PATH\%}).}
+ \lineii{REG_LINK}{A Unicode symbolic link.}
+ \lineii{REG_MULTI_SZ}{A sequence of null-terminated strings,
+ terminated by two null characters. (Python handles
+ this termination automatically.)}
+ \lineii{REG_NONE}{No defined value type.}
+ \lineii{REG_RESOURCE_LIST}{A device-driver resource list.}
+ \lineii{REG_SZ}{A null-terminated string.}
+ \end{tableii}
+
\var{reserved} can be anything - zero is always passed to the
API.
!
\var{value} is a string that specifies the new value.

***************
*** 367,371 ****


! \subsection{Registry handle objects \label{handle-object}}

This object wraps a Windows HKEY object, automatically closing it when
--- 363,367 ----


! \subsection{Registry Handle Objects \label{handle-object}}

This object wraps a Windows HKEY object, automatically closing it when



From python-dev@python.org Thu Nov 30 07:14:02 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 29 Nov 2000 23:14:02 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib liblocale.tex,1.20,1.21
Message-ID: <200011300714.XAA18203@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv18192/lib

Modified Files:
liblocale.tex
Log Message:

Use a table to describe the keys to the locale information dictionary;
this is slightly easier to read than the list environment that had been
used.


Index: liblocale.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/liblocale.tex,v
retrieving revision 1.20
retrieving revision 1.21
diff -C2 -r1.20 -r1.21
*** liblocale.tex 2000/11/17 19:09:34 1.20
--- liblocale.tex 2000/11/30 07:13:58 1.21
***************
*** 46,50 ****
\begin{verbatim}
import locale
! locale.setlocale(locale.LC_ALL,"")
\end{verbatim}

--- 46,50 ----
\begin{verbatim}
import locale
! locale.setlocale(locale.LC_ALL, '')
\end{verbatim}

***************
*** 62,126 ****
This dictionary has the following strings as keys:

! \begin{itemize}
! \item
! \code{'decimal_point'} specifies the decimal point used in floating
! point number representations for the \constant{LC_NUMERIC}
! category.
!
! \item
! \code{'groupin'} is a sequence of numbers specifying at which
! relative positions the \code{'thousands_sep'} is expected. If the
! sequence is terminated with \constant{CHAR_MAX}, no further
! grouping is performed. If the sequence terminates with a \code{0},
! the last group size is repeatedly used.
!
! \item
! \code{'thousands_sep'} is the character used between groups.
!
! \item
! \code{'int_curr_symbol'} specifies the international currency
! symbol from the \constant{LC_MONETARY} category.
!
! \item
! \code{'currency_symbol'} is the local currency symbol.
!
! \item
! \code{'mon_decimal_point'} is the decimal point used in monetary
! values.
!
! \item
! \code{'mon_thousands_sep'} is the separator for grouping of
! monetary values.
!
! \item
! \code{'mon_grouping'} has the same format as the \code{'grouping'}
! key; it is used for monetary values.
!
! \item
! \code{'positive_sign'} and \code{'negative_sign'} gives the sign
! used for positive and negative monetary quantities.
!
! \item
! \code{'int_frac_digits'} and \code{'frac_digits'} specify the number
! of fractional digits used in the international and local
! formatting of monetary values.
!
! \item
! \code{'p_cs_precedes'} and \code{'n_cs_precedes'} specifies whether
! the currency symbol precedes the value for positive or negative
! values.
!
! \item
! \code{'p_sep_by_space'} and \code{'n_sep_by_space'} specifies
! whether there is a space between the positive or negative value
! and the currency symbol.
!
! \item
! \code{'p_sign_posn'} and \code{'n_sign_posn'} indicate how the
! sign should be placed for positive and negative monetary values.
! \end{itemize}

! The possible values for \code{p_sign_posn} and
! \code{n_sign_posn} are given below.

\begin{tableii}{c|l}{code}{Value}{Explanation}
--- 62,101 ----
This dictionary has the following strings as keys:

! \begin{tableiii}{l|l|p{3in}}{constant}{Key}{Category}{Meaning}
! \lineiii{LC_NUMERIC}{\code{'decimal_point'}}
! {Decimal point character.}
! \lineiii{}{\code{'grouping'}}
! {Sequence of numbers specifying which relative positions
! the \code{'thousands_sep'} is expected. If the sequence is
! terminated with \constant{CHAR_MAX}, no further grouping
! is performed. If the sequence terminates with a \code{0},
! the last group size is repeatedly used.}
! \lineiii{}{\code{'thousands_sep'}}
! {Character used between groups.}\hline
! \lineiii{LC_MONETARY}{\code{'int_curr_symbol'}}
! {International currency symbol.}
! \lineiii{}{\code{'currency_symbol'}}
! {Local currency symbol.}
! \lineiii{}{\code{'mon_decimal_point'}}
! {Decimal point used for monetary values.}
! \lineiii{}{\code{'mon_thousands_sep'}}
! {Group separator used for monetary values.}
! \lineiii{}{\code{'mon_grouping'}}
! {Equivalent to \code{'grouping'}, used for monetary
! values.}
! \lineiii{}{\code{'positive_sign'}}
! {Symbol used to annotate a positive monetary value.}
! \lineiii{}{\code{'negative_sign'}}
! {Symbol used to annotate a nnegative monetary value.}
! \lineiii{}{\code{'frac_digits'}}
! {Number of fractional digits used in local formatting
! of monetary values.}
! \lineiii{}{\code{'int_frac_digits'}}
! {Number of fractional digits used in international
! formatting of monetary values.}
! \end{tableiii}

! The possible values for \code{'p_sign_posn'} and
! \code{'n_sign_posn'} are given below.

\begin{tableii}{c|l}{code}{Value}{Explanation}
***************
*** 130,134 ****
\lineii{3}{The sign should immediately precede the value.}
\lineii{4}{The sign should immediately follow the value.}
! \lineii{LC_MAX}{Nothing is specified in this locale.}
\end{tableii}
\end{funcdesc}
--- 105,109 ----
\lineii{3}{The sign should immediately precede the value.}
\lineii{4}{The sign should immediately follow the value.}
! \lineii{\constant{LC_MAX}}{Nothing is specified in this locale.}
\end{tableii}
\end{funcdesc}
***************
*** 290,297 ****
import locale
loc = locale.setlocale(locale.LC_ALL) # get current locale
! >>> locale.setlocale(locale.LC_ALL, "de") # use German locale
! >>> locale.strcoll("f\344n", "foo") # compare a string containing an umlaut
! >>> locale.setlocale(locale.LC_ALL, "") # use user's preferred locale
! >>> locale.setlocale(locale.LC_ALL, "C") # use default (C) locale
locale.setlocale(locale.LC_ALL, loc) # restore saved locale
\end{verbatim}
--- 265,272 ----
import locale
loc = locale.setlocale(locale.LC_ALL) # get current locale
! >>> locale.setlocale(locale.LC_ALL, 'de') # use German locale
! >>> locale.strcoll('f\344n', 'foo') # compare a string containing an umlaut
! >>> locale.setlocale(locale.LC_ALL, '') # use user's preferred locale
! >>> locale.setlocale(locale.LC_ALL, 'C') # use default (C) locale
locale.setlocale(locale.LC_ALL, loc) # restore saved locale
\end{verbatim}
***************
*** 309,313 ****
matter what the user's preferred locale is. The program must
explicitly say that it wants the user's preferred locale settings by
! calling \code{setlocale(LC_ALL, "")}.

It is generally a bad idea to call \function{setlocale()} in some library
--- 284,288 ----
matter what the user's preferred locale is. The program must
explicitly say that it wants the user's preferred locale settings by
! calling \code{setlocale(LC_ALL, '')}.

It is generally a bad idea to call \function{setlocale()} in some library



From python-dev@python.org Thu Nov 30 07:17:32 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 29 Nov 2000 23:17:32 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/perl python.perl,1.91,1.92
Message-ID: <200011300717.XAA18477@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/perl
In directory slayer.i.sourceforge.net:/tmp/cvs-serv18462/perl

Modified Files:
python.perl
Log Message:

A few small refinements to the table building code.


Index: python.perl
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/perl/python.perl,v
retrieving revision 1.91
retrieving revision 1.92
diff -C2 -r1.91 -r1.92
*** python.perl 2000/10/30 06:24:56 1.91
--- python.perl 2000/11/30 07:17:27 1.92
***************
*** 1019,1022 ****
--- 1019,1025 ----
$font = 'tt class="member"';
}
+ elsif ($font eq 'class') {
+ $font = 'tt class="class"';
+ }
elsif ($font eq 'constant') {
$font = 'tt class="constant"';
***************
*** 1069,1073 ****
$efont =~ s/ .*>/>/;
}
! return ($font, $sfont, $efont);
}

--- 1072,1076 ----
$efont =~ s/ .*>/>/;
}
! return ($sfont, $efont);
}

***************
*** 1106,1114 ****
my $c2 = next_argument();
s/[\s\n]+//;
! my($font,$sfont,$efont) = get_table_col1_fonts();
$c2 = '&nbsp;' if ($c2 eq '');
my($c1align,$c2align) = split('\|', $aligns);
my $padding = '';
! if ($c1align =~ /align="right"/) {
$padding = '&nbsp;';
}
--- 1109,1117 ----
my $c2 = next_argument();
s/[\s\n]+//;
! my($sfont,$efont) = get_table_col1_fonts();
$c2 = '&nbsp;' if ($c2 eq '');
my($c1align,$c2align) = split('\|', $aligns);
my $padding = '';
! if ($c1align =~ /align="right"/ || $c1 eq '') {
$padding = '&nbsp;';
}
***************
*** 1156,1164 ****
my $c3 = next_argument();
s/[\s\n]+//;
! my($font,$sfont,$efont) = get_table_col1_fonts();
$c3 = '&nbsp;' if ($c3 eq '');
my($c1align,$c2align,$c3align) = split('\|', $aligns);
my $padding = '';
! if ($c1align =~ /align="right"/) {
$padding = '&nbsp;';
}
--- 1159,1167 ----
my $c3 = next_argument();
s/[\s\n]+//;
! my($sfont,$efont) = get_table_col1_fonts();
$c3 = '&nbsp;' if ($c3 eq '');
my($c1align,$c2align,$c3align) = split('\|', $aligns);
my $padding = '';
! if ($c1align =~ /align="right"/ || $c1 eq '') {
$padding = '&nbsp;';
}
***************
*** 1211,1219 ****
my $c4 = next_argument();
s/[\s\n]+//;
! my($font,$sfont,$efont) = get_table_col1_fonts();
$c4 = '&nbsp;' if ($c4 eq '');
my($c1align,$c2align,$c3align,$c4align) = split('\|', $aligns);
my $padding = '';
! if ($c1align =~ /align="right"/) {
$padding = '&nbsp;';
}
--- 1214,1222 ----
my $c4 = next_argument();
s/[\s\n]+//;
! my($sfont,$efont) = get_table_col1_fonts();
$c4 = '&nbsp;' if ($c4 eq '');
my($c1align,$c2align,$c3align,$c4align) = split('\|', $aligns);
my $padding = '';
! if ($c1align =~ /align="right"/ || $c1 eq '') {
$padding = '&nbsp;';
}



From python-dev@python.org Thu Nov 30 07:39:02 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 29 Nov 2000 23:39:02 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/tools push-docs.sh,1.2,1.3 update-docs.sh,1.2,1.3
Message-ID: <200011300739.XAA20920@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/tools
In directory slayer.i.sourceforge.net:/tmp/cvs-serv20907/tools

Modified Files:
push-docs.sh update-docs.sh
Log Message:

Adjust to allow an explanation of the changes to be included in the
notification message.


Index: push-docs.sh
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/tools/push-docs.sh,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** push-docs.sh 2000/10/24 19:59:55 1.2
--- push-docs.sh 2000/11/30 07:38:58 1.3
***************
*** 4,7 ****
--- 4,13 ----
# update-docs.sh script unpacks them into their final destination.

+ TARGET=python.sourceforge.net:/home/users/fdrake
+
+ if [ "$1" ] ; then
+ scp "$1" $TARGET/python-docs-update.txt || exit $?
+ fi
+
START="`pwd`"
MYDIR="`dirname $0`"
***************
*** 15,17 ****
RELEASE=`grep '^RELEASE=' Makefile | sed 's|RELEASE=||'`
make --no-print-directory HTMLDIR="$HTMLDIR" bziphtml
! scp "html-$RELEASE.tar.bz2" python.sourceforge.net:/home/users/fdrake/python-docs-update.tar.bz2
--- 21,23 ----
RELEASE=`grep '^RELEASE=' Makefile | sed 's|RELEASE=||'`
make --no-print-directory HTMLDIR="$HTMLDIR" bziphtml
! scp "html-$RELEASE.tar.bz2" $TARGET/python-docs-update.tar.bz2

Index: update-docs.sh
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/tools/update-docs.sh,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** update-docs.sh 2000/10/29 13:21:45 1.2
--- update-docs.sh 2000/11/30 07:38:59 1.3
***************
*** 12,16 ****
fi

! UPDATES=/home/users/fdrake/python-docs-update.tar.bz2

if [ -f "$UPDATES" ] ; then
--- 12,17 ----
fi

! UPDATES=$HOME/python-docs-update.tar.bz2
! INFO=$HOME/python-docs-update.txt

if [ -f "$UPDATES" ] ; then
***************
*** 21,24 ****
--- 22,26 ----
(bzip2 -dc "$UPDATES" | tar xf -) || exit $?
rm "$UPDATES" || exit $?
+ EXPLANATION="`cat $INFO`"
Mail -s '[development doc updates]' \
python-dev@python.org doc-sig@python.org \
***************
*** 27,30 ****
--- 29,35 ----

http://python.sourceforge.net/devel-docs/
+
+ $EXPLANATION
EOF
+ rm -f $HOME/python-docs-update.txt
fi



From python-dev@python.org Thu Nov 30 12:31:07 2000
From: python-dev@python.org (Moshe Zadka)
Date: Thu, 30 Nov 2000 04:31:07 -0800
Subject: [Python-checkins] CVS: python/dist/src/Objects dictobject.c,2.65,2.66
Message-ID: <200011301231.EAA22228@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Objects
In directory slayer.i.sourceforge.net:/tmp/cvs-serv21539/Objects

Modified Files:
dictobject.c
Log Message:
Added .first{item,value,key}() to dictionaries.
Complete with docos and tests.
OKed by Guido.


Index: dictobject.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Objects/dictobject.c,v
retrieving revision 2.65
retrieving revision 2.66
diff -C2 -r2.65 -r2.66
*** dictobject.c 2000/09/01 23:29:27 2.65
--- dictobject.c 2000/11/30 12:31:00 2.66
***************
*** 710,713 ****
--- 710,782 ----

static PyObject *
+ dict_firstkey(register dictobject *mp, PyObject *args)
+ {
+ register int i;
+
+ if (!PyArg_NoArgs(args))
+ return NULL;
+ if (mp->ma_used == 0) {
+ PyErr_SetString(PyExc_ValueError, "empty dictionary");
+ return NULL;
+ }
+ for (i = 0; i < mp->ma_size; i++) {
+ if (mp->ma_table[i].me_value != NULL) {
+ PyObject *key = mp->ma_table[i].me_key;
+ Py_INCREF(key);
+ return key;
+ }
+ }
+ }
+
+ static PyObject *
+ dict_firstvalue(register dictobject *mp, PyObject *args)
+ {
+ register int i;
+
+ if (!PyArg_NoArgs(args))
+ return NULL;
+ if (mp->ma_used == 0) {
+ PyErr_SetString(PyExc_ValueError, "empty dictionary");
+ return NULL;
+ }
+ for (i = 0; i < mp->ma_size; i++) {
+ if (mp->ma_table[i].me_value != NULL) {
+ PyObject *value = mp->ma_table[i].me_value;
+ Py_INCREF(value);
+ return value;
+ }
+ }
+ }
+
+ static PyObject *
+ dict_firstitem(register dictobject *mp, PyObject *args)
+ {
+ register int i;
+
+ if (!PyArg_NoArgs(args))
+ return NULL;
+ if (mp->ma_used == 0) {
+ PyErr_SetString(PyExc_ValueError, "empty dictionary");
+ return NULL;
+ }
+ for (i = 0; i < mp->ma_size; i++) {
+ if (mp->ma_table[i].me_value != NULL) {
+ PyObject *key = mp->ma_table[i].me_key;
+ PyObject *value = mp->ma_table[i].me_value;
+ PyObject *item = PyTuple_New(2);
+ if (item == NULL) {
+ return NULL;
+ }
+ Py_INCREF(key);
+ PyTuple_SetItem(item, 0, key);
+ Py_INCREF(value);
+ PyTuple_SetItem(item, 1, value);
+ return item;
+ }
+ }
+ }
+
+
+ static PyObject *
dict_keys(register dictobject *mp, PyObject *args)
{
***************
*** 1163,1166 ****
--- 1232,1238 ----
{"items", (PyCFunction)dict_items},
{"values", (PyCFunction)dict_values},
+ {"firstkey", (PyCFunction)dict_firstkey},
+ {"firstitem", (PyCFunction)dict_firstitem},
+ {"firstvalue", (PyCFunction)dict_firstvalue},
{"update", (PyCFunction)dict_update},
{"clear", (PyCFunction)dict_clear},



From python-dev@python.org Thu Nov 30 12:31:07 2000
From: python-dev@python.org (Moshe Zadka)
Date: Thu, 30 Nov 2000 04:31:07 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib libstdtypes.tex,1.42,1.43
Message-ID: <200011301231.EAA22229@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv21539/Doc/lib

Modified Files:
libstdtypes.tex
Log Message:
Added .first{item,value,key}() to dictionaries.
Complete with docos and tests.
OKed by Guido.


Index: libstdtypes.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/libstdtypes.tex,v
retrieving revision 1.42
retrieving revision 1.43
diff -C2 -r1.42 -r1.43
*** libstdtypes.tex 2000/11/17 19:44:14 1.42
--- libstdtypes.tex 2000/11/30 12:31:02 1.43
***************
*** 784,789 ****
--- 784,793 ----
\ttindex{items()}
\ttindex{keys()}
+ \ttindex{firstitem()}
+ \ttindex{firstkey()}
\ttindex{update()}
\ttindex{values()}
+ \ttindex{firstvalue()}
+ \ttindex{setdefault()}
\ttindex{get()}}

***************
*** 805,813 ****
--- 809,825 ----
{a copy of \var{a}'s list of (\var{key}, \var{value}) pairs}
{(2)}
+ \lineiii{\var{a}.firstitem()}
+ {a (\var{key}, \var{value}) pair, the first one in \var{a}.items()}
+ {(2)}
\lineiii{\var{a}.keys()}{a copy of \var{a}'s list of keys}{(2)}
+ \lineiii{\var{a}.firstkey()}
+ {the first element in \var{a}.keys()}
+ {(2)}
\lineiii{\var{a}.update(\var{b})}
{\code{for k in \var{b}.keys(): \var{a}[k] = \var{b}[k]}}
{(3)}
\lineiii{\var{a}.values()}{a copy of \var{a}'s list of values}{(2)}
+ \lineiii{\var{a}.firstvalue()}
+ {the first element in \var{a}.values()}
\lineiii{\var{a}.get(\var{k}\optional{, \var{x}})}
{\code{\var{a}[\var{k}]} if \code{\var{a}.has_key(\var{k})},



From python-dev@python.org Thu Nov 30 12:31:08 2000
From: python-dev@python.org (Moshe Zadka)
Date: Thu, 30 Nov 2000 04:31:08 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib/test test_types.py,1.15,1.16
Message-ID: <200011301231.EAA22239@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib/test
In directory slayer.i.sourceforge.net:/tmp/cvs-serv21539/Lib/test

Modified Files:
test_types.py
Log Message:
Added .first{item,value,key}() to dictionaries.
Complete with docos and tests.
OKed by Guido.


Index: test_types.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/test/test_types.py,v
retrieving revision 1.15
retrieving revision 1.16
diff -C2 -r1.15 -r1.16
*** test_types.py 2000/10/23 17:22:08 1.15
--- test_types.py 2000/11/30 12:31:03 1.16
***************
*** 266,267 ****
--- 266,273 ----
if len(d['key']) <> 2:
raise TestFailed, 'present {} setdefault, w/ 2nd arg'
+ if d.keys()[0] != d.firstkey():
+ raise TestFailed, 'first key is not first in keys'
+ if d.values()[0] != d.firstvalue():
+ raise TestFailed, 'first value is not first in values'
+ if d.items()[0] != d.firstitem():
+ raise TestFailed, 'first item is not first in items'



From python-dev@python.org Thu Nov 30 13:34:07 2000
From: python-dev@python.org (Fred L. Drake, Jr.)
Date: Thu, 30 Nov 2000 08:34:07 -0500 (EST)
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib libstdtypes.tex,1.42,1.43
In-Reply-To: <200011301231.EAA22229@slayer.i.sourceforge.net>
References: <200011301231.EAA22229@slayer.i.sourceforge.net>
Message-ID: <14886.22351.263040.575270@cj42289-a.reston1.va.home.com>

Moshe Zadka writes:
+ \lineiii{\var{a}.firstitem()}
+ {a (\var{key}, \var{value}) pair, the first one in \var{a}.items()}
+ {(2)}
So what happens if the mapping is empty? That's needed for all
three.
You should also update UserDict.


-Fred

--
Fred L. Drake, Jr. <fdrake at acm.org>
PythonLabs at Digital Creations



From python-dev@python.org Thu Nov 30 13:43:10 2000
From: python-dev@python.org (Moshe Zadka)
Date: Thu, 30 Nov 2000 15:43:10 +0200 (IST)
Subject: [Python-Dev] Re: [Python-checkins] CVS: python/dist/src/Doc/lib
libstdtypes.tex,1.42,1.43
In-Reply-To: <14886.22351.263040.575270@cj42289-a.reston1.va.home.com>
Message-ID: <Pine.GSO.4.10.10011301542250.4645-100000@sundial>
On Thu, 30 Nov 2000, Fred L. Drake, Jr. wrote:


Moshe Zadka writes:
+ \lineiii{\var{a}.firstitem()}
+ {a (\var{key}, \var{value}) pair, the first one in \var{a}.items()}
+ {(2)}
So what happens if the mapping is empty? That's needed for all
three.
You should also update UserDict.
Right. Will be done soon.
--
Moshe Zadka <moshez@math.huji.ac.il> -- 95855124
http://advogato.org/person/moshez



From python-dev@python.org Thu Nov 30 13:43:48 2000
From: python-dev@python.org (Fred L. Drake, Jr.)
Date: Thu, 30 Nov 2000 08:43:48 -0500 (EST)
Subject: [Python-Dev] Re: [Python-checkins] CVS: python/dist/src/Doc/lib
libstdtypes.tex,1.42,1.43
In-Reply-To: <Pine.GSO.4.10.10011301542250.4645-100000@sundial>
References: <14886.22351.263040.575270@cj42289-a.reston1.va.home.com>
<Pine.GSO.4.10.10011301542250.4645-100000@sundial>
Message-ID: <14886.22932.50399.879012@cj42289-a.reston1.va.home.com>

Moshe Zadka writes:
Right. Will be done soon.
Given Guido's surprise at the checkin, you might want to wait until
the discussions are over and just make one set of checkins, with all
the results. ;)
Hmm. I need to think about adding version annotations to those
tables of operations on built-in types.


-Fred

--
Fred L. Drake, Jr. <fdrake at acm.org>
PythonLabs at Digital Creations



From python-dev@python.org Thu Nov 30 18:27:53 2000
From: python-dev@python.org (A.M. Kuchling)
Date: Thu, 30 Nov 2000 10:27:53 -0800
Subject: [Python-checkins] CVS: python/dist/src/Objects fileobject.c,2.93,2.94
Message-ID: <200011301827.KAA32318@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Objects
In directory slayer.i.sourceforge.net:/tmp/cvs-serv32241

Modified Files:
fileobject.c
Log Message:
Only use getline() when compiling using glibc


Index: fileobject.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Objects/fileobject.c,v
retrieving revision 2.93
retrieving revision 2.94
diff -C2 -r2.93 -r2.94
*** fileobject.c 2000/11/29 02:53:22 2.93
--- fileobject.c 2000/11/30 18:27:50 2.94
***************
*** 652,656 ****
PyObject *v;

! #ifdef HAVE_GETLINE
/* Use GNU libc extension getline() for arbitrary-sized lines */
if (n == 0) {
--- 652,656 ----
PyObject *v;

! #if defined(HAVE_GETLINE) && defined(_GNU_SOURCE)
/* Use GNU libc extension getline() for arbitrary-sized lines */
if (n == 0) {



From python-dev@python.org Thu Nov 30 19:30:23 2000
From: python-dev@python.org (Moshe Zadka)
Date: Thu, 30 Nov 2000 11:30:23 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib/test test_types.py,1.16,1.17
Message-ID: <200011301930.LAA06222@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib/test
In directory slayer.i.sourceforge.net:/tmp/cvs-serv5381/Lib/test

Modified Files:
test_types.py
Log Message:
Backing out my changes.
Improved version coming soon to a Source Forge near you!


Index: test_types.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/test/test_types.py,v
retrieving revision 1.16
retrieving revision 1.17
diff -C2 -r1.16 -r1.17
*** test_types.py 2000/11/30 12:31:03 1.16
--- test_types.py 2000/11/30 19:30:21 1.17
***************
*** 266,273 ****
if len(d['key']) <> 2:
raise TestFailed, 'present {} setdefault, w/ 2nd arg'
- if d.keys()[0] != d.firstkey():
- raise TestFailed, 'first key is not first in keys'
- if d.values()[0] != d.firstvalue():
- raise TestFailed, 'first value is not first in values'
- if d.items()[0] != d.firstitem():
- raise TestFailed, 'first item is not first in items'
--- 266,267 ----



From python-dev@python.org Thu Nov 30 19:30:23 2000
From: python-dev@python.org (Moshe Zadka)
Date: Thu, 30 Nov 2000 11:30:23 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib libstdtypes.tex,1.43,1.44
Message-ID: <200011301930.LAA06219@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv5381/Doc/lib

Modified Files:
libstdtypes.tex
Log Message:
Backing out my changes.
Improved version coming soon to a Source Forge near you!


Index: libstdtypes.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/libstdtypes.tex,v
retrieving revision 1.43
retrieving revision 1.44
diff -C2 -r1.43 -r1.44
*** libstdtypes.tex 2000/11/30 12:31:02 1.43
--- libstdtypes.tex 2000/11/30 19:30:20 1.44
***************
*** 784,793 ****
\ttindex{items()}
\ttindex{keys()}
- \ttindex{firstitem()}
- \ttindex{firstkey()}
\ttindex{update()}
\ttindex{values()}
- \ttindex{firstvalue()}
- \ttindex{setdefault()}
\ttindex{get()}}

--- 784,789 ----
***************
*** 809,825 ****
{a copy of \var{a}'s list of (\var{key}, \var{value}) pairs}
{(2)}
- \lineiii{\var{a}.firstitem()}
- {a (\var{key}, \var{value}) pair, the first one in \var{a}.items()}
- {(2)}
\lineiii{\var{a}.keys()}{a copy of \var{a}'s list of keys}{(2)}
- \lineiii{\var{a}.firstkey()}
- {the first element in \var{a}.keys()}
- {(2)}
\lineiii{\var{a}.update(\var{b})}
{\code{for k in \var{b}.keys(): \var{a}[k] = \var{b}[k]}}
{(3)}
\lineiii{\var{a}.values()}{a copy of \var{a}'s list of values}{(2)}
- \lineiii{\var{a}.firstvalue()}
- {the first element in \var{a}.values()}
\lineiii{\var{a}.get(\var{k}\optional{, \var{x}})}
{\code{\var{a}[\var{k}]} if \code{\var{a}.has_key(\var{k})},
--- 805,813 ----



From python-dev@python.org Thu Nov 30 19:30:23 2000
From: python-dev@python.org (Moshe Zadka)
Date: Thu, 30 Nov 2000 11:30:23 -0800
Subject: [Python-checkins] CVS: python/dist/src/Objects dictobject.c,2.66,2.67
Message-ID: <200011301930.LAA06218@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Objects
In directory slayer.i.sourceforge.net:/tmp/cvs-serv5381/Objects

Modified Files:
dictobject.c
Log Message:
Backing out my changes.
Improved version coming soon to a Source Forge near you!


Index: dictobject.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Objects/dictobject.c,v
retrieving revision 2.66
retrieving revision 2.67
diff -C2 -r2.66 -r2.67
*** dictobject.c 2000/11/30 12:31:00 2.66
--- dictobject.c 2000/11/30 19:30:19 2.67
***************
*** 710,782 ****

static PyObject *
- dict_firstkey(register dictobject *mp, PyObject *args)
- {
- register int i;
-
- if (!PyArg_NoArgs(args))
- return NULL;
- if (mp->ma_used == 0) {
- PyErr_SetString(PyExc_ValueError, "empty dictionary");
- return NULL;
- }
- for (i = 0; i < mp->ma_size; i++) {
- if (mp->ma_table[i].me_value != NULL) {
- PyObject *key = mp->ma_table[i].me_key;
- Py_INCREF(key);
- return key;
- }
- }
- }
-
- static PyObject *
- dict_firstvalue(register dictobject *mp, PyObject *args)
- {
- register int i;
-
- if (!PyArg_NoArgs(args))
- return NULL;
- if (mp->ma_used == 0) {
- PyErr_SetString(PyExc_ValueError, "empty dictionary");
- return NULL;
- }
- for (i = 0; i < mp->ma_size; i++) {
- if (mp->ma_table[i].me_value != NULL) {
- PyObject *value = mp->ma_table[i].me_value;
- Py_INCREF(value);
- return value;
- }
- }
- }
-
- static PyObject *
- dict_firstitem(register dictobject *mp, PyObject *args)
- {
- register int i;
-
- if (!PyArg_NoArgs(args))
- return NULL;
- if (mp->ma_used == 0) {
- PyErr_SetString(PyExc_ValueError, "empty dictionary");
- return NULL;
- }
- for (i = 0; i < mp->ma_size; i++) {
- if (mp->ma_table[i].me_value != NULL) {
- PyObject *key = mp->ma_table[i].me_key;
- PyObject *value = mp->ma_table[i].me_value;
- PyObject *item = PyTuple_New(2);
- if (item == NULL) {
- return NULL;
- }
- Py_INCREF(key);
- PyTuple_SetItem(item, 0, key);
- Py_INCREF(value);
- PyTuple_SetItem(item, 1, value);
- return item;
- }
- }
- }
-
-
- static PyObject *
dict_keys(register dictobject *mp, PyObject *args)
{
--- 710,713 ----
***************
*** 1232,1238 ****
{"items", (PyCFunction)dict_items},
{"values", (PyCFunction)dict_values},
- {"firstkey", (PyCFunction)dict_firstkey},
- {"firstitem", (PyCFunction)dict_firstitem},
- {"firstvalue", (PyCFunction)dict_firstvalue},
{"update", (PyCFunction)dict_update},
{"clear", (PyCFunction)dict_clear},
--- 1163,1166 ----



From python-dev@python.org Wed Nov 1 02:51:30 2000
From: python-dev@python.org (Tim Peters)
Date: Tue, 31 Oct 2000 18:51:30 -0800
Subject: [Python-checkins] CVS: python/dist/src/Tools/scripts ndiff.py,1.4,1.5
Message-ID: <200011010251.SAA26869@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Tools/scripts
In directory slayer.i.sourceforge.net:/tmp/cvs-serv26632/python/dist/src/tools/scripts

Modified Files:
ndiff.py
Log Message:
Hack ndiff to display lines w/ leading tabs more intuitively. This synchs
ndiff w/ a custom version I made for Guido during the pre-2.0 freeze.


Index: ndiff.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Tools/scripts/ndiff.py,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -r1.4 -r1.5
*** ndiff.py 1999/03/28 17:55:32 1.4
--- ndiff.py 2000/11/01 02:51:27 1.5
***************
*** 1,6 ****
#! /usr/bin/env python

! # Module ndiff version 1.4.0
! # Released to the public domain 27-Mar-1999,
# by Tim Peters (tim_one@email.msn.com).

--- 1,6 ----
#! /usr/bin/env python

! # Module ndiff version 1.5.0
! # Released to the public domain 08-Oct-2000,
# by Tim Peters (tim_one@email.msn.com).

***************
*** 29,40 ****

Lines beginning with "? " attempt to guide the eye to intraline
! differences, and were not present in either input file. These lines can
! be confusing if the source files contain tab characters.

The first file can be recovered by retaining only lines that begin with
" " or "- ", and deleting those 2-character prefixes; use ndiff with -r1.

! The second file can be recovered similarly, but by retaining only " "
! and "+ " lines; use ndiff with -r2; or, on Unix, the second file can be
recovered by piping the output through

--- 29,40 ----

Lines beginning with "? " attempt to guide the eye to intraline
! differences, and were not present in either input file. These lines can be
! confusing if the source files contain tab characters.

The first file can be recovered by retaining only lines that begin with
" " or "- ", and deleting those 2-character prefixes; use ndiff with -r1.

! The second file can be recovered similarly, but by retaining only " " and
! "+ " lines; use ndiff with -r2; or, on Unix, the second file can be
recovered by piping the output through

***************
*** 44,48 ****
"""

! __version__ = 1, 4, 0

# SequenceMatcher tries to compute a "human-friendly diff" between
--- 44,48 ----
"""

! __version__ = 1, 5, 0

# SequenceMatcher tries to compute a "human-friendly diff" between
***************
*** 515,520 ****
btags = btags + ' ' * (la - lb)
combined = map(lambda x,y: _combine[x+y], atags, btags)
! print '-', aelt, '+', belt, '?', \
! string.rstrip(string.join(combined, ''))
else:
# the synch pair is identical
--- 515,519 ----
btags = btags + ' ' * (la - lb)
combined = map(lambda x,y: _combine[x+y], atags, btags)
! printq(aelt, belt, string.rstrip(string.join(combined, '')))
else:
# the synch pair is identical
***************
*** 532,535 ****
--- 531,550 ----
elif blo < bhi:
dump('+', b, blo, bhi)
+
+ # Crap to deal with leading tabs in "?" output. Can hurt, but will
+ # probably help most of the time.
+
+ def printq(aline, bline, qline):
+ common = min(count_leading(aline, "\t"),
+ count_leading(bline, "\t"))
+ common = min(common, count_leading(qline[:common], " "))
+ qline = "\t" * common + qline[common:]
+ print '-', aline, '+', bline, '?', qline
+
+ def count_leading(line, ch):
+ i, n = 0, len(line)
+ while i < n and line[i] == ch:
+ i += 1
+ return i

def fail(msg):



From python-dev@python.org Wed Nov 1 03:12:37 2000
From: python-dev@python.org (Fred L. Drake)
Date: Tue, 31 Oct 2000 19:12:37 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib libasyncore.tex,1.5,1.6
Message-ID: <200011010312.TAA28493@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv28479

Modified Files:
libasyncore.tex
Log Message:

Typo: writeable --> writable
Reported by Erno Kuusela <erno@iki.fi>.


Index: libasyncore.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/libasyncore.tex,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -r1.5 -r1.6
*** libasyncore.tex 2000/07/16 19:01:09 1.5
--- libasyncore.tex 2000/11/01 03:12:34 1.6
***************
*** 104,108 ****
\end{methoddesc}

! \begin{methoddesc}{writeable}{}
Each time through the \method{select()} loop, the set of sockets
is scanned, and this method is called to see if there is any
--- 104,108 ----
\end{methoddesc}

! \begin{methoddesc}{writable}{}
Each time through the \method{select()} loop, the set of sockets
is scanned, and this method is called to see if there is any
***************
*** 188,192 ****
print data

! def writeable(self):
return (len(self.buffer) > 0)

--- 188,192 ----
print data

! def writable(self):
return (len(self.buffer) > 0)




From python-dev@python.org Wed Nov 1 19:59:15 2000
From: python-dev@python.org (A.M. Kuchling)
Date: Wed, 1 Nov 2000 11:59:15 -0800
Subject: [Python-checkins] CVS: python/dist/src/Modules _cursesmodule.c,2.39,2.40
Message-ID: <200011011959.LAA13600@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Modules
In directory slayer.i.sourceforge.net:/tmp/cvs-serv13420

Modified Files:
_cursesmodule.c
Log Message:
Patch from Randall Hopper to fix PR #116172, "curses module fails to
build on SGI":
* Check for 'sgi' preprocessor symbol, not '__sgi__'
* Surround individual character macros with #ifdef's, instead of making them
all rely on STRICT_SYSV_CURSES


Index: _cursesmodule.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Modules/_cursesmodule.c,v
retrieving revision 2.39
retrieving revision 2.40
diff -C2 -r2.39 -r2.40
*** _cursesmodule.c 2000/09/01 03:46:16 2.39
--- _cursesmodule.c 2000/11/01 19:59:12 2.40
***************
*** 79,83 ****
#endif

! #if defined(__sgi__) || defined(__sun__)
#define STRICT_SYSV_CURSES /* Don't use ncurses extensions */
typedef chtype attr_t; /* No attr_t type is available */
--- 79,91 ----
#endif

! #ifdef sgi
! /* This prototype is in <term.h>, but including this header #defines
! many common symbols (such as "lines") which breaks the curses
! module in other ways. So the code will just specify an explicit
! prototype here. */
! extern char *tigetstr(char *);
! #endif
!
! #if defined(sgi) || defined(__sun__)
#define STRICT_SYSV_CURSES /* Don't use ncurses extensions */
typedef chtype attr_t; /* No attr_t type is available */
***************
*** 1740,1750 ****
SetDictInt("ACS_SBSB", (ACS_VLINE));
SetDictInt("ACS_SSSS", (ACS_PLUS));
! #ifndef STRICT_SYSV_CURSES
! /* The following are never available with strict SYSV curses */
SetDictInt("ACS_S3", (ACS_S3));
SetDictInt("ACS_LEQUAL", (ACS_LEQUAL));
SetDictInt("ACS_GEQUAL", (ACS_GEQUAL));
SetDictInt("ACS_PI", (ACS_PI));
SetDictInt("ACS_NEQUAL", (ACS_NEQUAL));
SetDictInt("ACS_STERLING", (ACS_STERLING));
#endif
--- 1748,1772 ----
SetDictInt("ACS_SBSB", (ACS_VLINE));
SetDictInt("ACS_SSSS", (ACS_PLUS));
!
! /* The following are never available with strict SYSV curses */
! #ifdef ACS_S3
SetDictInt("ACS_S3", (ACS_S3));
+ #endif
+ #ifdef ACS_S7
+ SetDictInt("ACS_S7", (ACS_S7));
+ #endif
+ #ifdef ACS_LEQUAL
SetDictInt("ACS_LEQUAL", (ACS_LEQUAL));
+ #endif
+ #ifdef ACS_GEQUAL
SetDictInt("ACS_GEQUAL", (ACS_GEQUAL));
+ #endif
+ #ifdef ACS_PI
SetDictInt("ACS_PI", (ACS_PI));
+ #endif
+ #ifdef ACS_NEQUAL
SetDictInt("ACS_NEQUAL", (ACS_NEQUAL));
+ #endif
+ #ifdef ACS_STERLING
SetDictInt("ACS_STERLING", (ACS_STERLING));
#endif
***************
*** 2271,2280 ****
SetDictInt("A_CHARTEXT", A_CHARTEXT);
SetDictInt("A_COLOR", A_COLOR);
! #ifndef STRICT_SYSV_CURSES
SetDictInt("A_HORIZONTAL", A_HORIZONTAL);
SetDictInt("A_LEFT", A_LEFT);
SetDictInt("A_LOW", A_LOW);
SetDictInt("A_RIGHT", A_RIGHT);
SetDictInt("A_TOP", A_TOP);
SetDictInt("A_VERTICAL", A_VERTICAL);
#endif
--- 2293,2314 ----
SetDictInt("A_CHARTEXT", A_CHARTEXT);
SetDictInt("A_COLOR", A_COLOR);
!
! /* The following are never available with strict SYSV curses */
! #ifdef A_HORIZONTAL
SetDictInt("A_HORIZONTAL", A_HORIZONTAL);
+ #endif
+ #ifdef A_LEFT
SetDictInt("A_LEFT", A_LEFT);
+ #endif
+ #ifdef A_LOW
SetDictInt("A_LOW", A_LOW);
+ #endif
+ #ifdef A_RIGHT
SetDictInt("A_RIGHT", A_RIGHT);
+ #endif
+ #ifdef A_TOP
SetDictInt("A_TOP", A_TOP);
+ #endif
+ #ifdef A_VERTICAL
SetDictInt("A_VERTICAL", A_VERTICAL);
#endif



From python-dev@python.org Wed Nov 1 22:03:03 2000
From: python-dev@python.org (Moshe Zadka)
Date: Wed, 1 Nov 2000 14:03:03 -0800
Subject: [Python-checkins] CVS: python/nondist/sf-html sf-faq.html,1.15,1.16
Message-ID: <200011012203.OAA03403@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/sf-html
In directory slayer.i.sourceforge.net:/tmp/cvs-serv3265

Modified Files:
sf-faq.html
Log Message:
Changed description of bug report procedures.


Index: sf-faq.html
==================================================================RCS file: /cvsroot/python/python/nondist/sf-html/sf-faq.html,v
retrieving revision 1.15
retrieving revision 1.16
diff -C2 -r1.15 -r1.16
*** sf-faq.html 2000/08/25 07:55:48 1.15
--- sf-faq.html 2000/11/01 22:03:00 1.16
***************
*** 58,62 ****
<ol>
<li><a href="#b1">Where can I submit/view bugs for Python?</a></li>
! <li><a href="#b2">How do I use jitterbug?</a></li>
</ol>

--- 58,62 ----
<ol>
<li><a href="#b1">Where can I submit/view bugs for Python?</a></li>
! <li><a href="#b2">How do I use the sourceforge bug manager?</a></li>
</ol>

***************
*** 447,471 ****

<h4>A:</h4>
! As of now [25-Jul-200] the Python project does not use SourceForge's bug
! tracking facility. This may change when there is a way to import the existing
! jitterbug database. The jitterbug database can be accessed through the
! following interface:

- <blockquote>
- <tt><a
- href="http://www.python.org/python-bugs">http://www.python.org/python-bugs</a></tt></blockquote>
-
<h3><a name="b1" id="b1"></a>6.1.:</h3>

! <h4>Q: How do I use jitterbug?</h4>

<h4>A:</h4>
! To get the list of open bugs click on <tt>open</tt> (hidden between the second
! last and the last horizontal ruler).

! <p>To get a list of the bugs which are related to some area, enter an
! appropriate regular expression and press "Select Messages". Then select
! <tt>open</tt> (or whatever category you would like to view) as described
! above.</p>

<h1><a name="appendix" id="appendix"></a>A. Appendix</h1>
--- 447,465 ----

<h4>A:</h4>
! The Python project uses SourceForge's bug
! tracking facility. Go to
! <a href="http://sourceforge.net/bugs/?group_idT70">http://sourceforge.net/bugs/?group_idT70</a> for all bug management needs.

<h3><a name="b1" id="b1"></a>6.1.:</h3>

! <h4>Q: How do I use the sourceforge bug manager?</h4>

<h4>A:</h4>
! By default, you will see the list of all Open bugs. You can change
! which bugs you're viewing by selecting the assigned_to/status/area/type
! select boxes.

! <p>To submit a bug, use the "Submit a Bug" link, near the top of the page.
! </p>

<h1><a name="appendix" id="appendix"></a>A. Appendix</h1>
***************
*** 601,606 ****
submission. The patch manager is for <b>patches</b> only; if you have a
problem or suggestion but don't know how to write the code for it, use the
! <a href="http://www.python.org/search/search_bugs.html">Python Bugs
! List</a> instead. The bugs list is searchable; if you have a problem and
you're not sure if it has been reported or fixed already, this is the
first place to look. (There used to be a separate TODO list; we now prefer
--- 595,600 ----
submission. The patch manager is for <b>patches</b> only; if you have a
problem or suggestion but don't know how to write the code for it, use the
! <a href="#b1">bug reporting mechanism</a> instead.
! The bugs list is searchable; if you have a problem and
you're not sure if it has been reported or fixed already, this is the
first place to look. (There used to be a separate TODO list; we now prefer
***************
*** 609,615 ****
way.</b> When adding the patch, be sure to set the "<b>Category</b>" field
to "<b>documentation</b>". For documentation errors without patches,
! please use the <a
! href="http://www.python.org/search/search_bugs.html">Python Bugs List</a>
! instead.</li>
<li>We like context diffs. We grudgingly accept unified diffs. <b>Straight
("ed-style") diffs are right out!</b> If you don't know how to generate
--- 603,607 ----
way.</b> When adding the patch, be sure to set the "<b>Category</b>" field
to "<b>documentation</b>". For documentation errors without patches,
! please use the <a href="#b1">bug reporting mechanism</a>.</li>
<li>We like context diffs. We grudgingly accept unified diffs. <b>Straight
("ed-style") diffs are right out!</b> If you don't know how to generate



From python-dev@python.org Wed Nov 1 22:28:46 2000
From: python-dev@python.org (Moshe Zadka)
Date: Wed, 1 Nov 2000 14:28:46 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0042.txt,1.40,1.41
Message-ID: <200011012228.OAA05685@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv5018

Modified Files:
pep-0042.txt
Log Message:
- Added PyX_Update() addition to the API request (120081)
- Added vars() enhancement request (120082)


Index: pep-0042.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0042.txt,v
retrieving revision 1.40
retrieving revision 1.41
diff -C2 -r1.40 -r1.41
*** pep-0042.txt 2000/10/30 20:48:44 1.40
--- pep-0042.txt 2000/11/01 22:28:42 1.41
***************
*** 81,84 ****
--- 81,95 ----
http://sourceforge.net/bugs/?funcÞtailbug&bug_id6405&group_idT70

+ - The C API should include a PyDict_Update() function which takes a
+ dictionary as its first argument, and an arbitrary mapping as its
+ second. Similarly there should probably be a PyMapping_Update() in the
+ abstract API (and several other dictionary methods in there too).
+
+ http://sourceforge.net/bugs/?funcÞtailbug&bug_id2081&group_idT70
+
+ - Inside a function, vars() should include both locals() and globals()
+
+ http://sourceforge.net/bugs/?funcÞtailbug&bug_id2082&group_idT70
+
Standard Library




From python-dev@python.org Wed Nov 1 22:37:39 2000
From: python-dev@python.org (Thomas Wouters)
Date: Wed, 1 Nov 2000 14:37:39 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0204.txt,1.4,1.5
Message-ID: <200011012237.OAA06642@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv6200

Modified Files:
pep-0204.txt
Log Message:

Update this PEP to current, harsh, reality. It's been rejected :) If at all
possible, the reasoning should be extended to include the real reasons it
was rejected -- this is just guesswork from my side. (This means you, Guido,
or anyone who can channel Guido enough to call himself Guido.)



Index: pep-0204.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0204.txt,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -r1.4 -r1.5
*** pep-0204.txt 2000/08/23 05:41:57 1.4
--- pep-0204.txt 2000/11/01 22:37:36 1.5
***************
*** 3,7 ****
Version: $Revision$
Author: thomas@xs4all.net (Thomas Wouters)
! Status: Draft
Type: Standards Track
Python-Version: 2.0
--- 3,7 ----
Version: $Revision$
Author: thomas@xs4all.net (Thomas Wouters)
! Status: Rejected
Type: Standards Track
Python-Version: 2.0
***************
*** 263,267 ****
to be classified: are they part of the API, or should they be
made private functions?
!

References:
--- 263,281 ----
to be classified: are they part of the API, or should they be
made private functions?
!
!
! Rejection
!
! After careful consideration, and a period of meditation, this
! proposal has been rejected. The open issues, as well as some
! confusion between ranges and slice syntax, raised enough questions
! for Guido not to accept it for Python 2.0, and later to reject the
! proposal altogether. The new syntax and its intentions were deemed
! not obvious enough.
!
! [ TBD: Guido, ammend/confirm this, please. Preferably both; this
! is a PEP, it should contain *all* the reasons for rejection
! and/or reconsideration, for future reference. ]
!

References:



From python-dev@python.org Wed Nov 1 22:43:45 2000
From: python-dev@python.org (Thomas Wouters)
Date: Wed, 1 Nov 2000 14:43:45 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0204.txt,1.5,1.6
Message-ID: <200011012243.OAA07233@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv7213

Modified Files:
pep-0204.txt
Log Message:

Add Copyright.



Index: pep-0204.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0204.txt,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -r1.5 -r1.6
*** pep-0204.txt 2000/11/01 22:37:36 1.5
--- pep-0204.txt 2000/11/01 22:43:42 1.6
***************
*** 279,282 ****
--- 279,287 ----


+ Copyright
+
+ This document has been placed in the Public Domain.
+
+
References:




From python-dev@python.org Wed Nov 1 23:45:50 2000
From: python-dev@python.org (Thomas Wouters)
Date: Wed, 1 Nov 2000 15:45:50 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep2html.py,1.15,1.16
Message-ID: <200011012345.PAA12044@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv12019

Modified Files:
pep2html.py
Log Message:

Add -u and --user options to the call to getopt, to make them actually work.



Index: pep2html.py
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep2html.py,v
retrieving revision 1.15
retrieving revision 1.16
diff -C2 -r1.15 -r1.16
*** pep2html.py 2000/09/08 15:31:36 1.15
--- pep2html.py 2000/11/01 23:45:47 1.16
***************
*** 192,197 ****

try:
! opts, args = getopt.getopt(sys.argv[1:], 'ihq',
! ['install', 'help', 'quiet'])
except getopt.error, msg:
usage(1, msg)
--- 192,197 ----

try:
! opts, args = getopt.getopt(sys.argv[1:], 'ihqu:',
! ['install', 'help', 'quiet', 'user='])
except getopt.error, msg:
usage(1, msg)



From python-dev@python.org Thu Nov 2 08:05:41 2000
From: python-dev@python.org (Moshe Zadka)
Date: Thu, 2 Nov 2000 00:05:41 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0217.txt,1.2,1.3
Message-ID: <200011020805.AAA24917@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv24852

Modified Files:
pep-0217.txt
Log Message:
Added some more meat to the PEP
Added a section about Jython issues.


Index: pep-0217.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0217.txt,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** pep-0217.txt 2000/08/23 05:50:32 1.2
--- pep-0217.txt 2000/11/02 08:05:38 1.3
***************
*** 2,6 ****
Title: Display Hook for Interactive Use
Version: $Revision$
! Author: moshez@math.huji.ac.il (Moshe Zadka)
Status: Draft
Type: Standards Track
--- 2,6 ----
Title: Display Hook for Interactive Use
Version: $Revision$
! Author: peps@zadka.site.co.il (Moshe Zadka)
Status: Draft
Type: Standards Track
***************
*** 21,24 ****
--- 21,44 ----
interactive interpreter.

+ Solution
+
+ The bytecode PRINT_EXPR will call sys.displayhook(POP())
+ A displayhook() will be added to the sys builtin module, which is
+ equivalent to
+
+ import __builtin__
+ def displayhook(o):
+ if o is None:
+ return
+ __builtin__._ = o
+ print o
+
+ Jython Issues
+
+ The author knows too little about Jython, but it is very important
+ to be compatible with it. displayhook will have to be added to sys,
+ but since Jython works with Java bytecodes, the compiler would have
+ to be changed too, or maybe not.
+ Barry?





From python-dev@python.org Thu Nov 2 16:18:27 2000
From: python-dev@python.org (Barry Warsaw)
Date: Thu, 2 Nov 2000 08:18:27 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0227.txt,NONE,1.1
Message-ID: <200011021618.IAA15298@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv15290

Added Files:
pep-0227.txt
Log Message:
PEP 227, Statically Nested Scopes, Jeremy Hylton


***** Error reading new file: (2, 'No such file or directory')


From python-dev@python.org Thu Nov 2 16:19:09 2000
From: python-dev@python.org (Barry Warsaw)
Date: Thu, 2 Nov 2000 08:19:09 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0000.txt,1.40,1.41
Message-ID: <200011021619.IAA15368@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv15358

Modified Files:
pep-0000.txt
Log Message:
Added PEP 227, Statically Nested Scopes, Jeremy Hylton


Index: pep-0000.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0000.txt,v
retrieving revision 1.40
retrieving revision 1.41
diff -C2 -r1.40 -r1.41
*** pep-0000.txt 2000/10/30 21:16:38 1.40
--- pep-0000.txt 2000/11/02 16:19:06 1.41
***************
*** 56,59 ****
--- 56,60 ----
SD 225 pep-0225.txt Elementwise/Objectwise Operators Zhu, Lielens
I 226 pep-0226.txt Python 2.1 Release Schedule Hylton
+ S 227 pep-0227.txt Statically Nested Scopes Hylton





From python-dev@python.org Thu Nov 2 16:38:18 2000
From: python-dev@python.org (Barry Warsaw)
Date: Thu, 2 Nov 2000 08:38:18 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0000.txt,1.41,1.42
Message-ID: <200011021638.IAA16894@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv16886

Modified Files:
pep-0000.txt
Log Message:
Update PEP 204 status to Rejected.


Index: pep-0000.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0000.txt,v
retrieving revision 1.41
retrieving revision 1.42
diff -C2 -r1.41 -r1.42
*** pep-0000.txt 2000/11/02 16:19:06 1.41
--- pep-0000.txt 2000/11/02 16:38:15 1.42
***************
*** 33,37 ****
S 202 pep-0202.txt List Comprehensions Peters
SF 203 pep-0203.txt Augmented Assignments Wouters
! S 204 pep-0204.txt Range Literals Wouters
SD 205 pep-0205.txt Weak References Drake
I 206 pep-0206.txt 2.0 Batteries Included Zadka
--- 33,37 ----
S 202 pep-0202.txt List Comprehensions Peters
SF 203 pep-0203.txt Augmented Assignments Wouters
! SR 204 pep-0204.txt Range Literals Wouters
SD 205 pep-0205.txt Weak References Drake
I 206 pep-0206.txt 2.0 Batteries Included Zadka



From python-dev@python.org Thu Nov 2 16:43:34 2000
From: python-dev@python.org (Barry Warsaw)
Date: Thu, 2 Nov 2000 08:43:34 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0000.txt,1.42,1.43
Message-ID: <200011021643.IAA17418@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv17409

Modified Files:
pep-0000.txt
Log Message:
Mark PEP 200 as Final now that 2.0 is out the door.


Index: pep-0000.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0000.txt,v
retrieving revision 1.42
retrieving revision 1.43
diff -C2 -r1.42 -r1.43
*** pep-0000.txt 2000/11/02 16:38:15 1.42
--- pep-0000.txt 2000/11/02 16:43:32 1.43
***************
*** 29,33 ****
I 160 pep-0160.txt Python 1.6 Release Schedule Drake

! I 200 pep-0200.txt Python 2.0 Release Schedule Hylton
SF 201 pep-0201.txt Lockstep Iteration Warsaw
S 202 pep-0202.txt List Comprehensions Peters
--- 29,33 ----
I 160 pep-0160.txt Python 1.6 Release Schedule Drake

! IF 200 pep-0200.txt Python 2.0 Release Schedule Hylton
SF 201 pep-0201.txt Lockstep Iteration Warsaw
S 202 pep-0202.txt List Comprehensions Peters



From python-dev@python.org Thu Nov 2 16:44:06 2000
From: python-dev@python.org (Barry Warsaw)
Date: Thu, 2 Nov 2000 08:44:06 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0200.txt,1.45,1.46
Message-ID: <200011021644.IAA17466@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv17455

Modified Files:
pep-0200.txt
Log Message:
Mark status as Final, remove "Tentative" from Release Schedule.


Index: pep-0200.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0200.txt,v
retrieving revision 1.45
retrieving revision 1.46
diff -C2 -r1.45 -r1.46
*** pep-0200.txt 2000/10/30 20:48:44 1.45
--- pep-0200.txt 2000/11/02 16:44:04 1.46
***************
*** 4,8 ****
Owner: Jeremy Hylton <jeremy@digicool.com>
Python-Version: 2.0
! Status: Incomplete


--- 4,8 ----
Owner: Jeremy Hylton <jeremy@digicool.com>
Python-Version: 2.0
! Status: Final


***************
*** 16,20 ****
historical record.

! Tentative Release Schedule
[revised 5 Oct 2000]

--- 16,20 ----
historical record.

! Release Schedule
[revised 5 Oct 2000]




From python-dev@python.org Thu Nov 2 16:54:22 2000
From: python-dev@python.org (Guido van Rossum)
Date: Thu, 2 Nov 2000 08:54:22 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0042.txt,1.41,1.42
Message-ID: <200011021654.IAA18474@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv18457

Modified Files:
pep-0042.txt
Log Message:
Remove two rejected feature requests.


Index: pep-0042.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0042.txt,v
retrieving revision 1.41
retrieving revision 1.42
diff -C2 -r1.41 -r1.42
*** pep-0042.txt 2000/11/01 22:28:42 1.41
--- pep-0042.txt 2000/11/02 16:54:19 1.42
***************
*** 81,95 ****
http://sourceforge.net/bugs/?funcÞtailbug&bug_id6405&group_idT70

- - The C API should include a PyDict_Update() function which takes a
- dictionary as its first argument, and an arbitrary mapping as its
- second. Similarly there should probably be a PyMapping_Update() in the
- abstract API (and several other dictionary methods in there too).
-
- http://sourceforge.net/bugs/?funcÞtailbug&bug_id2081&group_idT70
-
- - Inside a function, vars() should include both locals() and globals()
-
- http://sourceforge.net/bugs/?funcÞtailbug&bug_id2082&group_idT70
-
Standard Library

--- 81,84 ----



From python-dev@python.org Thu Nov 2 17:52:59 2000
From: python-dev@python.org (Fred L. Drake)
Date: Thu, 2 Nov 2000 09:52:59 -0800
Subject: [Python-checkins] CVS: python/dist/src configure.in,1.175,1.176
Message-ID: <200011021752.JAA23302@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src
In directory slayer.i.sourceforge.net:/tmp/cvs-serv23294

Modified Files:
configure.in
Log Message:

Make sure the Modules/ directory is created before writing Modules/Setup.


Index: configure.in
==================================================================RCS file: /cvsroot/python/python/dist/src/configure.in,v
retrieving revision 1.175
retrieving revision 1.176
diff -C2 -r1.175 -r1.176
*** configure.in 2000/10/30 17:45:07 1.175
--- configure.in 2000/11/02 17:52:56 1.176
***************
*** 1301,1304 ****
--- 1301,1307 ----
AC_MSG_CHECKING(for Modules/Setup)
if test ! -f Modules/Setup ; then
+ if test ! -d Modules ; then
+ mkdir Modules
+ fi
cp "$srcdir/Modules/Setup.dist" Modules/Setup
AC_MSG_RESULT(creating)



From python-dev@python.org Thu Nov 2 19:33:56 2000
From: python-dev@python.org (Guido van Rossum)
Date: Thu, 2 Nov 2000 11:33:56 -0800
Subject: [Python-checkins] CVS: python/dist/src configure,1.167,1.168
Message-ID: <200011021933.LAA31933@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src
In directory slayer.i.sourceforge.net:/tmp/cvs-serv31920

Modified Files:
configure
Log Message:
New configure script from latest configure.in with autoconf 2.13

Index: configure
==================================================================RCS file: /cvsroot/python/python/dist/src/configure,v
retrieving revision 1.167
retrieving revision 1.168
diff -C2 -r1.167 -r1.168
*** configure 2000/10/30 17:45:07 1.167
--- configure 2000/11/02 19:33:53 1.168
***************
*** 1,5 ****
#! /bin/sh

! # From configure.in Revision: 1.175

# Guess values for system-dependent variables and create Makefiles.
--- 1,5 ----
#! /bin/sh

! # From configure.in Revision: 1.176

# Guess values for system-dependent variables and create Makefiles.
***************
*** 5976,5979 ****
--- 5976,5982 ----
echo "configure:5977: checking for Modules/Setup" >&5
if test ! -f Modules/Setup ; then
+ if test ! -d Modules ; then
+ mkdir Modules
+ fi
cp "$srcdir/Modules/Setup.dist" Modules/Setup
echo "$ac_t""creating" 1>&6



From python-dev@python.org Thu Nov 2 21:49:42 2000
From: python-dev@python.org (Fred L. Drake)
Date: Thu, 2 Nov 2000 13:49:42 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/ext ext.tex,1.87,1.88
Message-ID: <200011022149.NAA22985@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/ext
In directory slayer.i.sourceforge.net:/tmp/cvs-serv22968

Modified Files:
ext.tex
Log Message:

Fix cut & paste error that describes three paramters when there are only
two [bug #119729].

Update use of distutils.sysconfig that "broke" when Greg W. changed the API
[bug #119645].


Index: ext.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/ext/ext.tex,v
retrieving revision 1.87
retrieving revision 1.88
diff -C2 -r1.87 -r1.88
*** ext.tex 2000/10/26 17:19:58 1.87
--- ext.tex 2000/11/02 21:49:17 1.88
***************
*** 719,726 ****

The variant reads one C variable and stores into two C variables, the
! first one a pointer to an encoding name string (\var{encoding}), the
second a pointer to a pointer to a character buffer (\var{**buffer},
! the buffer used for storing the encoded data) and the third one a
! pointer to an integer (\var{*buffer_length}, the buffer length).

The encoding name must map to a registered codec. If set to \NULL{},
--- 719,725 ----

The variant reads one C variable and stores into two C variables, the
! first one a pointer to an encoding name string (\var{encoding}), and the
second a pointer to a pointer to a character buffer (\var{**buffer},
! the buffer used for storing the encoded data).

The encoding name must map to a registered codec. If set to \NULL{},
***************
*** 2139,2143 ****
\begin{verbatim}
import distutils.sysconfig
! >>> distutils.sysconfig.LINKFORSHARED
'-Xlinker -export-dynamic'
\end{verbatim}
--- 2138,2142 ----
\begin{verbatim}
import distutils.sysconfig
! >>> distutils.sysconfig.get_config_var('LINKFORSHARED')
'-Xlinker -export-dynamic'
\end{verbatim}



From python-dev@python.org Thu Nov 2 21:51:55 2000
From: python-dev@python.org (Thomas Wouters)
Date: Thu, 2 Nov 2000 13:51:55 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0204.txt,1.6,1.7
Message-ID: <200011022151.NAA23108@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv23090

Modified Files:
pep-0204.txt
Log Message:

Small whitespace 'fix', to test checkins.



Index: pep-0204.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0204.txt,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -r1.6 -r1.7
*** pep-0204.txt 2000/11/01 22:43:42 1.6
--- pep-0204.txt 2000/11/02 21:51:53 1.7
***************
*** 159,163 ****
literals. In slices, `end' would default to the end of the list,
but this has no meaning in range literals.
!

Reference Implementation
--- 159,163 ----
literals. In slices, `end' would default to the end of the list,
but this has no meaning in range literals.
!

Reference Implementation



From python-dev@python.org Thu Nov 2 23:53:53 2000
From: python-dev@python.org (Moshe Zadka)
Date: Thu, 2 Nov 2000 15:53:53 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0217.txt,1.3,1.4
Message-ID: <200011022353.PAA03931@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv3904

Modified Files:
pep-0217.txt
Log Message:
Added Jython solution
Added abstract interface specification.
(Motivation is in the abstract)


Index: pep-0217.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0217.txt,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** pep-0217.txt 2000/11/02 08:05:38 1.3
--- pep-0217.txt 2000/11/02 23:53:51 1.4
***************
*** 21,24 ****
--- 21,35 ----
interactive interpreter.

+ Interface
+
+ The current Python solution has worked for many users, and this
+ should not break it. Therefore, in the default configuration,
+ nothing will change in the REPL loop. To change the way the
+ interpreter prints interactively entered expressions, users
+ will have to rebind sys.displayhook to a callable object.
+ The result of calling this object with the result of the
+ interactively entered expression should be print-able,
+ and this is what will be printed on sys.stdout.
+
Solution

***************
*** 31,44 ****
if o is None:
return
__builtin__._ = o
- print o

Jython Issues

! The author knows too little about Jython, but it is very important
! to be compatible with it. displayhook will have to be added to sys,
! but since Jython works with Java bytecodes, the compiler would have
! to be changed too, or maybe not.
! Barry?


--- 42,52 ----
if o is None:
return
+ __builtin__._ = None
+ print `o`
__builtin__._ = o

Jython Issues

! The method Py.printResult will be similarily changed.





From python-dev@python.org Fri Nov 3 02:08:17 2000
From: python-dev@python.org (fidan latifi)
Date: Fri, 03 Nov 2000 02:08:17 GMT
Subject: [Python-checkins] null(2139,2143
Message-ID: <F84cOrBLSAQV6uPDVni0000917a@hotmail.com>

_________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.

Share information about yourself, create your own public profile at
http://profiles.msn.com.



From python-dev@python.org Fri Nov 3 02:08:30 2000
From: python-dev@python.org (fidan latifi)
Date: Fri, 03 Nov 2000 02:08:30 GMT
Subject: [Python-checkins] null(2139,2143
Message-ID: <F86pgk0BYACaRzsGwh800008f25@hotmail.com>

_________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com.

Share information about yourself, create your own public profile at
http://profiles.msn.com.



From python-dev@python.org Fri Nov 3 02:56:07 2000
From: python-dev@python.org (Guido van Rossum)
Date: Thu, 2 Nov 2000 18:56:07 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0000.txt,1.43,1.44
Message-ID: <200011030256.SAA03410@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv3399

Modified Files:
pep-0000.txt
Log Message:
Added an index by category.


Index: pep-0000.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0000.txt,v
retrieving revision 1.43
retrieving revision 1.44
diff -C2 -r1.43 -r1.44
*** pep-0000.txt 2000/11/02 16:43:32 1.43
--- pep-0000.txt 2000/11/03 02:56:05 1.44
***************
*** 15,22 ****


! Index

num filename title owner
--- ------------ ----- -----
I 0 pep-0000.txt Index of Python Enhancement Proposals Warsaw
I 1 pep-0001.txt PEP Guidelines Warsaw, Hylton
--- 15,85 ----


! Index by Category

num filename title owner
--- ------------ ----- -----
+
+ Meta-PEPs (PEPs about PEPs)
+
+ I 0 pep-0000.txt Index of Python Enhancement Proposals Warsaw
+ I 1 pep-0001.txt PEP Guidelines Warsaw, Hylton
+ I 2 pep-0002.txt Procedure for Adding New Modules Raymond
+ I 3 pep-0003.txt Guidelines for Handling Bug Reports Hylton
+ I 4 pep-0004.txt Deprecation of Standard Modules von Loewis
+ I 5 pep-0005.txt Guidelines for Language Evolution Prescod
+
+ Active PEPs (under serious consideration for Python 2.1 - even if empty)
+
+ I 42 pep-0042.txt Small Feature Requests Hylton
+ S 207 pep-0207.txt Rich Comparisons Ascher
+ S 208 pep-0208.txt Reworking the Coercion Model Ascher
+ S 217 pep-0217.txt Display Hook for Interactive Use Zadka
+ S 222 pep-0222.txt Web Library Enhancements Kuchling
+ I 226 pep-0226.txt Python 2.1 Release Schedule Hylton
+ S 227 pep-0227.txt Statically Nested Scopes Hylton
+
+ Pie-in-the-sky PEPs (not ready; may become active yet)
+
+ I 206 pep-0206.txt 2.0 Batteries Included Zadka
+ SD 211 pep-0211.txt Adding New Linear Algebra Operators Wilson
+ SD 212 pep-0212.txt Loop Counter Iteration Schneider-Kamp
+ SD 213 pep-0213.txt Attribute Access Handlers Prescod
+ SD 224 pep-0224.txt Attribute Docstrings Lemburg
+ SD 225 pep-0225.txt Elementwise/Objectwise Operators Zhu, Lielens
+
+ Incomplete PEPs (only an abstract)
+
+ SD 218 pep-0218.txt Adding a Built-In Set Object Type Wilson
+ SD 219 pep-0219.txt Stackless Python McMillan
+ I 220 pep-0220.txt Coroutines, Generators, Continuations McMillan
+
+ Empty PEPs (nothing written yet)
+
+ SD 205 pep-0205.txt Weak References Drake
+ SD 209 pep-0209.txt Adding Multidimensional Arrays Ascher
+ SD 210 pep-0210.txt Decoupling the Interpreter Loop Ascher
+ SD 215 pep-0215.txt String Interpolation Yee
+ I 216 pep-0216.txt Docstring Format Zadka
+
+ Finished PEPs (done, implemented)
+
+ I 160 pep-0160.txt Python 1.6 Release Schedule Drake
+ IF 200 pep-0200.txt Python 2.0 Release Schedule Hylton
+ SF 201 pep-0201.txt Lockstep Iteration Warsaw
+ S 202 pep-0202.txt List Comprehensions Peters
+ SF 203 pep-0203.txt Augmented Assignments Wouters
+ SF 214 pep-0214.txt Extended Print Statement Warsaw
+ SF 221 pep-0221.txt Import As Wouters
+ SF 223 pep-0223.txt Change the Meaning of \x Escapes Peters
+
+ Rejected PEPs
+
+ SR 204 pep-0204.txt Range Literals Wouters
+
+
+ Numerical Index
+
+ num filename title owner
+ --- ------------ ----- -----
I 0 pep-0000.txt Index of Python Enhancement Proposals Warsaw
I 1 pep-0001.txt PEP Guidelines Warsaw, Hylton
***************
*** 36,41 ****
SD 205 pep-0205.txt Weak References Drake
I 206 pep-0206.txt 2.0 Batteries Included Zadka
! SD 207 pep-0207.txt Rich Comparisons Ascher
! SD 208 pep-0208.txt Reworking the Coercion Model Ascher
SD 209 pep-0209.txt Adding Multidimensional Arrays Ascher
SD 210 pep-0210.txt Decoupling the Interpreter Loop Ascher
--- 99,104 ----
SD 205 pep-0205.txt Weak References Drake
I 206 pep-0206.txt 2.0 Batteries Included Zadka
! S 207 pep-0207.txt Rich Comparisons Ascher
! S 208 pep-0208.txt Reworking the Coercion Model Ascher
SD 209 pep-0209.txt Adding Multidimensional Arrays Ascher
SD 210 pep-0210.txt Decoupling the Interpreter Loop Ascher
***************
*** 46,57 ****
SD 215 pep-0215.txt String Interpolation Yee
I 216 pep-0216.txt Docstring Format Zadka
! SD 217 pep-0217.txt Display Hook for Interactive Use Zadka
SD 218 pep-0218.txt Adding a Built-In Set Object Type Wilson
SD 219 pep-0219.txt Stackless Python McMillan
I 220 pep-0220.txt Coroutines, Generators, Continuations McMillan
SF 221 pep-0221.txt Import As Wouters
! SD 222 pep-0222.txt Web Library Enhancements Kuchling
SF 223 pep-0223.txt Change the Meaning of \x Escapes Peters
! S 224 pep-0224.txt Attribute Docstrings Lemburg
SD 225 pep-0225.txt Elementwise/Objectwise Operators Zhu, Lielens
I 226 pep-0226.txt Python 2.1 Release Schedule Hylton
--- 109,120 ----
SD 215 pep-0215.txt String Interpolation Yee
I 216 pep-0216.txt Docstring Format Zadka
! S 217 pep-0217.txt Display Hook for Interactive Use Zadka
SD 218 pep-0218.txt Adding a Built-In Set Object Type Wilson
SD 219 pep-0219.txt Stackless Python McMillan
I 220 pep-0220.txt Coroutines, Generators, Continuations McMillan
SF 221 pep-0221.txt Import As Wouters
! S 222 pep-0222.txt Web Library Enhancements Kuchling
SF 223 pep-0223.txt Change the Meaning of \x Escapes Peters
! SD 224 pep-0224.txt Attribute Docstrings Lemburg
SD 225 pep-0225.txt Elementwise/Objectwise Operators Zhu, Lielens
I 226 pep-0226.txt Python 2.1 Release Schedule Hylton



From python-dev@python.org Fri Nov 3 02:57:35 2000
From: python-dev@python.org (Fred L. Drake)
Date: Thu, 2 Nov 2000 18:57:35 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/tools mkhowto,1.17,1.18
Message-ID: <200011030257.SAA03504@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/tools
In directory slayer.i.sourceforge.net:/tmp/cvs-serv3491/tools

Modified Files:
mkhowto
Log Message:

Make sure we clean up the index data each time it is written by LaTeX.


Index: mkhowto
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/tools/mkhowto,v
retrieving revision 1.17
retrieving revision 1.18
diff -C2 -r1.17 -r1.18
*** mkhowto 2000/09/20 05:49:09 1.17
--- mkhowto 2000/11/03 02:57:31 1.18
***************
*** 280,284 ****
--- 280,286 ----
if os.path.isfile("mod%s.idx" % self.doc):
self.run("%s mod%s.idx" % (MAKEINDEX_BINARY, self.doc))
+ use_indfix = 0
if os.path.isfile(self.doc + ".idx"):
+ use_indfix = 1
# call to Doc/tools/fix_hack omitted; doesn't appear necessary
self.run("%s %s.idx" % (MAKEINDEX_BINARY, self.doc))
***************
*** 296,302 ****
self.run("%s -s %s mod%s.idx"
% (MAKEINDEX_BINARY, ISTFILE, self.doc))
! if os.path.isfile(self.doc + ".idx"):
self.run("%s -s %s %s.idx"
% (MAKEINDEX_BINARY, ISTFILE, self.doc))
self.process_synopsis_files()
#
--- 298,305 ----
self.run("%s -s %s mod%s.idx"
% (MAKEINDEX_BINARY, ISTFILE, self.doc))
! if use_indfix:
self.run("%s -s %s %s.idx"
% (MAKEINDEX_BINARY, ISTFILE, self.doc))
+ indfix.process(self.doc + ".ind")
self.process_synopsis_files()
#



From python-dev@python.org Fri Nov 3 08:18:40 2000
From: python-dev@python.org (Thomas Wouters)
Date: Fri, 3 Nov 2000 00:18:40 -0800
Subject: [Python-checkins] CVS: python/dist/src/Demo/pysvr pysvr.c,1.8,1.9
Message-ID: <200011030818.AAA28198@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Demo/pysvr
In directory slayer.i.sourceforge.net:/tmp/cvs-serv27629/Demo/pysvr

Modified Files:
pysvr.c
Log Message:

Move our own getopt() implementation to _PyOS_GetOpt(), and use it
regardless of whether the system getopt() does what we want. This avoids the
hassle with prototypes and externs, and the check to see if the system
getopt() does what we want. Prefix optind, optarg and opterr with _PyOS_ to
avoid name clashes. Add new include file to define the right symbols. Fix
Demo/pyserv/pyserv.c to include getopt.h itself, instead of relying on
Python to provide it.



Index: pysvr.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Demo/pysvr/pysvr.c,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -r1.8 -r1.9
*** pysvr.c 2000/07/22 19:25:51 1.8
--- pysvr.c 2000/11/03 08:18:37 1.9
***************
*** 20,23 ****
--- 20,24 ----

#include <pthread.h>
+ #include <getopt.h>

/* XXX Umpfh.
***************
*** 32,39 ****
#define PORT 4000
#endif
-
- extern int optind;
- extern char *optarg;
- extern int getopt(int, char **, char *);

struct workorder {
--- 33,36 ----



From python-dev@python.org Fri Nov 3 08:18:40 2000
From: python-dev@python.org (Thomas Wouters)
Date: Fri, 3 Nov 2000 00:18:40 -0800
Subject: [Python-checkins] CVS: python/dist/src/Python Makefile.in,2.26,2.27 getopt.c,2.8,2.9
Message-ID: <200011030818.AAA28209@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Python
In directory slayer.i.sourceforge.net:/tmp/cvs-serv27629/Python

Modified Files:
Makefile.in getopt.c
Log Message:

Move our own getopt() implementation to _PyOS_GetOpt(), and use it
regardless of whether the system getopt() does what we want. This avoids the
hassle with prototypes and externs, and the check to see if the system
getopt() does what we want. Prefix optind, optarg and opterr with _PyOS_ to
avoid name clashes. Add new include file to define the right symbols. Fix
Demo/pyserv/pyserv.c to include getopt.h itself, instead of relying on
Python to provide it.



Index: Makefile.in
==================================================================RCS file: /cvsroot/python/python/dist/src/Python/Makefile.in,v
retrieving revision 2.26
retrieving revision 2.27
diff -C2 -r2.26 -r2.27
*** Makefile.in 2000/08/23 21:16:10 2.26
--- Makefile.in 2000/11/03 08:18:37 2.27
***************
*** 47,51 ****
pyfpe.o pystate.o pythonrun.o \
structmember.o sysmodule.o \
! traceback.o \
$(DYNLOADFILE) \
$(LIBOBJS)
--- 47,51 ----
pyfpe.o pystate.o pythonrun.o \
structmember.o sysmodule.o \
! traceback.o getopt.o \
$(DYNLOADFILE) \
$(LIBOBJS)

Index: getopt.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Python/getopt.c,v
retrieving revision 2.8
retrieving revision 2.9
diff -C2 -r2.8 -r2.9
*** getopt.c 2000/07/22 18:47:25 2.8
--- getopt.c 2000/11/03 08:18:37 2.9
***************
*** 28,73 ****
#include <string.h>

! #define bool int
! #ifndef TRUE
! #define TRUE 1
! #endif
! #ifndef FALSE
! #define FALSE 0
! #endif
!
! bool opterr = TRUE; /* generate error messages */
! int optind = 1; /* index into argv array */
! char * optarg = NULL; /* optional argument */
!
!
! #ifndef __BEOS__
! int getopt(int argc, char *argv[], char optstring[])
! #else
! int getopt(int argc, char *const *argv, const char *optstring)
! #endif
{
! static char *opt_ptr = "";
! register char *ptr;
! int option;

if (*opt_ptr == '\0') {

! if (optind >= argc || argv[optind][0] != '-' ||
! argv[optind][1] == '\0' /* lone dash */ )
return -1;

! else if (strcmp(argv[optind], "--") == 0) {
! ++optind;
return -1;
}

! opt_ptr = &argv[optind++][1];
}

if ( (option = *opt_ptr++) == '\0')
! return -1;

if ((ptr = strchr(optstring, option)) == NULL) {
! if (opterr)
fprintf(stderr, "Unknown option: -%c\n", option);

--- 28,60 ----
#include <string.h>

! int _PyOS_opterr = 1; /* generate error messages */
! int _PyOS_optind = 1; /* index into argv array */
! char *_PyOS_optarg = NULL; /* optional argument */
!
! int _PyOS_GetOpt(int argc, char **argv, char *optstring)
{
! static char *opt_ptr = "";
! char *ptr;
! int option;

if (*opt_ptr == '\0') {

! if (_PyOS_optind >= argc || argv[_PyOS_optind][0] != '-' ||
! argv[_PyOS_optind][1] == '\0' /* lone dash */ )
return -1;

! else if (strcmp(argv[_PyOS_optind], "--") == 0) {
! ++_PyOS_optind;
return -1;
}

! opt_ptr = &argv[_PyOS_optind++][1];
}

if ( (option = *opt_ptr++) == '\0')
! return -1;

if ((ptr = strchr(optstring, option)) == NULL) {
! if (_PyOS_opterr)
fprintf(stderr, "Unknown option: -%c\n", option);

***************
*** 77,87 ****
if (*(ptr + 1) == ':') {
if (*opt_ptr != '\0') {
! optarg = opt_ptr;
opt_ptr = "";
}

else {
! if (optind >= argc) {
! if (opterr)
fprintf(stderr,
"Argument expected for the -%c option\n", option);
--- 64,74 ----
if (*(ptr + 1) == ':') {
if (*opt_ptr != '\0') {
! _PyOS_optarg = opt_ptr;
opt_ptr = "";
}

else {
! if (_PyOS_optind >= argc) {
! if (_PyOS_opterr)
fprintf(stderr,
"Argument expected for the -%c option\n", option);
***************
*** 89,93 ****
}

! optarg = argv[optind++];
}
}
--- 76,80 ----
}

! _PyOS_optarg = argv[_PyOS_optind++];
}
}



From python-dev@python.org Fri Nov 3 08:18:40 2000
From: python-dev@python.org (Thomas Wouters)
Date: Fri, 3 Nov 2000 00:18:40 -0800
Subject: [Python-checkins] CVS: python/dist/src configure,1.168,1.169 configure.in,1.176,1.177
Message-ID: <200011030818.AAA28202@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src
In directory slayer.i.sourceforge.net:/tmp/cvs-serv27629

Modified Files:
configure configure.in
Log Message:

Move our own getopt() implementation to _PyOS_GetOpt(), and use it
regardless of whether the system getopt() does what we want. This avoids the
hassle with prototypes and externs, and the check to see if the system
getopt() does what we want. Prefix optind, optarg and opterr with _PyOS_ to
avoid name clashes. Add new include file to define the right symbols. Fix
Demo/pyserv/pyserv.c to include getopt.h itself, instead of relying on
Python to provide it.



Index: configure
==================================================================RCS file: /cvsroot/python/python/dist/src/configure,v
retrieving revision 1.168
retrieving revision 1.169
diff -C2 -r1.168 -r1.169
*** configure 2000/11/02 19:33:53 1.168
--- configure 2000/11/03 08:18:36 1.169
***************
*** 4840,4844 ****

/* Ultrix mips cc rejects this. */
! typedef int charset[2]; const charset x;
/* SunOS 4.1.1 cc rejects this. */
char const *const *ccp;
--- 4840,4844 ----

/* Ultrix mips cc rejects this. */
! typedef int charset[2]; const charset x = {0,0};
/* SunOS 4.1.1 cc rejects this. */
char const *const *ccp;
***************
*** 4915,4919 ****

int main() {
! } $ac_kw foo() {
; return 0; }
EOF
--- 4915,4919 ----

int main() {
! } int $ac_kw foo() {
; return 0; }
EOF
***************
*** 5626,5670 ****
LIBS=$LIBS_SAVE

- # check for getopt
- echo $ac_n "checking for genuine getopt""... $ac_c" 1>&6
- echo "configure:5631: checking for genuine getopt" >&5
- if eval "test \"`echo '$''{'ac_cv_func_getopt'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
- if test "$cross_compiling" = yes; then
- ac_cv_func_getopt=no
- else
- cat > conftest.$ac_ext <<EOF
- #line 5639 "configure"
- #include "confdefs.h"
- #include <stdio.h>
- extern int optind, opterr, getopt();
- extern char* optarg;
- int main() {
- char* av[] = { "testprog", "parameter", "-fFlag", NULL };
- opterr = 0;
- if (getopt(3, av, "f:") == 'f') { exit(1); }
- exit(0);
- }
- EOF
- if { (eval echo configure:5651: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
- then
- ac_cv_func_getopt=yes
- else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- rm -fr conftest*
- ac_cv_func_getopt=no
- fi
- rm -fr conftest*
- fi
-
- fi
- echo "$ac_t""$ac_cv_func_getopt" 1>&6
- test $ac_cv_func_getopt = no && LIBOBJS="$LIBOBJS getopt.o"
-
# check whether malloc(0) returns NULL or not
echo $ac_n "checking what malloc(0) returns""... $ac_c" 1>&6
! echo "configure:5669: checking what malloc(0) returns" >&5
if eval "test \"`echo '$''{'ac_cv_malloc_zero'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
--- 5626,5632 ----
LIBS=$LIBS_SAVE

# check whether malloc(0) returns NULL or not
echo $ac_n "checking what malloc(0) returns""... $ac_c" 1>&6
! echo "configure:5631: checking what malloc(0) returns" >&5
if eval "test \"`echo '$''{'ac_cv_malloc_zero'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
***************
*** 5674,5678 ****
else
cat > conftest.$ac_ext <<EOF
! #line 5677 "configure"
#include "confdefs.h"
#include <stdio.h>
--- 5636,5640 ----
else
cat > conftest.$ac_ext <<EOF
! #line 5639 "configure"
#include "confdefs.h"
#include <stdio.h>
***************
*** 5693,5697 ****
}
EOF
! if { (eval echo configure:5696: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_malloc_zero=nonnull
--- 5655,5659 ----
}
EOF
! if { (eval echo configure:5658: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_malloc_zero=nonnull
***************
*** 5719,5733 ****
ac_safe=`echo "wchar.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for wchar.h""... $ac_c" 1>&6
! echo "configure:5722: checking for wchar.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5727 "configure"
#include "confdefs.h"
#include <wchar.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
! { (eval echo configure:5732: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
--- 5681,5695 ----
ac_safe=`echo "wchar.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for wchar.h""... $ac_c" 1>&6
! echo "configure:5684: checking for wchar.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5689 "configure"
#include "confdefs.h"
#include <wchar.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
! { (eval echo configure:5694: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
***************
*** 5759,5768 ****
usable_wchar_t="unkown"
echo $ac_n "checking for usable wchar_t""... $ac_c" 1>&6
! echo "configure:5762: checking for usable wchar_t" >&5
if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
! #line 5767 "configure"
#include "confdefs.h"

--- 5721,5730 ----
usable_wchar_t="unkown"
echo $ac_n "checking for usable wchar_t""... $ac_c" 1>&6
! echo "configure:5724: checking for usable wchar_t" >&5
if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
! #line 5729 "configure"
#include "confdefs.h"

***************
*** 5778,5782 ****

EOF
! if { (eval echo configure:5781: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
cat >> confdefs.h <<\EOF
--- 5740,5744 ----

EOF
! if { (eval echo configure:5743: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
cat >> confdefs.h <<\EOF
***************
*** 5797,5801 ****
# check for endianness
echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
! echo "configure:5800: checking whether byte ordering is bigendian" >&5
if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
--- 5759,5763 ----
# check for endianness
echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
! echo "configure:5762: checking whether byte ordering is bigendian" >&5
if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
***************
*** 5804,5808 ****
# See if sys/param.h defines the BYTE_ORDER macro.
cat > conftest.$ac_ext <<EOF
! #line 5807 "configure"
#include "confdefs.h"
#include <sys/types.h>
--- 5766,5770 ----
# See if sys/param.h defines the BYTE_ORDER macro.
cat > conftest.$ac_ext <<EOF
! #line 5769 "configure"
#include "confdefs.h"
#include <sys/types.h>
***************
*** 5815,5823 ****
; return 0; }
EOF
! if { (eval echo configure:5818: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
# It does; now see whether it defined to BIG_ENDIAN or not.
cat > conftest.$ac_ext <<EOF
! #line 5822 "configure"
#include "confdefs.h"
#include <sys/types.h>
--- 5777,5785 ----
; return 0; }
EOF
! if { (eval echo configure:5780: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
# It does; now see whether it defined to BIG_ENDIAN or not.
cat > conftest.$ac_ext <<EOF
! #line 5784 "configure"
#include "confdefs.h"
#include <sys/types.h>
***************
*** 5830,5834 ****
; return 0; }
EOF
! if { (eval echo configure:5833: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_bigendian=yes
--- 5792,5796 ----
; return 0; }
EOF
! if { (eval echo configure:5795: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_bigendian=yes
***************
*** 5850,5854 ****
else
cat > conftest.$ac_ext <<EOF
! #line 5853 "configure"
#include "confdefs.h"
main () {
--- 5812,5816 ----
else
cat > conftest.$ac_ext <<EOF
! #line 5815 "configure"
#include "confdefs.h"
main () {
***************
*** 5863,5867 ****
}
EOF
! if { (eval echo configure:5866: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_bigendian=no
--- 5825,5829 ----
}
EOF
! if { (eval echo configure:5828: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_bigendian=no
***************
*** 5890,5894 ****
# or fills with zeros (like the Cray J90, according to Tim Peters).
echo $ac_n "checking whether right shift extends the sign bit""... $ac_c" 1>&6
! echo "configure:5893: checking whether right shift extends the sign bit" >&5
if eval "test \"`echo '$''{'ac_cv_rshift_extends_sign'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
--- 5852,5856 ----
# or fills with zeros (like the Cray J90, according to Tim Peters).
echo $ac_n "checking whether right shift extends the sign bit""... $ac_c" 1>&6
! echo "configure:5855: checking whether right shift extends the sign bit" >&5
if eval "test \"`echo '$''{'ac_cv_rshift_extends_sign'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
***************
*** 5899,5903 ****
else
cat > conftest.$ac_ext <<EOF
! #line 5902 "configure"
#include "confdefs.h"

--- 5861,5865 ----
else
cat > conftest.$ac_ext <<EOF
! #line 5864 "configure"
#include "confdefs.h"

***************
*** 5908,5912 ****

EOF
! if { (eval echo configure:5911: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_rshift_extends_sign=yes
--- 5870,5874 ----

EOF
! if { (eval echo configure:5873: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_rshift_extends_sign=yes
***************
*** 5940,5949 ****
EOF
echo $ac_n "checking for socklen_t""... $ac_c" 1>&6
! echo "configure:5943: checking for socklen_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_socklen_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5948 "configure"
#include "confdefs.h"
#include <sys/types.h>
--- 5902,5911 ----
EOF
echo $ac_n "checking for socklen_t""... $ac_c" 1>&6
! echo "configure:5905: checking for socklen_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_socklen_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5910 "configure"
#include "confdefs.h"
#include <sys/types.h>
***************
*** 5974,5978 ****

echo $ac_n "checking for Modules/Setup""... $ac_c" 1>&6
! echo "configure:5977: checking for Modules/Setup" >&5
if test ! -f Modules/Setup ; then
if test ! -d Modules ; then
--- 5936,5940 ----

echo $ac_n "checking for Modules/Setup""... $ac_c" 1>&6
! echo "configure:5939: checking for Modules/Setup" >&5
if test ! -f Modules/Setup ; then
if test ! -d Modules ; then

Index: configure.in
==================================================================RCS file: /cvsroot/python/python/dist/src/configure.in,v
retrieving revision 1.176
retrieving revision 1.177
diff -C2 -r1.176 -r1.177
*** configure.in 2000/11/02 17:52:56 1.176
--- configure.in 2000/11/03 08:18:36 1.177
***************
*** 1205,1224 ****
LIBS=$LIBS_SAVE

- # check for getopt
- AC_MSG_CHECKING(for genuine getopt)
- AC_CACHE_VAL(ac_cv_func_getopt,
- [AC_TRY_RUN([#include <stdio.h>
- extern int optind, opterr, getopt();
- extern char* optarg;
- int main() {
- char* av[] = { "testprog", "parameter", "-fFlag", NULL };
- opterr = 0;
- if (getopt(3, av, "f:") == 'f') { exit(1); }
- exit(0);
- }], ac_cv_func_getopt=yes, ac_cv_func_getopt=no, ac_cv_func_getopt=no)])dnl
- AC_MSG_RESULT($ac_cv_func_getopt)
- test $ac_cv_func_getopt = no && LIBOBJS="$LIBOBJS getopt.o"
- AC_SUBST(LIBOBJS)dnl
-
# check whether malloc(0) returns NULL or not
AC_MSG_CHECKING(what malloc(0) returns)
--- 1205,1208 ----



From python-dev@python.org Fri Nov 3 08:18:40 2000
From: python-dev@python.org (Thomas Wouters)
Date: Fri, 3 Nov 2000 00:18:40 -0800
Subject: [Python-checkins] CVS: python/dist/src/Include pygetopt.h,NONE,2.1
Message-ID: <200011030818.AAA28197@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Include
In directory slayer.i.sourceforge.net:/tmp/cvs-serv27629/Include

Added Files:
pygetopt.h
Log Message:

Move our own getopt() implementation to _PyOS_GetOpt(), and use it
regardless of whether the system getopt() does what we want. This avoids the
hassle with prototypes and externs, and the check to see if the system
getopt() does what we want. Prefix optind, optarg and opterr with _PyOS_ to
avoid name clashes. Add new include file to define the right symbols. Fix
Demo/pyserv/pyserv.c to include getopt.h itself, instead of relying on
Python to provide it.



--- NEW FILE ---

#ifndef Py_PYGETOPT_H
#define Py_PYGETOPT_H
#ifdef __cplusplus
extern "C" {
#endif

extern DL_IMPORT(int) _PyOS_opterr;
extern DL_IMPORT(int) _PyOS_optind;
extern DL_IMPORT(char *) _PyOS_optarg;

DL_IMPORT(int) _PyOS_GetOpt(int argc, char **argv, char *optstring);

#ifdef __cplusplus
}
#endif
#endif /* !Py_PYGETOPT_H */



From python-dev@python.org Fri Nov 3 08:18:40 2000
From: python-dev@python.org (Thomas Wouters)
Date: Fri, 3 Nov 2000 00:18:40 -0800
Subject: [Python-checkins] CVS: python/dist/src/Modules main.c,1.45,1.46
Message-ID: <200011030818.AAA28208@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Modules
In directory slayer.i.sourceforge.net:/tmp/cvs-serv27629/Modules

Modified Files:
main.c
Log Message:

Move our own getopt() implementation to _PyOS_GetOpt(), and use it
regardless of whether the system getopt() does what we want. This avoids the
hassle with prototypes and externs, and the check to see if the system
getopt() does what we want. Prefix optind, optarg and opterr with _PyOS_ to
avoid name clashes. Add new include file to define the right symbols. Fix
Demo/pyserv/pyserv.c to include getopt.h itself, instead of relying on
Python to provide it.



Index: main.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Modules/main.c,v
retrieving revision 1.45
retrieving revision 1.46
diff -C2 -r1.45 -r1.46
*** main.c 2000/09/15 18:40:42 1.45
--- main.c 2000/11/03 08:18:37 1.46
***************
*** 18,30 ****
#endif

#define COPYRIGHT \
"Type \"copyright\", \"credits\" or \"license\" for more information."

- /* Interface to getopt(): */
- extern int optind;
- extern char *optarg;
- extern int getopt(); /* PROTO((int, char **, char *)); -- not standardized */
-
-
/* For Py_GetArgcArgv(); set by main() */
static char **orig_argv;
--- 18,26 ----
#endif

+ #include "pygetopt.h"
+
#define COPYRIGHT \
"Type \"copyright\", \"credits\" or \"license\" for more information."

/* For Py_GetArgcArgv(); set by main() */
static char **orig_argv;
***************
*** 106,119 ****
unbuffered = 1;

! while ((c = getopt(argc, argv, "c:diOStuUvxXhV")) != EOF) {
if (c == 'c') {
/* -c is the last option; following arguments
that look like options are left for the
the command to interpret. */
! command = malloc(strlen(optarg) + 2);
if (command == NULL)
Py_FatalError(
"not enough memory to copy -c argument");
! strcpy(command, optarg);
strcat(command, "\n");
break;
--- 102,115 ----
unbuffered = 1;

! while ((c = _PyOS_GetOpt(argc, argv, "c:diOStuUvxXhV")) != EOF) {
if (c == 'c') {
/* -c is the last option; following arguments
that look like options are left for the
the command to interpret. */
! command = malloc(strlen(_PyOS_optarg) + 2);
if (command == NULL)
Py_FatalError(
"not enough memory to copy -c argument");
! strcpy(command, _PyOS_optarg);
strcat(command, "\n");
break;
***************
*** 182,189 ****
}

! if (command == NULL && optind < argc &&
! strcmp(argv[optind], "-") != 0)
{
! filename = argv[optind];
if (filename != NULL) {
if ((fp = fopen(filename, "r")) == NULL) {
--- 178,185 ----
}

! if (command == NULL && _PyOS_optind < argc &&
! strcmp(argv[_PyOS_optind], "-") != 0)
{
! filename = argv[_PyOS_optind];
if (filename != NULL) {
if ((fp = fopen(filename, "r")) == NULL) {
***************
*** 254,263 ****

if (command != NULL) {
! /* Backup optind and force sys.argv[0] = '-c' */
! optind--;
! argv[optind] = "-c";
}

! PySys_SetArgv(argc-optind, argv+optind);

if ((inspect || (command == NULL && filename == NULL)) &&
--- 250,259 ----

if (command != NULL) {
! /* Backup _PyOS_optind and force sys.argv[0] = '-c' */
! _PyOS_optind--;
! argv[_PyOS_optind] = "-c";
}

! PySys_SetArgv(argc-_PyOS_optind, argv+_PyOS_optind);

if ((inspect || (command == NULL && filename == NULL)) &&



From python-dev@python.org Fri Nov 3 12:58:11 2000
From: python-dev@python.org (Guido van Rossum)
Date: Fri, 3 Nov 2000 04:58:11 -0800
Subject: [Python-checkins] CVS: python/dist/src/Demo/pysvr Makefile,1.3,1.4
Message-ID: <200011031258.EAA32272@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Demo/pysvr
In directory slayer.i.sourceforge.net:/tmp/cvs-serv32260

Modified Files:
Makefile
Log Message:
Fix Makefile so at least it uses Python 2.0, and compiles out of the
box on Linux.


Index: Makefile
==================================================================RCS file: /cvsroot/python/python/dist/src/Demo/pysvr/Makefile,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** Makefile 1997/08/14 19:48:42 1.3
--- Makefile 2000/11/03 12:58:09 1.4
***************
*** 14,18 ****
# Where Python is installed, and which version
INST=/usr/local
! VER=1.5

# Expressions using the above definitions -- no need to change
--- 14,18 ----
# Where Python is installed, and which version
INST=/usr/local
! VER=2.0

# Expressions using the above definitions -- no need to change
***************
*** 29,33 ****
# (See LIBS= in Modules/Makefile in build tree)
RLLIBS=-lreadline -ltermcap
! OTHERLIBS=-lsocket -lnsl -lpthread -ldl -lm

# Compilation and link flags -- no need to change normally
--- 29,33 ----
# (See LIBS= in Modules/Makefile in build tree)
RLLIBS=-lreadline -ltermcap
! OTHERLIBS=-lnsl -lpthread -ldl -lm -ldb -lutil

# Compilation and link flags -- no need to change normally



From python-dev@python.org Fri Nov 3 15:42:23 2000
From: python-dev@python.org (Barry Warsaw)
Date: Fri, 3 Nov 2000 07:42:23 -0800
Subject: [Python-checkins] CVS: python/nondist/peps Makefile,1.1,1.2
Message-ID: <200011031542.HAA19766@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19757

Modified Files:
Makefile
Log Message:
Added `install' and `clean' targets.


Index: Makefile
==================================================================RCS file: /cvsroot/python/python/nondist/peps/Makefile,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** Makefile 2000/09/07 01:29:32 1.1
--- Makefile 2000/11/03 15:42:20 1.2
***************
*** 4,8 ****
# Not really important, but convenient.

! PEP2HTML=./pep2html.py -q

.SUFFIXES: .txt .html
--- 4,8 ----
# Not really important, but convenient.

! PEP2HTML=./pep2html.py

.SUFFIXES: .txt .html
***************
*** 14,15 ****
--- 14,21 ----

all: $(TARGETS)
+
+ install:
+ $(PEP2HTML) -i
+
+ clean:
+ -rm *.html



From python-dev@python.org Fri Nov 3 15:43:31 2000
From: python-dev@python.org (Barry Warsaw)
Date: Fri, 3 Nov 2000 07:43:31 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep2html.py,1.16,1.17
Message-ID: <200011031543.HAA19847@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19838

Modified Files:
pep2html.py
Log Message:
Document -q/--quiet in the module docstring.


Index: pep2html.py
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep2html.py,v
retrieving revision 1.16
retrieving revision 1.17
diff -C2 -r1.16 -r1.17
*** pep2html.py 2000/11/01 23:45:47 1.16
--- pep2html.py 2000/11/03 15:43:28 1.17
***************
*** 20,23 ****
--- 20,26 ----
ignored.

+ -q/--quiet
+ Turn off verbose messages.
+
-h/--help
Print this help message and exit.



From python-dev@python.org Fri Nov 3 20:24:17 2000
From: python-dev@python.org (Fredrik Lundh)
Date: Fri, 3 Nov 2000 12:24:17 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib/test/output test_unicodedata,1.3,1.4
Message-ID: <200011032024.MAA26242@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib/test/output
In directory slayer.i.sourceforge.net:/tmp/cvs-serv25791/lib/test/output

Modified Files:
test_unicodedata
Log Message:


Added 38,642 missing characters to the Unicode database (first-last
ranges) -- but thanks to the 2.0 compression scheme, this doesn't add
a single byte to the resulting binaries (!)

Closes bug #117524

Index: test_unicodedata
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/test/output/test_unicodedata,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** test_unicodedata 2000/09/27 12:25:14 1.3
--- test_unicodedata 2000/11/03 20:24:15 1.4
***************
*** 1,5 ****
test_unicodedata
Testing Unicode Database...
! Methods: 86793e1265f3cf5506e6ede8f69ab4deb973f3ea
! Functions: 5abd7e976848725e58f5834a0e5e37615f40d3a2
API: ok
--- 1,5 ----
test_unicodedata
Testing Unicode Database...
! Methods: 6c7a7c02657b69d0fdd7a7d174f573194bba2e18
! Functions: 41e1d4792185d6474a43c83ce4f593b1bdb01f8a
API: ok



From python-dev@python.org Fri Nov 3 20:24:17 2000
From: python-dev@python.org (Fredrik Lundh)
Date: Fri, 3 Nov 2000 12:24:17 -0800
Subject: [Python-checkins] CVS: python/dist/src/Objects unicodetype_db.h,1.2,1.3
Message-ID: <200011032024.MAA26233@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Objects
In directory slayer.i.sourceforge.net:/tmp/cvs-serv25791/Objects

Modified Files:
unicodetype_db.h
Log Message:


Added 38,642 missing characters to the Unicode database (first-last
ranges) -- but thanks to the 2.0 compression scheme, this doesn't add
a single byte to the resulting binaries (!)

Closes bug #117524

Index: unicodetype_db.h
==================================================================RCS file: /cvsroot/python/python/dist/src/Objects/unicodetype_db.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** unicodetype_db.h 2000/09/25 23:03:33 1.2
--- unicodetype_db.h 2000/11/03 20:24:15 1.3
***************
*** 1,3 ****
! /* this file was generated by Tools\unicode\makeunicodedata.py 1.1 */

/* a list of unique character type descriptors */
--- 1,3 ----
! /* this file was generated by tools\unicode\makeunicodedata.py 1.1 */

/* a list of unique character type descriptors */
***************
*** 151,231 ****
172, 173, 174, 90, 48, 175, 90, 48, 176, 177, 178, 48, 48, 179, 127, 36,
36, 124, 23, 146, 180, 23, 181, 182, 183, 23, 23, 23, 184, 23, 23, 185,
! 183, 186, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 187, 36, 36, 186, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 188, 36,
36, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 52, 189, 190, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 186, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 191, 36, 36, 192,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 193, 192, 36, 36, 193, 192, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 193, 192, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
--- 151,231 ----
172, 173, 174, 90, 48, 175, 90, 48, 176, 177, 178, 48, 48, 179, 127, 36,
36, 124, 23, 146, 180, 23, 181, 182, 183, 23, 23, 23, 184, 23, 23, 185,
! 183, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 186, 36, 36, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 187, 36,
36, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 52, 188, 189, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 190, 36, 36, 191,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 192, 191, 36, 36, 192, 191, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 192, 191, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
***************
*** 238,245 ****
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 193, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 194, 36, 36, 36, 36, 36, 36, 195, 196, 197, 48, 48, 198, 199,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 200, 201, 48, 202, 48, 203, 204,
! 36, 151, 205, 206, 48, 48, 48, 207, 208, 2, 209, 210, 48, 211, 212, 213,
};

--- 238,245 ----
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36,
! 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 36, 192, 48, 48, 48, 48, 48, 48,
! 48, 48, 48, 193, 36, 36, 36, 36, 36, 36, 194, 195, 196, 48, 48, 197, 198,
! 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, 199, 200, 48, 201, 48, 202, 203,
! 36, 151, 204, 205, 48, 48, 48, 206, 207, 2, 208, 209, 48, 210, 211, 212,
};

***************
*** 532,549 ****
1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0,
! 0, 40, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 40, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 40, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1,
! 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 40, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 40, 40, 40, 40, 40,
! 40, 40, 40, 40, 40, 40, 40, 40, 40, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 16, 16, 16, 16, 16, 16, 16, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 16, 16, 16, 16, 16, 0, 0, 0, 0, 0, 40, 1, 40, 40, 40, 40, 40,
40, 40, 40, 40, 40, 1, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40,
40, 0, 40, 40, 40, 40, 40, 0, 40, 0, 40, 40, 0, 40, 40, 0, 40, 40, 40,
--- 532,548 ----
1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0,
! 0, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40,
! 40, 40, 40, 40, 40, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 40, 40, 40, 40, 40, 40,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 1, 1, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1,
! 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0, 1, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 40, 40, 40, 40, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 40, 40, 40, 40,
! 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 16, 16, 16, 16, 16, 16, 16, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 16, 16, 16, 16, 16, 0, 0, 0, 0, 0, 40, 1, 40, 40, 40, 40, 40,
40, 40, 40, 40, 40, 1, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, 40,
40, 0, 40, 40, 40, 40, 40, 0, 40, 0, 40, 40, 0, 40, 40, 0, 40, 40, 40,



From python-dev@python.org Fri Nov 3 20:24:17 2000
From: python-dev@python.org (Fredrik Lundh)
Date: Fri, 3 Nov 2000 12:24:17 -0800
Subject: [Python-checkins] CVS: python/dist/src/Modules unicodedata_db.h,1.2,1.3
Message-ID: <200011032024.MAA26244@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Modules
In directory slayer.i.sourceforge.net:/tmp/cvs-serv25791/Modules

Modified Files:
unicodedata_db.h
Log Message:


Added 38,642 missing characters to the Unicode database (first-last
ranges) -- but thanks to the 2.0 compression scheme, this doesn't add
a single byte to the resulting binaries (!)

Closes bug #117524

Index: unicodedata_db.h
==================================================================RCS file: /cvsroot/python/python/dist/src/Modules/unicodedata_db.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** unicodedata_db.h 2000/09/25 08:07:05 1.2
--- unicodedata_db.h 2000/11/03 20:24:15 1.3
***************
*** 1,3 ****
! /* this file was generated by ..\Tools\unicode\makeunicodedata.py 1.1 */

/* a list of unique database records */
--- 1,3 ----
! /* this file was generated by tools\unicode\makeunicodedata.py 1.1 */

/* a list of unique database records */
***************
*** 3635,3639 ****
NULL
};
! /* index tables used to find the right database record */
#define SHIFT 5
static unsigned char index1[] = {
--- 3635,3639 ----
NULL
};
! /* index tables for the database records */
#define SHIFT 5
static unsigned char index1[] = {
***************
*** 3663,3744 ****
189, 190, 90, 103, 191, 90, 103, 192, 193, 194, 103, 103, 195, 128, 35,
35, 196, 197, 198, 199, 197, 200, 201, 202, 166, 166, 166, 203, 166, 166,
! 204, 202, 205, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 206, 35, 35, 205, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 207, 35, 35, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 208, 209, 210, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 205, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 211, 35, 35, 212, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 213, 212, 35, 35, 213, 212, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 213, 214, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
--- 3663,3763 ----
189, 190, 90, 103, 191, 90, 103, 192, 193, 194, 103, 103, 195, 128, 35,
35, 196, 197, 198, 199, 197, 200, 201, 202, 166, 166, 166, 203, 166, 166,
! 204, 202, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 205, 35, 35, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 206, 35, 35, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 207, 208, 209, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 103, 103, 103, 103, 103, 103, 103, 210, 35, 35, 211, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 212, 211, 35, 35, 212, 211, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 212, 213, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
***************
*** 3751,3758 ****
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 215, 103, 103, 103, 103, 103, 103, 103, 103, 103,
! 216, 35, 35, 35, 35, 35, 35, 217, 218, 219, 47, 47, 220, 221, 47, 47, 47,
! 47, 47, 47, 47, 47, 47, 47, 222, 223, 47, 224, 47, 225, 226, 35, 227,
! 228, 229, 47, 47, 47, 230, 231, 232, 233, 234, 235, 236, 237, 238,
};

--- 3770,3777 ----
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35, 35,
! 35, 35, 35, 35, 35, 35, 35, 214, 103, 103, 103, 103, 103, 103, 103, 103,
! 103, 215, 35, 35, 35, 35, 35, 35, 216, 217, 218, 47, 47, 219, 220, 47,
! 47, 47, 47, 47, 47, 47, 47, 47, 47, 221, 222, 47, 223, 47, 224, 225, 35,
! 226, 227, 228, 47, 47, 47, 229, 230, 231, 232, 233, 234, 235, 236, 237,
};

***************
*** 4099,4106 ****
42, 0, 0, 0, 0, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42,
42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42,
! 42, 42, 42, 0, 0, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 0,
0, 0, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
--- 4118,4124 ----
42, 0, 0, 0, 0, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42,
42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42,
! 42, 42, 42, 0, 0, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30,
! 30, 30, 30, 30, 30, 30, 30, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 30, 30, 30,
! 30, 30, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 0,
0, 0, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23,
***************
*** 4108,4127 ****
0, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 0, 23, 23, 23, 0, 23,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 115, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 115, 116, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 116, 30, 30, 30, 30,
! 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 21, 21, 21, 21, 21, 21, 21, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 21, 21, 21, 21, 21, 0, 0, 0, 0, 0, 64, 117, 64, 64, 64, 64,
! 64, 64, 64, 64, 64, 64, 11, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64,
! 64, 64, 0, 64, 64, 64, 64, 64, 0, 64, 0, 64, 64, 0, 64, 64, 0, 64, 64,
! 64, 64, 64, 64, 64, 64, 64, 64, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66,
66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66,
! 66, 66, 66, 66, 66, 66, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 66, 66, 66, 66, 66,
66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66,
66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66,
--- 4126,4145 ----
0, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 23, 0, 23, 23, 23, 0, 23,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 30, 30, 30, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 115, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 115, 116, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 116, 30, 30, 30,
! 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 30, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 21, 21, 21, 21, 21, 21, 21, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 21, 21, 21, 21, 21, 0, 0, 0, 0, 0, 64, 117, 64, 64, 64,
! 64, 64, 64, 64, 64, 64, 64, 11, 64, 64, 64, 64, 64, 64, 64, 64, 64, 64,
! 64, 64, 64, 0, 64, 64, 64, 64, 64, 0, 64, 0, 64, 64, 0, 64, 64, 0, 64,
! 64, 64, 64, 64, 64, 64, 64, 64, 64, 66, 66, 66, 66, 66, 66, 66, 66, 66,
66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66,
! 66, 66, 66, 66, 66, 66, 66, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
! 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 66, 66, 66, 66, 66,
66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66,
66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66,
***************
*** 4155,4159 ****
};

! /* same, for the decomposition data */
#define DECOMP_SHIFT 5
static unsigned char decomp_index1[] = {
--- 4173,4177 ----
};

! /* index tables for the decomposition data */
#define DECOMP_SHIFT 5
static unsigned char decomp_index1[] = {



From python-dev@python.org Fri Nov 3 20:24:17 2000
From: python-dev@python.org (Fredrik Lundh)
Date: Fri, 3 Nov 2000 12:24:17 -0800
Subject: [Python-checkins] CVS: python/dist/src/Tools/unicode makeunicodedata.py,1.7,1.8
Message-ID: <200011032024.MAA26229@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Tools/unicode
In directory slayer.i.sourceforge.net:/tmp/cvs-serv25791/tools/unicode

Modified Files:
makeunicodedata.py
Log Message:


Added 38,642 missing characters to the Unicode database (first-last
ranges) -- but thanks to the 2.0 compression scheme, this doesn't add
a single byte to the resulting binaries (!)

Closes bug #117524

Index: makeunicodedata.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Tools/unicode/makeunicodedata.py,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -r1.7 -r1.8
*** makeunicodedata.py 2000/10/26 03:56:46 1.7
--- makeunicodedata.py 2000/11/03 20:24:15 1.8
***************
*** 10,13 ****
--- 10,14 ----
# 2000-09-25 fl added character type table
# 2000-09-26 fl added LINEBREAK, DECIMAL, and DIGIT flags/fields
+ # 2000-11-03 fl expand first/last ranges
#
# written by Fredrik Lundh (fredrik@pythonware.com), September 2000
***************
*** 40,47 ****
UPPER_MASK = 0x80

! def maketables():

unicode = UnicodeData(UNICODE_DATA)

# extract unicode properties
dummy = (0, 0, 0, 0)
--- 41,51 ----
UPPER_MASK = 0x80

! def maketables(trace=0):

unicode = UnicodeData(UNICODE_DATA)

+ print "--- Processing", UNICODE_DATA, "..."
+ print len(filter(None, unicode.table)), "characters"
+
# extract unicode properties
dummy = (0, 0, 0, 0)
***************
*** 92,95 ****
--- 96,104 ----
FILE = "Modules/unicodedata_db.h"

+ print "--- Writing", FILE, "..."
+
+ print len(table), "unique properties"
+ print len(decomp_data), "unique decomposition entries"
+
fp = open(FILE, "w")
print >>fp, "/* this file was generated by %s %s */" % (SCRIPT, VERSION)
***************
*** 126,130 ****

# split record index table
! index1, index2, shift = splitbins(index)

print >>fp, "/* index tables for the database records */"
--- 135,139 ----

# split record index table
! index1, index2, shift = splitbins(index, trace)

print >>fp, "/* index tables for the database records */"
***************
*** 134,138 ****

# split decomposition index table
! index1, index2, shift = splitbins(decomp_index)

print >>fp, "/* index tables for the decomposition data */"
--- 143,147 ----

# split decomposition index table
! index1, index2, shift = splitbins(decomp_index, trace)

print >>fp, "/* index tables for the decomposition data */"
***************
*** 201,210 ****
index[char] = i

- print len(table), "ctype entries"
-
FILE = "Objects/unicodetype_db.h"

fp = open(FILE, "w")

print >>fp, "/* this file was generated by %s %s */" % (SCRIPT, VERSION)
print >>fp
--- 210,221 ----
index[char] = i

FILE = "Objects/unicodetype_db.h"

fp = open(FILE, "w")

+ print "--- Writing", FILE, "..."
+
+ print len(table), "unique character type entries"
+
print >>fp, "/* this file was generated by %s %s */" % (SCRIPT, VERSION)
print >>fp
***************
*** 217,221 ****

# split decomposition index table
! index1, index2, shift = splitbins(index)

print >>fp, "/* type indexes */"
--- 228,232 ----

# split decomposition index table
! index1, index2, shift = splitbins(index, trace)

print >>fp, "/* type indexes */"
***************
*** 234,238 ****
class UnicodeData:

! def __init__(self, filename):
file = open(filename)
table = [None] * 65536
--- 245,249 ----
class UnicodeData:

! def __init__(self, filename, expand=1):
file = open(filename)
table = [None] * 65536
***************
*** 245,248 ****
--- 256,275 ----
table[char] = s

+ # expand first-last ranges (ignore surrogates and private use)
+ if expand:
+ field = None
+ for i in range(0, 0xD800):
+ s = table[i]
+ if s:
+ if s[1][-6:] == "First>":
+ s[1] = ""
+ field = s[:]
+ elif s[1][-5:] == "Last>":
+ s[1] = ""
+ field = None
+ elif field:
+ field[0] = hex(i)
+ table[i] = field
+
# public attributes
self.filename = filename
***************
*** 307,312 ****
where mask is a bitmask isolating the last "shift" bits.

! If optional arg trace is true (default false), progress info is
! printed to sys.stderr.
"""

--- 334,340 ----
where mask is a bitmask isolating the last "shift" bits.

! If optional arg trace is non-zero (default zero), progress info
! is printed to sys.stderr. The higher the value, the more info
! you'll get.
"""

***************
*** 342,346 ****
# determine memory size
b = len(t1)*getsize(t1) + len(t2)*getsize(t2)
! if trace:
dump(t1, t2, shift, b)
if b < bytes:
--- 370,374 ----
# determine memory size
b = len(t1)*getsize(t1) + len(t2)*getsize(t2)
! if trace > 1:
dump(t1, t2, shift, b)
if b < bytes:
***************
*** 359,361 ****

if __name__ == "__main__":
! maketables()
--- 387,389 ----

if __name__ == "__main__":
! maketables(1)



From python-dev@python.org Fri Nov 3 20:50:48 2000
From: python-dev@python.org (M.-A. Lemburg)
Date: Fri, 03 Nov 2000 21:50:48 +0100
Subject: [Python-checkins] CVS: python/dist/src/Lib/test/output
test_unicodedata,1.3,1.4
References: <200011032024.MAA26242@slayer.i.sourceforge.net>
Message-ID: <3A032528.D743FC0A@lemburg.com>

Fredrik Lundh wrote:
Update of /cvsroot/python/python/dist/src/Lib/test/output
In directory slayer.i.sourceforge.net:/tmp/cvs-serv25791/lib/test/output

Modified Files:
test_unicodedata
Log Message:

Added 38,642 missing characters to the Unicode database (first-last
ranges) -- but thanks to the 2.0 compression scheme, this doesn't add
a single byte to the resulting binaries (!)

Closes bug #117524
Cool :-)

--
Marc-Andre Lemburg
______________________________________________________________________
Business: http://www.lemburg.com/
Python Pages: http://www.lemburg.com/python/


From python-dev@python.org Sun Nov 5 16:48:58 2000
From: python-dev@python.org (Moshe Zadka)
Date: Sun, 5 Nov 2000 08:48:58 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0216.txt,1.2,1.3
Message-ID: <200011051648.IAA13172@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv13154

Modified Files:
pep-0216.txt
Log Message:
Added requirements and problems.


Index: pep-0216.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0216.txt,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** pep-0216.txt 2000/08/23 05:49:27 1.2
--- pep-0216.txt 2000/11/05 16:48:55 1.3
***************
*** 7,10 ****
--- 7,94 ----
Created: 31-Jul-2000

+ Abstract
+
+ Named Python objects, such as modules, classes and functions, have a
+ string attribute called __doc__. If the first expression inside
+ the definition is a literal string, that string is assigned
+ to the __doc__ attribute.
+
+ The __doc__ attribute is called a documentation string, or docstring.
+ It is often used to summarize the interface of the module, class or
+ function. However, since there is no common format for documentation
+ string, tools for extracting docstrings and transforming those into
+ documentation in a standard format (e.g., DocBook) have not sprang
+ up in abundance, and those that do exist are for the most part
+ unmaintained and unused.
+
+ Perl Documentation
+
+ In Perl, most modules are documented in a format called POD -- Plain
+ Old Documentation. This is an easy-to-type, very low level format
+ which integrates well with the Perl parser. Many tools exist to turn
+ POD documentation into other formats: info, HTML and man pages, among
+ others. However, in Perl, the information is not available at run-time.
+
+ Java Documentation
+
+ In Java, special comments before classes and functions function to
+ document the code. A program to extract these, and turn them into
+ HTML documentation is called javadoc, and is part of the standard
+ Java distribution. However, the only output format that is supported
+ is HTML, and JavaDoc has a very intimate relationship with HTML.
+
+ Python Docstring Goals
+
+ Python documentation string are easy to spot during parsing, and are
+ also available to the runtime interpreter. This double purpose is
+ a bit problematic, sometimes: for example, some are reluctant to have
+ too long docstrings, because they do not want to take much space in
+ the runtime. In addition, because of the current lack of tools, people
+ read objects' docstrings by "print"ing them, so a tendancy to make them
+ brief and free of markups has sprung up. This tendancy hinders writing
+ better documentation-extraction tools, since it causes docstrings to
+ contain little information, which is hard to parse.
+
+ High Level Solutions
+
+ To counter the objection that the strings take up place in the running
+ program, it is suggested that documentation extraction tools will
+ concatenate a maximum prefix of string literals which appear in the
+ beginning of a definition. The first of these will also be available
+ in the interactive interpreter, so it should contain a few summary
+ lines.
+
+ Docstring Format Goals
+
+ These are the goals for the docstring format, as discussed ad neasum
+ in the doc-sig.
+
+ 1. It must be easy to type with any standard text editor.
+ 2. It must be readable to the casual observer.
+ 3. It must not contain information which can be deduced from parsing
+ the module.
+ 4. It must contain sufficient information so it can be converted
+ to any reasonable markup format.
+ 5. It must be possible to write a module's entire documentation in
+ docstrings, without feeling hampered by the markup language.
+
+ Docstring Contents
+
+ For requirement 5. above, it is needed to specify what must be
+ in docstrings.
+
+ At least the following must be available:
+
+ a. A tag that means "this is a Python ``something'', guess what"
+ b. Tags that mean "this is a Python class/module/class var/instance var..."
+ c. An easy way to include Python source code/Python interactive sessions
+ d. Emphasis/bold
+ e. List/tables
+
+ Rejected Suggestions
+
+ XML -- it's very hard to type, and too cluttered to read it
+ comfortably.
+





From python-dev@python.org Sun Nov 5 16:55:27 2000
From: python-dev@python.org (Moshe Zadka)
Date: Sun, 5 Nov 2000 08:55:27 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0228.txt,NONE,1.1 pep-0000.txt,1.44,1.45
Message-ID: <200011051655.IAA13536@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv13461

Modified Files:
pep-0000.txt
Added Files:
pep-0228.txt
Log Message:
Added first revision of numerical model pep.


***** Error reading new file: (2, 'No such file or directory')
***** file: pep-0228.txt cwd: /tmp/cvs-serv13461
Index: pep-0000.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0000.txt,v
retrieving revision 1.44
retrieving revision 1.45
diff -C2 -r1.44 -r1.45
*** pep-0000.txt 2000/11/03 02:56:05 1.44
--- pep-0000.txt 2000/11/05 16:55:24 1.45
***************
*** 120,123 ****
--- 120,124 ----
I 226 pep-0226.txt Python 2.1 Release Schedule Hylton
S 227 pep-0227.txt Statically Nested Scopes Hylton
+ S 228 pep-0228.txt Reworking Python's Numeric Model Zadka





From python-dev@python.org Sun Nov 5 20:36:11 2000
From: python-dev@python.org (Moshe Zadka)
Date: Sun, 5 Nov 2000 12:36:11 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0228.txt,1.1,1.2
Message-ID: <200011052036.MAA09976@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv9952

Modified Files:
pep-0228.txt
Log Message:
Added some issues because of Py-Dev feedback


Index: pep-0228.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0228.txt,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** pep-0228.txt 2000/11/05 16:55:24 1.1
--- pep-0228.txt 2000/11/05 20:36:06 1.2
***************
*** 1,3 ****
! PEP: Unassigned
Title: Reworking Python's Numeric Model
Version: $Revision$
--- 1,3 ----
! PEP: 228
Title: Reworking Python's Numeric Model
Version: $Revision$
***************
*** 76,104 ****
mathematicl result.

- 6. Rationale -- The rationale fleshes out the specification by
- describing what motivated the design and why particular design
- decisions were made. It should describe alternate designs that
- were considered and related work, e.g. how the feature is
- supported in other languages.
-
- The rationale should provide evidence of consensus within the
- community and discuss important objections or concerns raised
- during discussion.
-
- 7. Reference Implementation -- The reference implementation must
- be completed before any PEP is given status 'final,' but it
- need not be completed before the PEP is accepted. It is better
- to finish the specification and rationale first and reach
- consensus on it before writing code.
-
- The final implementation must include test code and
- documentation appropriate for either the Python language
- reference or the standard library reference.
-
Numerical Python Issues

! People using Numerical Python do that for high-performance
! vector operations. Therefore, NumPy should keep it's hardware
! based numeric model.

Copyright
--- 76,90 ----
mathematicl result.

Numerical Python Issues
+
+ People using Numerical Python do that for high-performance
+ vector operations. Therefore, NumPy should keep it's hardware
+ based numeric model.
+
+ Unresolved Issues
+
+ Which number literals will be exact, and which inexact?

! How do we deal with IEEE 754?

Copyright



From python-dev@python.org Mon Nov 6 00:44:37 2000
From: python-dev@python.org (Guido van Rossum)
Date: Sun, 5 Nov 2000 16:44:37 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0000.txt,1.45,1.46
Message-ID: <200011060044.QAA27975@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv27965

Modified Files:
pep-0000.txt
Log Message:
Add 228 (numerical model) to the pie-in-the-sky category -- this can't
be ready for Python 2.1.


Index: pep-0000.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0000.txt,v
retrieving revision 1.45
retrieving revision 1.46
diff -C2 -r1.45 -r1.46
*** pep-0000.txt 2000/11/05 16:55:24 1.45
--- pep-0000.txt 2000/11/06 00:44:34 1.46
***************
*** 47,50 ****
--- 47,51 ----
SD 224 pep-0224.txt Attribute Docstrings Lemburg
SD 225 pep-0225.txt Elementwise/Objectwise Operators Zhu, Lielens
+ S 228 pep-0228.txt Reworking Python's Numeric Model Zadka

Incomplete PEPs (only an abstract)



From python-dev@python.org Mon Nov 6 02:49:29 2000
From: python-dev@python.org (Mark Hammond)
Date: Sun, 5 Nov 2000 18:49:29 -0800
Subject: [Python-checkins] CVS: python/dist/src/Tools/freeze modulefinder.py,1.14,1.15
Message-ID: <200011060249.SAA15782@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Tools/freeze
In directory slayer.i.sourceforge.net:/tmp/cvs-serv15773

Modified Files:
modulefinder.py
Log Message:
Application of [ Patch #102226 ] freeze/modulefinder.py should use _winreg, not win32api

Index: modulefinder.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Tools/freeze/modulefinder.py,v
retrieving revision 1.14
retrieving revision 1.15
diff -C2 -r1.14 -r1.15
*** modulefinder.py 2000/09/15 16:37:42 1.14
--- modulefinder.py 2000/11/06 02:49:27 1.15
***************
*** 9,23 ****
import sys

- if sys.platform=="win32":
- # On Windows, we can locate modules in the registry with
- # the help of the win32api package.
- try:
- import win32api
- except ImportError:
- print "The win32api module is not available - modules listed"
- print "in the registry will not be found."
- win32api = None
-
-
IMPORT_NAME = dis.opname.index('IMPORT_NAME')
IMPORT_FROM = dis.opname.index('IMPORT_FROM')
--- 9,12 ----
***************
*** 340,352 ****

# Emulate the Registered Module support on Windows.
! if sys.platform=="win32" and win32api is not None:
! HKEY_LOCAL_MACHINE = 0x80000002
try:
! pathname = win32api.RegQueryValue(HKEY_LOCAL_MACHINE, "Software\\Python\\PythonCore\\%s\\Modules\\%s" % (sys.winver, name))
fp = open(pathname, "rb")
# XXX - To do - remove the hard code of C_EXTENSION.
stuff = "", "rb", imp.C_EXTENSION
return fp, pathname, stuff
! except win32api.error:
pass

--- 329,343 ----

# Emulate the Registered Module support on Windows.
! if sys.platform=="win32":
! import _winreg
! from _winreg import HKEY_LOCAL_MACHINE
try:
! pathname = _winreg.QueryValueEx(HKEY_LOCAL_MACHINE, \
! "Software\\Python\\PythonCore\\%s\\Modules\\%s" % (sys.winver, name))
fp = open(pathname, "rb")
# XXX - To do - remove the hard code of C_EXTENSION.
stuff = "", "rb", imp.C_EXTENSION
return fp, pathname, stuff
! except _winreg.error:
pass




From python-dev@python.org Mon Nov 6 03:33:54 2000
From: python-dev@python.org (Jeremy Hylton)
Date: Sun, 5 Nov 2000 19:33:54 -0800
Subject: [Python-checkins] CVS: python/dist/src/Tools/compiler/compiler transformer.py,1.17,1.18
Message-ID: <200011060333.TAA18666@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Tools/compiler/compiler
In directory slayer.i.sourceforge.net:/tmp/cvs-serv18510

Modified Files:
transformer.py
Log Message:
If a function contains a doc string, remove the doc string node from
the function's body.

If assert is used without an error message, make the AST node None
rather than Name('None').



Index: transformer.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Tools/compiler/compiler/transformer.py,v
retrieving revision 1.17
retrieving revision 1.18
diff -C2 -r1.17 -r1.18
*** transformer.py 2000/10/25 18:10:32 1.17
--- transformer.py 2000/11/06 03:33:52 1.18
***************
*** 174,177 ****
--- 174,181 ----
code = self.com_node(nodelist[4])

+ if doc is not None:
+ assert isinstance(code, Stmt)
+ assert isinstance(code.nodes[0], Discard)
+ del code.nodes[0]
n = Function(name, names, defaults, flags, doc, code)
n.lineno = lineno
***************
*** 401,405 ****
expr2 = self.com_node(nodelist[3])
else:
! expr2 = Name('None')
n = Assert(expr1, expr2)
n.lineno = nodelist[0][2]
--- 405,409 ----
expr2 = self.com_node(nodelist[3])
else:
! expr2 = None
n = Assert(expr1, expr2)
n.lineno = nodelist[0][2]



From python-dev@python.org Mon Nov 6 03:43:14 2000
From: python-dev@python.org (Jeremy Hylton)
Date: Sun, 5 Nov 2000 19:43:14 -0800
Subject: [Python-checkins] CVS: python/dist/src/Tools/compiler/compiler pycodegen.py,1.26,1.27 pyassem.py,1.13,1.14 misc.py,1.6,1.7
Message-ID: <200011060343.TAA19466@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Tools/compiler/compiler
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19430

Modified Files:
pycodegen.py pyassem.py misc.py
Log Message:
Change the graph structure to contain the code generator object for
embedded code objects (e.g. functions) rather than the generated code
object. This change means that the compiler generates code for
everything at the end, rather then generating code for each function
as it finds it. Implementation note: _convert_LOAD_CONST in
pyassem.py must be change to call getCode().

Other changes follow. Several changes creates extra edges between
basic blocks to reflect control flow for loops and exceptions. These
missing edges had gone unnoticed because they do not affect the
current compilation process.

pyassem.py:
Add _enable_debug() and _disable_debug() methods that print
instructions and blocks to stdout as they are generated.

Add edges between blocks for instructions like SETUP_LOOP,
FOR_LOOP, etc.

Add pruneNext to get rid of bogus edges remaining after
unconditional transfer ops (e.g. JUMP_FORWARD)

Change repr of Block to omit block length.

pycodegen.py:
Make sure a new block is started after FOR_LOOP, etc.

Change assert implementation to use RAISE_VARARGS 1 when there is
no user-specified failure output.

misc.py:
Implement __contains__ and copy for Set.





Index: pycodegen.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Tools/compiler/compiler/pycodegen.py,v
retrieving revision 1.26
retrieving revision 1.27
diff -C2 -r1.26 -r1.27
*** pycodegen.py 2000/10/13 21:58:13 1.26
--- pycodegen.py 2000/11/06 03:43:11 1.27
***************
*** 161,165 ****
for default in node.defaults:
self.visit(default)
! self.emit('LOAD_CONST', gen.getCode())
self.emit('MAKE_FUNCTION', len(node.defaults))

--- 161,165 ----
for default in node.defaults:
self.visit(default)
! self.emit('LOAD_CONST', gen)
self.emit('MAKE_FUNCTION', len(node.defaults))

***************
*** 196,200 ****
self.visit(suite)
self.emit('JUMP_FORWARD', end)
! self.nextBlock(nextTest)
self.emit('POP_TOP')
if node.else_:
--- 196,200 ----
self.visit(suite)
self.emit('JUMP_FORWARD', end)
! self.startBlock(nextTest)
self.emit('POP_TOP')
if node.else_:
***************
*** 244,251 ****
self.set_lineno(node)
self.emit('FOR_LOOP', anchor)
self.visit(node.assign)
self.visit(node.body)
self.emit('JUMP_ABSOLUTE', start)
! self.nextBlock(anchor)
self.emit('POP_BLOCK')
if node.else_:
--- 244,252 ----
self.set_lineno(node)
self.emit('FOR_LOOP', anchor)
+ self.nextBlock()
self.visit(node.assign)
self.visit(node.body)
self.emit('JUMP_ABSOLUTE', start)
! self.startBlock(anchor)
self.emit('POP_BLOCK')
if node.else_:
***************
*** 305,309 ****
end = self.newBlock()
self.emit('JUMP_FORWARD', end)
! self.nextBlock(cleanup)
self.emit('ROT_TWO')
self.emit('POP_TOP')
--- 306,310 ----
end = self.newBlock()
self.emit('JUMP_FORWARD', end)
! self.startBlock(cleanup)
self.emit('ROT_TWO')
self.emit('POP_TOP')
***************
*** 345,353 ****
skip_one = self.newBlock()
self.emit('JUMP_FORWARD', skip_one)
! self.nextBlock(cont)
self.emit('POP_TOP')
self.nextBlock(skip_one)
self.emit('JUMP_ABSOLUTE', start)
! self.nextBlock(anchor)
self.delName(append)

--- 346,354 ----
skip_one = self.newBlock()
self.emit('JUMP_FORWARD', skip_one)
! self.startBlock(cont)
self.emit('POP_TOP')
self.nextBlock(skip_one)
self.emit('JUMP_ABSOLUTE', start)
! self.startBlock(anchor)
self.delName(append)

***************
*** 364,367 ****
--- 365,369 ----
self.nextBlock(start)
self.emit('FOR_LOOP', anchor)
+ self.nextBlock()
self.visit(node.assign)
return start, anchor
***************
*** 391,397 ****
self.emit('JUMP_IF_TRUE', end)
self.nextBlock()
self.emit('LOAD_GLOBAL', 'AssertionError')
! self.visit(node.fail)
! self.emit('RAISE_VARARGS', 2)
self.nextBlock(end)
self.emit('POP_TOP')
--- 393,403 ----
self.emit('JUMP_IF_TRUE', end)
self.nextBlock()
+ self.emit('POP_TOP')
self.emit('LOAD_GLOBAL', 'AssertionError')
! if node.fail:
! self.visit(node.fail)
! self.emit('RAISE_VARARGS', 2)
! else:
! self.emit('RAISE_VARARGS', 1)
self.nextBlock(end)
self.emit('POP_TOP')
***************
*** 420,427 ****
self.set_lineno(node)
self.emit('SETUP_EXCEPT', handlers)
self.visit(node.body)
self.emit('POP_BLOCK')
self.emit('JUMP_FORWARD', lElse)
! self.nextBlock(handlers)

last = len(node.handlers) - 1
--- 426,434 ----
self.set_lineno(node)
self.emit('SETUP_EXCEPT', handlers)
+ self.nextBlock()
self.visit(node.body)
self.emit('POP_BLOCK')
self.emit('JUMP_FORWARD', lElse)
! self.startBlock(handlers)

last = len(node.handlers) - 1
***************
*** 447,450 ****
--- 454,459 ----
if expr:
self.nextBlock(next)
+ else:
+ self.nextBlock()
self.emit('POP_TOP')
self.emit('END_FINALLY')
***************
*** 458,461 ****
--- 467,471 ----
self.set_lineno(node)
self.emit('SETUP_FINALLY', final)
+ self.nextBlock()
self.visit(node.body)
self.emit('POP_BLOCK')

Index: pyassem.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Tools/compiler/compiler/pyassem.py,v
retrieving revision 1.13
retrieving revision 1.14
diff -C2 -r1.13 -r1.14
*** pyassem.py 2000/10/13 21:58:13 1.13
--- pyassem.py 2000/11/06 03:43:11 1.14
***************
*** 4,11 ****
--- 4,19 ----
import new
import string
+ import sys
import types

from compiler import misc

+ def xxx_sort(l):
+ l = l[:]
+ def sorter(a, b):
+ return cmp(a.bid, b.bid)
+ l.sort(sorter)
+ return l
+
class FlowGraph:
def __init__(self):
***************
*** 17,27 ****

def startBlock(self, block):
self.current = block

! def nextBlock(self, block=None):
! if block is None:
! block = self.newBlock()
# XXX think we need to specify when there is implicit transfer
! # from one block to the next
#
# I think this strategy works: each block has a child
--- 25,40 ----

def startBlock(self, block):
+ if self._debug:
+ if self.current:
+ print "end", repr(self.current)
+ print " ", self.current.get_children()
+ print repr(block)
self.current = block

! def nextBlock(self, block=None, force=0):
# XXX think we need to specify when there is implicit transfer
! # from one block to the next. might be better to represent this
! # with explicit JUMP_ABSOLUTE instructions that are optimized
! # out when they are unnecessary.
#
# I think this strategy works: each block has a child
***************
*** 31,34 ****
--- 44,57 ----
# immediately after its parent.
# Worry: maintaining this invariant could be tricky
+ if block is None:
+ block = self.newBlock()
+
+ # Note: If the current block ends with an unconditional
+ # control transfer, then it is incorrect to add an implicit
+ # transfer to the block graph. The current code requires
+ # these edges to get the blocks emitted in the right order,
+ # however. :-( If a client needs to remove these edges, call
+ # pruneEdges().
+
self.current.addNext(block)
self.startBlock(block)
***************
*** 42,52 ****
self.startBlock(self.exit)

def emit(self, *inst):
! # XXX should jump instructions implicitly call nextBlock?
if inst[0] == 'RETURN_VALUE':
self.current.addOutEdge(self.exit)
self.current.emit(inst)

! def getBlocks(self):
"""Return the blocks in reverse postorder

--- 65,86 ----
self.startBlock(self.exit)

+ _debug = 0
+
+ def _enable_debug(self):
+ self._debug = 1
+
+ def _disable_debug(self):
+ self._debug = 0
+
def emit(self, *inst):
! if self._debug:
! print "\t", inst
if inst[0] == 'RETURN_VALUE':
self.current.addOutEdge(self.exit)
+ if len(inst) == 2 and isinstance(inst[1], Block):
+ self.current.addOutEdge(inst[1])
self.current.emit(inst)

! def getBlocksInOrder(self):
"""Return the blocks in reverse postorder

***************
*** 65,75 ****
if not self.exit in order:
order.append(self.exit)
return order

def dfs_postorder(b, seen):
"""Depth-first search of tree rooted at b, return in postorder"""
order = []
seen[b] = b
! for c in b.children():
if seen.has_key(c):
continue
--- 99,153 ----
if not self.exit in order:
order.append(self.exit)
+
+ ## for b in order:
+ ## print repr(b)
+ ## print "\t", b.get_children()
+ ## print b
+ ## print
+
return order

+ def getBlocks(self):
+ return self.blocks.elements()
+
+ def getRoot(self):
+ """Return nodes appropriate for use with dominator"""
+ return self.entry
+
+ def getContainedGraphs(self):
+ l = []
+ for b in self.getBlocks():
+ l.extend(b.getContainedGraphs())
+ return l
+
+ _uncond_transfer = ('RETURN_VALUE', 'RAISE_VARARGS',
+ 'JUMP_ABSOLUTE', 'JUMP_FORWARD')
+
+ def pruneNext(self):
+ """Remove bogus edge for unconditional transfers
+
+ Each block has a next edge that accounts for implicit control
+ transfers, e.g. from a JUMP_IF_FALSE to the block that will be
+ executed if the test is true.
+
+ These edges must remain for the current assembler code to
+ work. If they are removed, the dfs_postorder gets things in
+ weird orders. However, they shouldn't be there for other
+ purposes, e.g. conversion to SSA form. This method will
+ remove the next edge when it follows an unconditional control
+ transfer.
+ """
+ try:
+ op, arg = self.insts[-1]
+ except (IndexError, TypeError):
+ return
+ if op in self._uncond_transfer:
+ self.next = []
+
def dfs_postorder(b, seen):
"""Depth-first search of tree rooted at b, return in postorder"""
order = []
seen[b] = b
! for c in b.get_children():
if seen.has_key(c):
continue
***************
*** 92,99 ****
def __repr__(self):
if self.label:
! return "<block %s id=%d len=%d>" % (self.label, self.bid,
! len(self.insts))
else:
! return "<block id=%d len=%d>" % (self.bid, len(self.insts))

def __str__(self):
--- 170,176 ----
def __repr__(self):
if self.label:
! return "<block %s id=%d>" % (self.label, self.bid)
else:
! return "<block id=%d>" % (self.bid)

def __str__(self):
***************
*** 121,127 ****
assert len(self.next) == 1, map(str, self.next)

! def children(self):
return self.outEdges.elements() + self.next

# flags for code objects
CO_OPTIMIZED = 0x0001
--- 198,221 ----
assert len(self.next) == 1, map(str, self.next)

! def get_children(self):
! if self.next and self.next[0] in self.outEdges:
! self.outEdges.remove(self.next[0])
return self.outEdges.elements() + self.next

+ def getContainedGraphs(self):
+ """Return all graphs contained within this block.
+
+ For example, a MAKE_FUNCTION block will contain a reference to
+ the graph for the function body.
+ """
+ contained = []
+ for inst in self.insts:
+ if len(inst) == 1:
+ continue
+ op = inst[1]
+ if hasattr(op, 'graph'):
+ contained.append(op.graph)
+ return contained
+
# flags for code objects
CO_OPTIMIZED = 0x0001
***************
*** 205,209 ****
begin = {}
end = {}
! for b in self.getBlocks():
begin[b] = pc
for inst in b.getInstructions():
--- 299,303 ----
begin = {}
end = {}
! for b in self.getBlocksInOrder():
begin[b] = pc
for inst in b.getInstructions():
***************
*** 275,278 ****
--- 369,374 ----
_converters = {}
def _convert_LOAD_CONST(self, arg):
+ if hasattr(arg, 'getCode'):
+ arg = arg.getCode()
return self._lookupName(arg, self.consts)


Index: misc.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Tools/compiler/compiler/misc.py,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -r1.6 -r1.7
*** misc.py 2000/03/16 20:02:38 1.6
--- misc.py 2000/11/06 03:43:11 1.7
***************
*** 15,18 ****
--- 15,20 ----
def __len__(self):
return len(self.elts)
+ def __contains__(self, elt):
+ return self.elts.has_key(elt)
def add(self, elt):
self.elts[elt] = elt
***************
*** 23,26 ****
--- 25,32 ----
def remove(self, elt):
del self.elts[elt]
+ def copy(self):
+ c = Set()
+ c.elts.update(self.elts)
+ return c

class Stack:



From python-dev@python.org Mon Nov 6 03:47:41 2000
From: python-dev@python.org (Jeremy Hylton)
Date: Sun, 5 Nov 2000 19:47:41 -0800
Subject: [Python-checkins] CVS: python/dist/src/Tools/compiler/compiler pyassem.py,1.14,1.15
Message-ID: <200011060347.TAA20007@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Tools/compiler/compiler
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19954/compiler

Modified Files:
pyassem.py
Log Message:
move pruneNext method to correct object (doh!)


Index: pyassem.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Tools/compiler/compiler/pyassem.py,v
retrieving revision 1.14
retrieving revision 1.15
diff -C2 -r1.14 -r1.15
*** pyassem.py 2000/11/06 03:43:11 1.14
--- pyassem.py 2000/11/06 03:47:39 1.15
***************
*** 121,148 ****
return l

- _uncond_transfer = ('RETURN_VALUE', 'RAISE_VARARGS',
- 'JUMP_ABSOLUTE', 'JUMP_FORWARD')
-
- def pruneNext(self):
- """Remove bogus edge for unconditional transfers
-
- Each block has a next edge that accounts for implicit control
- transfers, e.g. from a JUMP_IF_FALSE to the block that will be
- executed if the test is true.
-
- These edges must remain for the current assembler code to
- work. If they are removed, the dfs_postorder gets things in
- weird orders. However, they shouldn't be there for other
- purposes, e.g. conversion to SSA form. This method will
- remove the next edge when it follows an unconditional control
- transfer.
- """
- try:
- op, arg = self.insts[-1]
- except (IndexError, TypeError):
- return
- if op in self._uncond_transfer:
- self.next = []
-
def dfs_postorder(b, seen):
"""Depth-first search of tree rooted at b, return in postorder"""
--- 121,124 ----
***************
*** 197,200 ****
--- 173,200 ----
self.next.append(block)
assert len(self.next) == 1, map(str, self.next)
+
+ _uncond_transfer = ('RETURN_VALUE', 'RAISE_VARARGS',
+ 'JUMP_ABSOLUTE', 'JUMP_FORWARD')
+
+ def pruneNext(self):
+ """Remove bogus edge for unconditional transfers
+
+ Each block has a next edge that accounts for implicit control
+ transfers, e.g. from a JUMP_IF_FALSE to the block that will be
+ executed if the test is true.
+
+ These edges must remain for the current assembler code to
+ work. If they are removed, the dfs_postorder gets things in
+ weird orders. However, they shouldn't be there for other
+ purposes, e.g. conversion to SSA form. This method will
+ remove the next edge when it follows an unconditional control
+ transfer.
+ """
+ try:
+ op, arg = self.insts[-1]
+ except (IndexError, ValueError):
+ return
+ if op in self._uncond_transfer:
+ self.next = []

def get_children(self):



From python-dev@python.org Mon Nov 6 15:30:02 2000
From: python-dev@python.org (Barry Warsaw)
Date: Mon, 6 Nov 2000 07:30:02 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0228.txt,1.2,1.3
Message-ID: <200011061530.HAA23507@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv23491

Modified Files:
pep-0228.txt
Log Message:
Spell-checking, grammar, formatting.


Index: pep-0228.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0228.txt,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** pep-0228.txt 2000/11/05 20:36:06 1.2
--- pep-0228.txt 2000/11/06 15:29:58 1.3
***************
*** 5,8 ****
--- 5,9 ----
Status: Draft
Type: Standards Track
+ Python-Version: ??
Created: 4-Nov-2000
Post-History:
***************
*** 10,45 ****
Abstract

! Today, Python's numerical model is similar to the C numeric model:
! there are several unrelated numerical types, and when operations
! between numerical types are requested, coercions happen. While the C
! rational for the numerical model is that it is very similar to what
! happens on the hardware level, that rational does not apply to Python.
! So, while it is acceptable to C programmers that 2/3 == 0, it is very
! surprising to Python programmers.

Rationale

- In usability studies, one of Python hardest to learn features was
- the fact integer division returns the floor of the division. This
- makes it hard to program correctly, requiring casts to float() in
- various parts through the code. Python numerical model stems from
- C, while an easier numerical model would stem from the mathematical
- understanding of numbers.

Other Numerical Models

! Perl's numerical model is that there is one type of numbers -- floating
! point numbers. While it is consistent and superficially non-suprising,
! it tends to have subtle gotchas. One of these is that printing numbers
! is very tricky, and requires correct rounding. In Perl, there is also
! a mode where all numbers are integers. This mode also has its share of
! problems, which arise from the fact that there is not even an approximate
! way of dividing numbers and getting meaningful answers.
!
! Suggested Interface For Python Numerical Model
!
! While coercion rules will remain for add-on types and classes, the built
! in type system will have exactly one Python type -- a number. There
! are several things which can be considered "number methods":

1. isnatural()
--- 11,51 ----
Abstract

! Today, Python's numerical model is similar to the C numeric model:
! there are several unrelated numerical types, and when operations
! between numerical types are requested, coercions happen. While
! the C rationale for the numerical model is that it is very similar
! to what happens on the hardware level, that rationale does not
! apply to Python. So, while it is acceptable to C programmers that
! 2/3 == 0, it is very surprising to Python programmers.

+
Rationale
+
+ In usability studies, one of Python features hardest to learn was
+ the fact that integer division returns the floor of the division.
+ This makes it hard to program correctly, requiring casts to
+ float() in various parts through the code. Python's numerical
+ model stems from C, while an easier numerical model would stem
+ from the mathematical understanding of numbers.


Other Numerical Models

! Perl's numerical model is that there is one type of numbers --
! floating point numbers. While it is consistent and superficially
! non-surprising, it tends to have subtle gotchas. One of these is
! that printing numbers is very tricky, and requires correct
! rounding. In Perl, there is also a mode where all numbers are
! integers. This mode also has its share of problems, which arise
! from the fact that there is not even an approximate way of
! dividing numbers and getting meaningful answers.
!
!
! Suggested Interface For Python's Numerical Model
!
! While coercion rules will remain for add-on types and classes, the
! built in type system will have exactly one Python type -- a
! number. There are several things which can be considered "number
! methods":

1. isnatural()
***************
*** 51,65 ****
a. isexact()

! Obviously, a number which answers m as true, also answers m+k as true.
! If "isexact()" is not true, then any answer might be wrong. (But not
! horribly wrong: it's close the truth).

Now, there is two thing the models promises for the field operations
(+, -, /, *):

! If both operands satisfy isexact(), the result satisfies isexact()

! All field rules are true, except that for not-isexact() numbers,
! they might be only approximately true.

There is one important operation, inexact() which takes a number
--- 57,72 ----
a. isexact()

! Obviously, a number which answers m as true, also answers m+k as
! true. If "isexact()" is not true, then any answer might be wrong.
! (But not horribly wrong: it's close to the truth.)

Now, there is two thing the models promises for the field operations
(+, -, /, *):

! - If both operands satisfy isexact(), the result satisfies
! isexact().

! - All field rules are true, except that for not-isexact() numbers,
! they might be only approximately true.

There is one important operation, inexact() which takes a number
***************
*** 69,85 ****
when given inexact numbers: e.g, int().

Inexact Operations

- The functions in the "math" module will be allowed to return inexact
- results for exact values. However, they will never return a non-real
- number. The functions in the "cmath" module will return the correct
- mathematicl result.

Numerical Python Issues

! People using Numerical Python do that for high-performance
! vector operations. Therefore, NumPy should keep it's hardware
! based numeric model.

Unresolved Issues

--- 76,95 ----
when given inexact numbers: e.g, int().

+
Inexact Operations
+
+ The functions in the "math" module will be allowed to return
+ inexact results for exact values. However, they will never return
+ a non-real number. The functions in the "cmath" module will
+ return the correct mathematical result.


Numerical Python Issues

! People who use Numerical Python do so for high-performance vector
! operations. Therefore, NumPy should keep its hardware based
! numeric model.

+
Unresolved Issues

***************
*** 88,94 ****
--- 98,106 ----
How do we deal with IEEE 754?

+
Copyright

This document has been placed in the public domain.
+





From python-dev@python.org Mon Nov 6 15:30:49 2000
From: python-dev@python.org (Barry Warsaw)
Date: Mon, 6 Nov 2000 07:30:49 -0800
Subject: [Python-checkins] CVS: python/nondist/peps Makefile,1.2,1.3
Message-ID: <200011061530.HAA23602@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv23585

Modified Files:
Makefile
Log Message:
Added `update' target


Index: Makefile
==================================================================RCS file: /cvsroot/python/python/nondist/peps/Makefile,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** Makefile 2000/11/03 15:42:20 1.2
--- Makefile 2000/11/06 15:30:47 1.3
***************
*** 20,21 ****
--- 20,24 ----
clean:
-rm *.html
+
+ update:
+ cvs update -P -d



From python-dev@python.org Mon Nov 6 16:03:54 2000
From: python-dev@python.org (Jeremy Hylton)
Date: Mon, 6 Nov 2000 08:03:54 -0800
Subject: [Python-checkins] CVS: python/dist/src/Tools/compiler/compiler transformer.py,1.18,1.19
Message-ID: <200011061603.IAA26508@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Tools/compiler/compiler
In directory slayer.i.sourceforge.net:/tmp/cvs-serv26474

Modified Files:
transformer.py
Log Message:
a few small optimizations that seem to give a 5-10% speedup; the
further optimization of com_node makes the most difference.


Index: transformer.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Tools/compiler/compiler/transformer.py,v
retrieving revision 1.18
retrieving revision 1.19
diff -C2 -r1.18 -r1.19
*** transformer.py 2000/11/06 03:33:52 1.18
--- transformer.py 2000/11/06 16:03:52 1.19
***************
*** 83,90 ****

def __init__(self):
! self._dispatch = { }
for value, name in symbol.sym_name.items():
if hasattr(self, name):
self._dispatch[value] = getattr(self, name)

def transform(self, tree):
--- 83,99 ----

def __init__(self):
! self._dispatch = {}
for value, name in symbol.sym_name.items():
if hasattr(self, name):
self._dispatch[value] = getattr(self, name)
+ self._dispatch[token.NEWLINE] = self.com_NEWLINE
+ self._atom_dispatch = {token.LPAR: self.atom_lpar,
+ token.LSQB: self.atom_lsqb,
+ token.LBRACE: self.atom_lbrace,
+ token.BACKQUOTE: self.atom_backquote,
+ token.NUMBER: self.atom_number,
+ token.STRING: self.atom_string,
+ token.NAME: self.atom_name,
+ }

def transform(self, tree):
***************
*** 485,489 ****
# testlist: expr (',' expr)* [',']
# exprlist: expr (',' expr)* [',']
! return self.com_binary('tuple', nodelist)

exprlist = testlist
--- 494,498 ----
# testlist: expr (',' expr)* [',']
# exprlist: expr (',' expr)* [',']
! return self.com_binary(Tuple, nodelist)

exprlist = testlist
***************
*** 493,501 ****
if len(nodelist) == 1 and nodelist[0][0] == symbol.lambdef:
return self.lambdef(nodelist[0])
! return self.com_binary('or', nodelist)

def and_test(self, nodelist):
# not_test ('and' not_test)*
! return self.com_binary('and', nodelist)

def not_test(self, nodelist):
--- 502,510 ----
if len(nodelist) == 1 and nodelist[0][0] == symbol.lambdef:
return self.lambdef(nodelist[0])
! return self.com_binary(Or, nodelist)

def and_test(self, nodelist):
# not_test ('and' not_test)*
! return self.com_binary(And, nodelist)

def not_test(self, nodelist):
***************
*** 545,557 ****
def expr(self, nodelist):
# xor_expr ('|' xor_expr)*
! return self.com_binary('bitor', nodelist)

def xor_expr(self, nodelist):
# xor_expr ('^' xor_expr)*
! return self.com_binary('bitxor', nodelist)

def and_expr(self, nodelist):
# xor_expr ('&' xor_expr)*
! return self.com_binary('bitand', nodelist)

def shift_expr(self, nodelist):
--- 554,566 ----
def expr(self, nodelist):
# xor_expr ('|' xor_expr)*
! return self.com_binary(Bitor, nodelist)

def xor_expr(self, nodelist):
# xor_expr ('^' xor_expr)*
! return self.com_binary(Bitxor, nodelist)

def and_expr(self, nodelist):
# xor_expr ('&' xor_expr)*
! return self.com_binary(Bitand, nodelist)

def shift_expr(self, nodelist):
***************
*** 584,610 ****
for i in range(2, len(nodelist), 2):
right = self.com_node(nodelist[i])
! if nodelist[i-1][0] == token.STAR:
node = Mul([node, right])
! node.lineno = nodelist[1][2]
! elif nodelist[i-1][0] == token.SLASH:
node = Div([node, right])
- node.lineno = nodelist[1][2]
else:
node = Mod([node, right])
! node.lineno = nodelist[1][2]
return node

def factor(self, nodelist):
! t = nodelist[0][0]
node = self.com_node(nodelist[-1])
if t == token.PLUS:
node = UnaryAdd(node)
! node.lineno = nodelist[0][2]
elif t == token.MINUS:
node = UnarySub(node)
! node.lineno = nodelist[0][2]
elif t == token.TILDE:
node = Invert(node)
! node.lineno = nodelist[0][2]
return node

--- 593,619 ----
for i in range(2, len(nodelist), 2):
right = self.com_node(nodelist[i])
! t = nodelist[i-1][0]
! if t == token.STAR:
node = Mul([node, right])
! elif t == token.SLASH:
node = Div([node, right])
else:
node = Mod([node, right])
! node.lineno = nodelist[1][2]
return node

def factor(self, nodelist):
! elt = nodelist[0]
! t = elt[0]
node = self.com_node(nodelist[-1])
if t == token.PLUS:
node = UnaryAdd(node)
! node.lineno = elt[2]
elif t == token.MINUS:
node = UnarySub(node)
! node.lineno = elt[2]
elif t == token.TILDE:
node = Invert(node)
! node.lineno = elt[2]
return node

***************
*** 613,674 ****
node = self.com_node(nodelist[0])
for i in range(1, len(nodelist)):
! if nodelist[i][0] == token.DOUBLESTAR:
n = Power([node, self.com_node(nodelist[i+1])])
! n.lineno = nodelist[i][2]
return n

! node = self.com_apply_trailer(node, nodelist[i])

return node

def atom(self, nodelist):
! t = nodelist[0][0]
! if t == token.LPAR:
! if nodelist[1][0] == token.RPAR:
! n = Tuple(())
! n.lineno = nodelist[0][2]
! return n
! return self.com_node(nodelist[1])
!
! if t == token.LSQB:
! if nodelist[1][0] == token.RSQB:
! n = List(())
! n.lineno = nodelist[0][2]
! return n
! return self.com_list_constructor(nodelist[1])

! if t == token.LBRACE:
! if nodelist[1][0] == token.RBRACE:
! return Dict(())
! return self.com_dictmaker(nodelist[1])
!
! if t == token.BACKQUOTE:
! n = Backquote(self.com_node(nodelist[1]))
n.lineno = nodelist[0][2]
return n

! if t == token.NUMBER:
! ### need to verify this matches compile.c
! k = eval(nodelist[0][1])
! n = Const(k)
n.lineno = nodelist[0][2]
return n

! if t == token.STRING:
! ### need to verify this matches compile.c
! k = ''
! for node in nodelist:
! k = k + eval(node[1])
! n = Const(k)
! n.lineno = nodelist[0][2]
! return n

! if t == token.NAME:
! ### any processing to do?
! n = Name(nodelist[0][1])
! n.lineno = nodelist[0][2]
! return n

! raise error, "unknown node type"

# --------------------------------------------------------------
--- 622,683 ----
node = self.com_node(nodelist[0])
for i in range(1, len(nodelist)):
! elt = nodelist[i]
! if elt[0] == token.DOUBLESTAR:
n = Power([node, self.com_node(nodelist[i+1])])
! n.lineno = elt[2]
return n

! node = self.com_apply_trailer(node, elt)

return node

def atom(self, nodelist):
! return self._atom_dispatch[nodelist[0][0]](nodelist)

! def atom_lpar(self, nodelist):
! if nodelist[1][0] == token.RPAR:
! n = Tuple(())
n.lineno = nodelist[0][2]
return n
+ return self.com_node(nodelist[1])

! def atom_lsqb(self, nodelist):
! if nodelist[1][0] == token.RSQB:
! n = List(())
n.lineno = nodelist[0][2]
return n
+ return self.com_list_constructor(nodelist[1])

! def atom_lbrace(self, nodelist):
! if nodelist[1][0] == token.RBRACE:
! return Dict(())
! return self.com_dictmaker(nodelist[1])

! def atom_backquote(self, nodelist):
! n = Backquote(self.com_node(nodelist[1]))
! n.lineno = nodelist[0][2]
! return n
!
! def atom_number(self, nodelist):
! ### need to verify this matches compile.c
! k = eval(nodelist[0][1])
! n = Const(k)
! n.lineno = nodelist[0][2]
! return n
!
! def atom_string(self, nodelist):
! ### need to verify this matches compile.c
! k = ''
! for node in nodelist:
! k = k + eval(node[1])
! n = Const(k)
! n.lineno = nodelist[0][2]
! return n

! def atom_name(self, nodelist):
! ### any processing to do?
! n = Name(nodelist[0][1])
! n.lineno = nodelist[0][2]
! return n

# --------------------------------------------------------------
***************
*** 682,699 ****
# and compound_stmt.
# We'll just dispatch them.

# A ';' at the end of a line can make a NEWLINE token appear
# here, Render it harmless. (genc discards ('discard',
# ('const', xxxx)) Nodes)
! key = node[0]
!
! meth = self._dispatch.get(key, None)
! if meth:
! return meth(node[1:])
! else:
! if key == token.NEWLINE:
! return Discard(Const(None))
!
! raise error, 'illegal node passed to com_node: %s' % `node`

def com_arglist(self, nodelist):
--- 691,701 ----
# and compound_stmt.
# We'll just dispatch them.
+ return self._dispatch[node[0]](node[1:])

+ def com_NEWLINE(self):
# A ';' at the end of a line can make a NEWLINE token appear
# here, Render it harmless. (genc discards ('discard',
# ('const', xxxx)) Nodes)
! return Discard(Const(None))

def com_arglist(self, nodelist):
***************
*** 908,917 ****
def com_assign_trailer(self, primary, node, assigning):
t = node[1][0]
- if t == token.LPAR:
- raise SyntaxError, "can't assign to function call"
if t == token.DOT:
return self.com_assign_attr(primary, node[2], assigning)
if t == token.LSQB:
return self.com_subscriptlist(primary, node[2], assigning)
raise SyntaxError, "unknown trailer type: %s" % t

--- 910,919 ----
def com_assign_trailer(self, primary, node, assigning):
t = node[1][0]
if t == token.DOT:
return self.com_assign_attr(primary, node[2], assigning)
if t == token.LSQB:
return self.com_subscriptlist(primary, node[2], assigning)
+ if t == token.LPAR:
+ raise SyntaxError, "can't assign to function call"
raise SyntaxError, "unknown trailer type: %s" % t

***************
*** 919,923 ****
return AssAttr(primary, node[1], assigning)

! def com_binary(self, type, nodelist):
"Compile 'NODE (OP NODE)*' into (type, [ node1, ..., nodeN ])."
l = len(nodelist)
--- 921,925 ----
return AssAttr(primary, node[1], assigning)

! def com_binary(self, constructor, nodelist):
"Compile 'NODE (OP NODE)*' into (type, [ node1, ..., nodeN ])."
l = len(nodelist)
***************
*** 927,931 ****
for i in range(0, l, 2):
items.append(self.com_node(nodelist[i]))
! return Node(type, items)

def com_stmt(self, node):
--- 929,933 ----
for i in range(0, l, 2):
items.append(self.com_node(nodelist[i]))
! return constructor(items)

def com_stmt(self, node):
***************
*** 965,969 ****
fors = []
while node:
! if node[1][1] == 'for':
assignNode = self.com_assign(node[2], OP_ASSIGN)
listNode = self.com_node(node[4])
--- 967,972 ----
fors = []
while node:
! t = node[1][1]
! if t == 'for':
assignNode = self.com_assign(node[2], OP_ASSIGN)
listNode = self.com_node(node[4])
***************
*** 975,979 ****
else:
node = self.com_list_iter(node[5])
! elif node[1][1] == 'if':
test = self.com_node(node[2])
newif = ListCompIf(test)
--- 978,982 ----
else:
node = self.com_list_iter(node[5])
! elif t == 'if':
test = self.com_node(node[2])
newif = ListCompIf(test)
***************
*** 1102,1108 ****
# slice_item: expression | proper_slice | ellipsis
ch = node[1]
! if ch[0] == token.DOT and node[2][0] == token.DOT:
return Ellipsis()
! if ch[0] == token.COLON or len(node) > 2:
return self.com_sliceobj(node)
return self.com_node(ch)
--- 1105,1112 ----
# slice_item: expression | proper_slice | ellipsis
ch = node[1]
! t = ch[0]
! if t == token.DOT and node[2][0] == token.DOT:
return Ellipsis()
! if t == token.COLON or len(node) > 2:
return self.com_sliceobj(node)
return self.com_node(ch)



From python-dev@python.org Mon Nov 6 18:22:01 2000
From: python-dev@python.org (Moshe Zadka)
Date: Mon, 6 Nov 2000 10:22:01 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0000.txt,1.46,1.47 pep-0207.txt,1.1,1.2
Message-ID: <200011061822.KAA05805@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv5783

Modified Files:
pep-0000.txt pep-0207.txt
Log Message:
Changed ownership to MAL and me.


Index: pep-0000.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0000.txt,v
retrieving revision 1.46
retrieving revision 1.47
diff -C2 -r1.46 -r1.47
*** pep-0000.txt 2000/11/06 00:44:34 1.46
--- pep-0000.txt 2000/11/06 18:21:58 1.47
***************
*** 32,36 ****

I 42 pep-0042.txt Small Feature Requests Hylton
! S 207 pep-0207.txt Rich Comparisons Ascher
S 208 pep-0208.txt Reworking the Coercion Model Ascher
S 217 pep-0217.txt Display Hook for Interactive Use Zadka
--- 32,36 ----

I 42 pep-0042.txt Small Feature Requests Hylton
! S 207 pep-0207.txt Rich Comparisons Zadka, Lemburg
S 208 pep-0208.txt Reworking the Coercion Model Ascher
S 217 pep-0217.txt Display Hook for Interactive Use Zadka
***************
*** 100,104 ****
SD 205 pep-0205.txt Weak References Drake
I 206 pep-0206.txt 2.0 Batteries Included Zadka
! S 207 pep-0207.txt Rich Comparisons Ascher
S 208 pep-0208.txt Reworking the Coercion Model Ascher
SD 209 pep-0209.txt Adding Multidimensional Arrays Ascher
--- 100,104 ----
SD 205 pep-0205.txt Weak References Drake
I 206 pep-0206.txt 2.0 Batteries Included Zadka
! S 207 pep-0207.txt Rich Comparisons Zadka, Lemburg
S 208 pep-0208.txt Reworking the Coercion Model Ascher
SD 209 pep-0209.txt Adding Multidimensional Arrays Ascher

Index: pep-0207.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0207.txt,v
retrieving revision 1.1
retrieving revision 1.2
diff -C2 -r1.1 -r1.2
*** pep-0207.txt 2000/07/15 23:28:27 1.1
--- pep-0207.txt 2000/11/06 18:21:58 1.2
***************
*** 2,6 ****
Title: Rich Comparisions
Version: $Revision$
! Owner: davida@activestate.com (David Ascher)
Python-Version: 2.1
Status: Incomplete
--- 2,6 ----
Title: Rich Comparisions
Version: $Revision$
! Owner: mal@lemburg.com (Marc-Andre Lemburg), pep@zadka.site.co.il (Moshe Zadka)
Python-Version: 2.1
Status: Incomplete



From python-dev@python.org Mon Nov 6 18:46:11 2000
From: python-dev@python.org (Barry Warsaw)
Date: Mon, 6 Nov 2000 10:46:11 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib cgi.py,1.55,1.56
Message-ID: <200011061846.KAA07862@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv7854

Modified Files:
cgi.py
Log Message:
This fixes several bug reports concering memory bloating during large
file uploads.

In response to SF bugs 110674 and 119806, and discussions on
python-dev, we are removing the self.lines attribute from the
FieldStorage class. Specifically touched where methods __init__(),
read_lines_to_eof(), and skip_lines().

No one can remember why self.lines was added. Technically, it's part
of the public interface for the class, but it was never documented.
It's possible clever or nosy code will break because of this, but it
was decided to remove it and see who complains.

This resolution also closes the second half of the cgi.py entry in PEP
42. The first half of that PEP concerns specifically binary file
uploads, where there may be no end-of-line marker for a very long
time. This patch does not address that issue.


Index: cgi.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/cgi.py,v
retrieving revision 1.55
retrieving revision 1.56
diff -C2 -r1.55 -r1.56
*** cgi.py 2000/10/03 13:51:09 1.55
--- cgi.py 2000/11/06 18:46:09 1.56
***************
*** 20,24 ****
#

! __version__ = "2.4"


--- 20,24 ----
#

! __version__ = "2.5"


***************
*** 498,502 ****
self.list = self.file = None
self.done = 0
- self.lines = []
if ctype == 'application/x-www-form-urlencoded':
self.read_urlencoded()
--- 498,501 ----
***************
*** 634,638 ****
self.done = -1
break
- self.lines.append(line)
self.file.write(line)

--- 633,636 ----
***************
*** 647,651 ****
self.done = -1
break
- self.lines.append(line)
if line[:2] == "--":
strippedline = string.strip(line)
--- 645,648 ----
***************
*** 677,681 ****
self.done = -1
break
- self.lines.append(line)
if line[:2] == "--":
strippedline = string.strip(line)
--- 674,677 ----



From python-dev@python.org Mon Nov 6 18:49:08 2000
From: python-dev@python.org (Barry Warsaw)
Date: Mon, 6 Nov 2000 10:49:08 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0042.txt,1.42,1.43
Message-ID: <200011061849.KAA08213@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv8189

Modified Files:
pep-0042.txt
Log Message:
Updated the cgi.py entry after it was resolved to remove the
self.lines attribute. This doesn't completely address the binary file
upload part of the feature request.


Index: pep-0042.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0042.txt,v
retrieving revision 1.42
retrieving revision 1.43
diff -C2 -r1.42 -r1.43
*** pep-0042.txt 2000/11/02 16:54:19 1.42
--- pep-0042.txt 2000/11/06 18:49:06 1.43
***************
*** 178,186 ****
a binary type.

! Second, because the lines that are read are stored in an
! instance attribute (self.lines -- a list), the uploaded data is
! never freed. self.lines isn't definied as part of the public
! interface it /might/ be safe to remove it. OTOH, removing it
! will break code clever and nosy code.

- urllib should support proxy definitions that contain just the
--- 178,185 ----
a binary type.

! The second issue was related to the self.lines attribute, which
! was removed in revision 1.56 of cgi.py (see also):
!
! http://sourceforge.net/bugs/?funcÞtailbug&bug_id9806&group_idT70

- urllib should support proxy definitions that contain just the



From python-dev@python.org Mon Nov 6 20:17:40 2000
From: python-dev@python.org (Fred L. Drake)
Date: Mon, 6 Nov 2000 12:17:40 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib libstdtypes.tex,1.40,1.41
Message-ID: <200011062017.MAA18607@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv18590/lib

Modified Files:
libstdtypes.tex
Log Message:

Document the proper exception to be raised by I/O operations on closed
files; error reported by Ng Pheng Siong <ngps@post1.com>.

Make sure that various special object attributes are properly indexed.


Index: libstdtypes.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/libstdtypes.tex,v
retrieving revision 1.40
retrieving revision 1.41
diff -C2 -r1.40 -r1.41
*** libstdtypes.tex 2000/10/25 21:03:55 1.40
--- libstdtypes.tex 2000/11/06 20:17:37 1.41
***************
*** 973,976 ****
--- 973,977 ----
It is written as \code{Ellipsis}.

+
\subsubsection{File Objects\obindex{file}
\label{bltin-file-objects}}
***************
*** 996,1001 ****
\begin{methoddesc}[file]{close}{}
Close the file. A closed file cannot be read or written anymore.
! Any operation which requires that the file be open will raise an
! \exception{IOError} after the file has been closed. Calling
\method{close()} more than once is allowed.
\end{methoddesc}
--- 997,1002 ----
\begin{methoddesc}[file]{close}{}
Close the file. A closed file cannot be read or written anymore.
! Any operation which requires that the file be open will raise a
! \exception{ValueError} after the file has been closed. Calling
\method{close()} more than once is allowed.
\end{methoddesc}
***************
*** 1138,1141 ****
--- 1139,1143 ----
\end{memberdesc}

+
\subsubsection{Internal Objects \label{typesinternal}}

***************
*** 1150,1174 ****
object types, where they are relevant:

! \begin{memberdescni}{__dict__}
! A dictionary of some sort used to store an
object's (writable) attributes.
! \end{memberdescni}

! \begin{memberdescni}{__methods__}
List of the methods of many built-in object types,
e.g., \code{[].__methods__} yields
\code{['append', 'count', 'index', 'insert', 'pop', 'remove',
! 'reverse', 'sort']}.
! \end{memberdescni}

! \begin{memberdescni}{__members__}
! Similar to \member{__methods__}, but lists data attributes.
! \end{memberdescni}

! \begin{memberdescni}{__class__}
The class to which a class instance belongs.
! \end{memberdescni}

! \begin{memberdescni}{__bases__}
The tuple of base classes of a class object.
! \end{memberdescni}
--- 1152,1178 ----
object types, where they are relevant:

! \begin{memberdesc}[object]{__dict__}
! A dictionary or other mapping object used to store an
object's (writable) attributes.
! \end{memberdesc}

! \begin{memberdesc}[object]{__methods__}
List of the methods of many built-in object types,
e.g., \code{[].__methods__} yields
\code{['append', 'count', 'index', 'insert', 'pop', 'remove',
! 'reverse', 'sort']}. This usually does not need to be explicitly
! provided by the object.
! \end{memberdesc}

! \begin{memberdesc}[object]{__members__}
! Similar to \member{__methods__}, but lists data attributes. This
! usually does not need to be explicitly provided by the object.
! \end{memberdesc}

! \begin{memberdesc}[instance]{__class__}
The class to which a class instance belongs.
! \end{memberdesc}

! \begin{memberdesc}[class]{__bases__}
The tuple of base classes of a class object.
! \end{memberdesc}



From python-dev@python.org Tue Nov 7 03:34:47 2000
From: python-dev@python.org (A.M. Kuchling)
Date: Mon, 6 Nov 2000 19:34:47 -0800
Subject: [Python-checkins] CVS: python/dist/src/Modules _cursesmodule.c,2.40,2.41
Message-ID: <200011070334.TAA23335@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Modules
In directory slayer.i.sourceforge.net:/tmp/cvs-serv23315

Modified Files:
_cursesmodule.c
Log Message:
Patch #102278: add tparm() function to _curses module


Index: _cursesmodule.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Modules/_cursesmodule.c,v
retrieving revision 2.40
retrieving revision 2.41
diff -C2 -r2.40 -r2.41
*** _cursesmodule.c 2000/11/01 19:59:12 2.40
--- _cursesmodule.c 2000/11/07 03:34:44 2.41
***************
*** 48,55 ****
savetty scr_dump scr_init scr_restore scr_set scrl set_curterm
set_term setterm setupterm tgetent tgetflag tgetnum tgetstr
! tgoto timeout tparm tputs tputs typeahead use_default_colors
! vidattr vidputs waddchnstr waddchstr wchgat wcolor_set
! winchnstr winchstr winnstr wmouse_trafo wredrawln wscrl
! wtimeout

Low-priority:
--- 48,54 ----
savetty scr_dump scr_init scr_restore scr_set scrl set_curterm
set_term setterm setupterm tgetent tgetflag tgetnum tgetstr
! tgoto timeout tputs typeahead use_default_colors vidattr
! vidputs waddchnstr waddchstr wchgat wcolor_set winchnstr
! winchstr winnstr wmouse_trafo wredrawln wscrl wtimeout

Low-priority:
***************
*** 2099,2102 ****
--- 2098,2152 ----

static PyObject *
+ PyCurses_tparm(PyObject *self, PyObject *args)
+ {
+ char* fmt;
+ char* result = NULL;
+ int i1,i2,i3,i4,i5,i6,i7,i8,i9;
+
+ PyCursesInitialised;
+
+ if (!PyArg_ParseTuple(args, "s|iiiiiiiii:tparm",
+ &fmt, &i1, &i2, &i3, &i4,
+ &i5, &i6, &i7, &i8, &i9)) {
+ return NULL;
+ }
+
+ switch (PyTuple_GET_SIZE(args)) {
+ case 1:
+ result = tparm(fmt);
+ break;
+ case 2:
+ result = tparm(fmt,i1);
+ break;
+ case 3:
+ result = tparm(fmt,i1,i2);
+ break;
+ case 4:
+ result = tparm(fmt,i1,i2,i3);
+ break;
+ case 5:
+ result = tparm(fmt,i1,i2,i3,i4);
+ break;
+ case 6:
+ result = tparm(fmt,i1,i2,i3,i4,i5);
+ break;
+ case 7:
+ result = tparm(fmt,i1,i2,i3,i4,i5,i6);
+ break;
+ case 8:
+ result = tparm(fmt,i1,i2,i3,i4,i5,i6,i7);
+ break;
+ case 9:
+ result = tparm(fmt,i1,i2,i3,i4,i5,i6,i7,i8);
+ break;
+ case 10:
+ result = tparm(fmt,i1,i2,i3,i4,i5,i6,i7,i8,i9);
+ break;
+ }
+
+ return PyString_FromString(result);
+ }
+
+ static PyObject *
PyCurses_TypeAhead(PyObject *self, PyObject *args)
{
***************
*** 2247,2250 ****
--- 2297,2301 ----
{"tigetnum", (PyCFunction)PyCurses_tigetnum, METH_VARARGS},
{"tigetstr", (PyCFunction)PyCurses_tigetstr, METH_VARARGS},
+ {"tparm", (PyCFunction)PyCurses_tparm, METH_VARARGS},
{"typeahead", (PyCFunction)PyCurses_TypeAhead},
{"unctrl", (PyCFunction)PyCurses_UnCtrl},



From python-dev@python.org Tue Nov 7 03:35:26 2000
From: python-dev@python.org (A.M. Kuchling)
Date: Mon, 6 Nov 2000 19:35:26 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib libcurses.tex,1.20,1.21
Message-ID: <200011070335.TAA23460@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv23347

Modified Files:
libcurses.tex
Log Message:
Patch #102278: add tparm() function to _curses module


Index: libcurses.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/libcurses.tex,v
retrieving revision 1.20
retrieving revision 1.21
diff -C2 -r1.20 -r1.21
*** libcurses.tex 2000/10/10 17:03:45 1.20
--- libcurses.tex 2000/11/07 03:35:24 1.21
***************
*** 467,470 ****
--- 467,477 ----
\end{funcdesc}

+ \begin{funcdesc}{tparm}{str\optional{,...}}
+ Instantiates the string \var{str} with the supplied parameters, where
+ \var{str} should be a parameterized string obtained from the terminfo
+ database. E.g. \code{tparm(tigetstr("cup"),5,3)} could result in
+ \code{"\e{}033[6;4H"}, the exact result depending on terminal type.
+ \end{funcdesc}
+
\begin{funcdesc}{typeahead}{fd}
Specifies that the file descriptor \var{fd} be used for typeahead



From python-dev@python.org Tue Nov 7 09:11:07 2000
From: python-dev@python.org (Moshe Zadka)
Date: Tue, 7 Nov 2000 01:11:07 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0216.txt,1.3,1.4
Message-ID: <200011070911.BAA13249@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv13156

Modified Files:
pep-0216.txt
Log Message:
Added structured text consensus.


Index: pep-0216.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0216.txt,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** pep-0216.txt 2000/11/05 16:48:55 1.3
--- pep-0216.txt 2000/11/07 09:11:04 1.4
***************
*** 86,89 ****
--- 86,106 ----
e. List/tables

+ Docstring Basic Structure
+
+ The documentation strings will be in StructuredText
+ (http://www.zope.org/Members/jim/StructuredTextWiki/StructuredTextNG)
+ Since StructuredText is not yet strong enough to handle (a) and (b)
+ above, we will need to extend it. I suggest using
+ '[<optional description>:python identifier]'.
+ E.g.: [class:POP3], [:POP3.list], etc. If the description is missing,
+ a guess will be made from the text.
+
+ Unresolved Issues
+
+ How do we describe input and output types of functions?
+
+ What additional constraint do we enforce on each docstring?
+ (module/class/function)?
+
Rejected Suggestions




From python-dev@python.org Tue Nov 7 09:36:42 2000
From: python-dev@python.org (Fredrik Lundh)
Date: Tue, 7 Nov 2000 10:36:42 +0100
Subject: [Python-checkins] CVS: python/nondist/peps pep-0216.txt,1.3,1.4
References: <200011070911.BAA13249@slayer.i.sourceforge.net>
Message-ID: <01e301c0489e$3e349540$0900a8c0@SPIFF>

Moshe Zadka wrote:
Modified Files:
pep-0216.txt
Log Message:
Added structured text consensus.
when/where was this discussed?

</F>



From Moshe Zadka <moshez@math.huji.ac.il> Tue Nov 7 09:49:54 2000
From: Moshe Zadka (Moshe Zadka)
Date: Tue, 7 Nov 2000 11:49:54 +0200 (IST)
Subject: [Python-checkins] CVS: python/nondist/peps pep-0216.txt,1.3,1.4
In-Reply-To: <01e301c0489e$3e349540$0900a8c0@SPIFF>
Message-ID: <Pine.GSO.4.10.10011071149300.13407-100000@sundial>
On Tue, 7 Nov 2000, Fredrik Lundh wrote:

Moshe Zadka wrote:
Modified Files:
pep-0216.txt
Log Message:
Added structured text consensus.
when/where was this discussed?
ummmm....doc-sig, where all things documentation-related are discussed?

--
Moshe Zadka <moshez@math.huji.ac.il> -- 95855124
http://advogato.org/person/moshez



From python-dev@python.org Tue Nov 7 14:54:52 2000
From: python-dev@python.org (Greg Ward)
Date: Tue, 7 Nov 2000 06:54:52 -0800
Subject: [Python-checkins] CVS: python/nondist/sf-html sf-faq.html,1.16,1.17
Message-ID: <200011071454.GAA26318@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/sf-html
In directory slayer.i.sourceforge.net:/tmp/cvs-serv26310

Modified Files:
sf-faq.html
Log Message:
Fixed a couple of typos.

Index: sf-faq.html
==================================================================RCS file: /cvsroot/python/python/nondist/sf-html/sf-faq.html,v
retrieving revision 1.16
retrieving revision 1.17
diff -C2 -r1.16 -r1.17
*** sf-faq.html 2000/11/01 22:03:00 1.16
--- sf-faq.html 2000/11/07 14:54:50 1.17
***************
*** 336,340 ****

<h4>A:</h4>
! You probably want to turn of keyword expansion and line-ending conversion:

<blockquote>
--- 336,340 ----

<h4>A:</h4>
! You probably want to turn off keyword expansion and line-ending conversion:

<blockquote>
***************
*** 451,455 ****
<a href="http://sourceforge.net/bugs/?group_idT70">http://sourceforge.net/bugs/?group_idT70</a> for all bug management needs.

! <h3><a name="b1" id="b1"></a>6.1.:</h3>

<h4>Q: How do I use the sourceforge bug manager?</h4>
--- 451,455 ----
<a href="http://sourceforge.net/bugs/?group_idT70">http://sourceforge.net/bugs/?group_idT70</a> for all bug management needs.

! <h3><a name="b2" id="b2"></a>6.2.:</h3>

<h4>Q: How do I use the sourceforge bug manager?</h4>



From python-dev@python.org Tue Nov 7 15:44:24 2000
From: python-dev@python.org (Greg Ward)
Date: Tue, 7 Nov 2000 07:44:24 -0800
Subject: [Python-checkins] CVS: python/dist/src configure.in,1.177,1.178 configure,1.169,1.170
Message-ID: <200011071544.HAA31147@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src
In directory slayer.i.sourceforge.net:/tmp/cvs-serv30976

Modified Files:
configure.in configure
Log Message:
Fix for SF bug #117606:
- when compiling with GCC on Solaris, use "$(CC) -shared" instead
of "$(CC) -G" to generate .so files
- when compiling with GCC on any platform, add "-fPIC" to OPT
(without this, "$(CC) -shared" dies horribly)


Index: configure.in
==================================================================RCS file: /cvsroot/python/python/dist/src/configure.in,v
retrieving revision 1.177
retrieving revision 1.178
diff -C2 -r1.177 -r1.178
*** configure.in 2000/11/03 08:18:36 1.177
--- configure.in 2000/11/07 15:44:21 1.178
***************
*** 309,314 ****
yes)
case $ac_cv_prog_cc_g in
! yes) OPT="-g -O2 -Wall -Wstrict-prototypes";;
! *) OPT="-O2 -Wall -Wstrict-prototypes";;
esac
;;
--- 309,314 ----
yes)
case $ac_cv_prog_cc_g in
! yes) OPT="-g -O2 -Wall -Wstrict-prototypes -fPIC";;
! *) OPT="-O2 -Wall -Wstrict-prototypes -fPIC";;
esac
;;
***************
*** 565,569 ****
SunOS/5*)
if test "$GCC" = "yes"
! then LDSHARED='$(CC) -G'
else LDSHARED="ld -G";
fi ;;
--- 565,569 ----
SunOS/5*)
if test "$GCC" = "yes"
! then LDSHARED='$(CC) -shared'
else LDSHARED="ld -G";
fi ;;

Index: configure
==================================================================RCS file: /cvsroot/python/python/dist/src/configure,v
retrieving revision 1.169
retrieving revision 1.170
diff -C2 -r1.169 -r1.170
*** configure 2000/11/03 08:18:36 1.169
--- configure 2000/11/07 15:44:21 1.170
***************
*** 1,5 ****
#! /bin/sh

! # From configure.in Revision: 1.176

# Guess values for system-dependent variables and create Makefiles.
--- 1,5 ----
#! /bin/sh

! # From configure.in Revision: 1.178

# Guess values for system-dependent variables and create Makefiles.
***************
*** 1194,1199 ****
yes)
case $ac_cv_prog_cc_g in
! yes) OPT="-g -O2 -Wall -Wstrict-prototypes";;
! *) OPT="-O2 -Wall -Wstrict-prototypes";;
esac
;;
--- 1194,1199 ----
yes)
case $ac_cv_prog_cc_g in
! yes) OPT="-g -O2 -Wall -Wstrict-prototypes -fPIC";;
! *) OPT="-O2 -Wall -Wstrict-prototypes -fPIC";;
esac
;;
***************
*** 2651,2655 ****
SunOS/5*)
if test "$GCC" = "yes"
! then LDSHARED='$(CC) -G'
else LDSHARED="ld -G";
fi ;;
--- 2651,2655 ----
SunOS/5*)
if test "$GCC" = "yes"
! then LDSHARED='$(CC) -shared'
else LDSHARED="ld -G";
fi ;;
***************
*** 4840,4844 ****

/* Ultrix mips cc rejects this. */
! typedef int charset[2]; const charset x = {0,0};
/* SunOS 4.1.1 cc rejects this. */
char const *const *ccp;
--- 4840,4844 ----

/* Ultrix mips cc rejects this. */
! typedef int charset[2]; const charset x;
/* SunOS 4.1.1 cc rejects this. */
char const *const *ccp;
***************
*** 4915,4919 ****

int main() {
! } int $ac_kw foo() {
; return 0; }
EOF
--- 4915,4919 ----

int main() {
! } $ac_kw foo() {
; return 0; }
EOF



From python-dev@python.org Tue Nov 7 16:09:57 2000
From: python-dev@python.org (Fred L. Drake)
Date: Tue, 7 Nov 2000 08:09:57 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc ACKS,1.7,1.8
Message-ID: <200011071609.IAA01713@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc
In directory slayer.i.sourceforge.net:/tmp/cvs-serv1695/Doc

Modified Files:
ACKS
Log Message:

More names...


Index: ACKS
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/ACKS,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -r1.7 -r1.8
*** ACKS 2000/10/22 03:23:58 1.7
--- ACKS 2000/11/07 16:09:53 1.8
***************
*** 60,63 ****
--- 60,64 ----
Stefan Hoffmeister
Albert Hofkamp
+ Gregor Hoffleit
Gerrit Holl
Rob Hooft
***************
*** 103,106 ****
--- 104,108 ----
Sjoerd Mullender
Dale Nagata
+ Ng Pheng Siong
Koray Oner
Denis S. Otkidach



From python-dev@python.org Wed Nov 8 06:20:42 2000
From: python-dev@python.org (Fred L. Drake)
Date: Tue, 7 Nov 2000 22:20:42 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0205.txt,1.2,1.3
Message-ID: <200011080620.WAA20659@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv20652

Modified Files:
pep-0205.txt
Log Message:

Added some text describing the motivations for weak references, what is
available in Java, and pointers to previous work in Python.

There is a lot to be done before there can be a sample implementation;
issues related to implementation need to be discussed.


Index: pep-0205.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0205.txt,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** pep-0205.txt 2000/10/30 20:48:44 1.2
--- pep-0205.txt 2000/11/08 06:20:40 1.3
***************
*** 2,8 ****
Title: Weak References
Version: $Revision$
! Owner: fdrake@acm.org (Fred Drake)
Python-Version: 2.1
Status: Incomplete


--- 2,149 ----
Title: Weak References
Version: $Revision$
! Owner: Fred L. Drake, Jr. <fdrake@acm.org>
Python-Version: 2.1
Status: Incomplete
+ Type: Standards Track
+ Post-History:
+
+ Motivation
+
+ There are two basic applications for weak references which have
+ been noted by Python programmers: object caches and reduction of
+ pain from circular references.
+
+ Caches (weak dictionaries)
+
+ There is a need to allow objects to be maintained to represent
+ external state, mapping a single instance to the external
+ reality, where allowing multiple instances to be mapped to the
+ same external resource would create unnecessary difficulty
+ maintaining synchronization among instances. In these cases,
+ a common idiom is to support a cache of instances; a factory
+ function is used to return either a new or existing instance.
+
+ The difficulty in this approach is that one of two things must
+ be tolerated: either the cache grows without bound, or there
+ needs to be explicit management of the cache elsewhere in the
+ application. The later can be very tedious and leads to more
+ code than is really necessary to solve the problem at hand,
+ and the former can be unacceptable for long-running processes
+ or even relatively short processes with substantial memory
+ requirements.
+
+ - External objects that need to be represented by a single
+ instance, no matter how many internal users there are. This
+ can be useful for representing files that need to be written
+ back to disk in whole rather than locked & modified for
+ every use.
+
+ - Objects which are expensive to create, but may be needed by
+ multiple internal consumers. Similar to the first case, but
+ not necessarily bound to external resources, and possibly
+ not an issue for shared state. Weak references are only
+ useful in this case if there is some flavor of "soft"
+ references or if there is a high likelihood that users of
+ individual objects will overlap in lifespan.
+
+ Circular references
+
+ - DOMs require a huge amount of circular (to parent & document
+ nodes), but most of these aren't useful. Using weak
+ references allows applications to hold onto less of the tree
+ without a lot of difficulty. This might be especially
+ useful in the context of something like xml.dom.pulldom.
+
+
+ Weak References in Java
+
+ http://java.sun.com/j2se/1.3/docs/api/java/lang/ref/package-summary.html
+
+ Java provides three forms of weak references, and one interesting
+ helper class. The three forms are called "weak", "soft", and
+ "phantom" references. The relevant classes are defined in the
+ java.lang.ref package.
+
+ For each of the reference types, there is an option to add the
+ reference to a queue when it is invalidated by the memory
+ allocator. The primary purpose of this facility seems to be that
+ it allows larger structures to be composed to incorporate
+ weak-reference semantics without having to impose substantial
+ additional locking requirements. For instance, it would not be
+ difficult to use this facility to create a "weak" hash table which
+ removes keys and referents when a reference is no longer used
+ elsewhere. Using weak references for the objects without some
+ sort of notification queue for invalidations leads to much more
+ tedious implementation of the various operations required on hash
+ tables. This can be a performance bottleneck if deallocations of
+ the stored objects are infrequent.
+
+ Java's "weak" references are most like Diane Hackborn's old vref
+ proposal: a reference object refers to a single Python object,
+ but does not own a reference to that object. When that object is
+ deallocated, the reference object is invalidated. Users of the
+ reference object can easily determine that the reference has been
+ invalidated, or a NullObjectDereferenceError can be raised when
+ an attempt is made to use the referred-to object.
+
+ The "soft" references are similar, but are not invalidated as soon
+ as all other references to the referred-to object have been
+ released. The "soft" reference does own a reference, but allows
+ the memory allocator to free the referent if the memory is needed
+ elsewhere. It is not clear whether this means soft references are
+ released before the malloc() implementation calls sbrk() or its
+ equivalent, or if soft references are only cleared when malloc()
+ returns NULL.
+
+ XXX -- Need to figure out what phantom references are all about.
+
+ Unlike the other two reference types, "phantom" references must be
+ associated with an invalidation queue.
+
+
+ Previous Weak Reference Work in Python
+
+ Diane Hackborn's vref work. 'vref' objects were very similar to
+ java.lang.ref.WeakReference objects, except there was no
+ equivalent to the invalidation queues. Implementing a "weak
+ dictionary" would be just as difficult as using only weak
+ references (without the invalidation queue) in Java. Information
+ on this appears to have disappeared from the Web. Original
+ discussion occurred in the comp.lang.python newsgroup; a good
+ archive of that may turn up something more. Dianne's old Web
+ pages at Oregon State University have disappeared. I've sent an
+ email to what appears to be a recent email address for Dianne to
+ see if any information is still available.
+
+ Marc-André Lemburg's mx.Proxy package. These Web pages appear to
+ be unavailable at the moment.
+
+ http://starship.python.net/crew/lemburg/
+
+ The weakdict module by Dieter Maurer is implemented in C and
+ Python. It appears that the Web pages have not been updated since
+ Python 1.5.2a, so I'm not yet sure if the implementation is
+ compatible with Python 2.0.
+
+ http://www.handshake.de/~dieter/weakdict.html
+
+
+ Possible Applications
+
+ PyGTK+ bindings?
+
+ Tkinter?
+
+ DOM trees?
+
+
+ Proposed Implementation
+
+ XXX -- Not yet.
+
+
+ Copyright
+
+ This document has been placed in the public domain.





From python-dev@python.org Wed Nov 8 06:23:37 2000
From: python-dev@python.org (Fred L. Drake)
Date: Tue, 7 Nov 2000 22:23:37 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0000.txt,1.47,1.48
Message-ID: <200011080623.WAA20903@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv20894

Modified Files:
pep-0000.txt
Log Message:

Moved the "Weak References" PEP from empty to incomplete, even though
there is more than an abstract (not enough of the required parts are
in place still).


Index: pep-0000.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0000.txt,v
retrieving revision 1.47
retrieving revision 1.48
diff -C2 -r1.47 -r1.48
*** pep-0000.txt 2000/11/06 18:21:58 1.47
--- pep-0000.txt 2000/11/08 06:23:35 1.48
***************
*** 51,54 ****
--- 51,55 ----
Incomplete PEPs (only an abstract)

+ SD 205 pep-0205.txt Weak References Drake
SD 218 pep-0218.txt Adding a Built-In Set Object Type Wilson
SD 219 pep-0219.txt Stackless Python McMillan
***************
*** 57,61 ****
Empty PEPs (nothing written yet)

- SD 205 pep-0205.txt Weak References Drake
SD 209 pep-0209.txt Adding Multidimensional Arrays Ascher
SD 210 pep-0210.txt Decoupling the Interpreter Loop Ascher
--- 58,61 ----



From python-dev@python.org Wed Nov 8 06:47:08 2000
From: python-dev@python.org (Fred L. Drake)
Date: Tue, 7 Nov 2000 22:47:08 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0205.txt,1.3,1.4
Message-ID: <200011080647.WAA21933@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv21925

Modified Files:
pep-0205.txt
Log Message:

Slight update regarding Dianne Hackborn's vref() proposal from 1995;
there was never an implementation.


Index: pep-0205.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0205.txt,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** pep-0205.txt 2000/11/08 06:20:40 1.3
--- pep-0205.txt 2000/11/08 06:47:05 1.4
***************
*** 104,118 ****
Previous Weak Reference Work in Python

! Diane Hackborn's vref work. 'vref' objects were very similar to
! java.lang.ref.WeakReference objects, except there was no
equivalent to the invalidation queues. Implementing a "weak
dictionary" would be just as difficult as using only weak
references (without the invalidation queue) in Java. Information
! on this appears to have disappeared from the Web. Original
! discussion occurred in the comp.lang.python newsgroup; a good
! archive of that may turn up something more. Dianne's old Web
! pages at Oregon State University have disappeared. I've sent an
! email to what appears to be a recent email address for Dianne to
! see if any information is still available.

Marc-André Lemburg's mx.Proxy package. These Web pages appear to
--- 104,118 ----
Previous Weak Reference Work in Python

! Diane Hackborn's vref proposal. 'vref' objects were very similar
! to java.lang.ref.WeakReference objects, except there was no
equivalent to the invalidation queues. Implementing a "weak
dictionary" would be just as difficult as using only weak
references (without the invalidation queue) in Java. Information
! on this has disappeared from the Web. Original discussion
! occurred in the comp.lang.python newsgroup; a good archive of that
! may turn up something more.
!
! Dianne doesn't have any record of her proposal, and doesn't recall
! doing an implementation.

Marc-André Lemburg's mx.Proxy package. These Web pages appear to



From python-dev@python.org Wed Nov 8 15:17:51 2000
From: python-dev@python.org (Guido van Rossum)
Date: Wed, 8 Nov 2000 07:17:51 -0800
Subject: [Python-checkins] CVS: python/dist/src/Demo/threads Coroutine.py,NONE,1.1 fcmp.py,NONE,1.1 squasher.py,NONE,1.1 README,1.7,1.8
Message-ID: <200011081517.HAA16919@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Demo/threads
In directory slayer.i.sourceforge.net:/tmp/cvs-serv16912

Modified Files:
README
Added Files:
Coroutine.py fcmp.py squasher.py
Log Message:
Add 1994 Coroutine module by Tim Peters

--- NEW FILE ---
# Coroutine implementation using Python threads.
#
# Combines ideas from Guido's Generator module, and from the coroutine
# features of Icon and Simula 67.
#
# To run a collection of functions as coroutines, you need to create
# a Coroutine object to control them:
# co = Coroutine()
# and then 'create' a subsidiary object for each function in the
# collection:
# cof1 = co.create(f1 [, arg1, arg2, ...]) # [] means optional,
# cof2 = co.create(f2 [, arg1, arg2, ...]) #... not list
# cof3 = co.create(f3 [, arg1, arg2, ...])
# etc. The functions need not be distinct; 'create'ing the same
# function multiple times gives you independent instances of the
# function.
#
# To start the coroutines running, use co.tran on one of the create'd
# functions; e.g., co.tran(cof2). The routine that first executes
# co.tran is called the "main coroutine". It's special in several
# respects: it existed before you created the Coroutine object; if any of
# the create'd coroutines exits (does a return, or suffers an unhandled
# exception), EarlyExit error is raised in the main coroutine; and the
# co.detach() method transfers control directly to the main coroutine
# (you can't use co.tran() for this because the main coroutine doesn't
# have a name ...).
#
# Coroutine objects support these methods:
#
# handle = .create(func [, arg1, arg2, ...])
# Creates a coroutine for an invocation of func(arg1, arg2, ...),
# and returns a handle ("name") for the coroutine so created. The
# handle can be used as the target in a subsequent .tran().
#
# .tran(target, data=None)
# Transfer control to the create'd coroutine "target", optionally
# passing it an arbitrary piece of data. To the coroutine A that does
# the .tran, .tran acts like an ordinary function call: another
# coroutine B can .tran back to it later, and if it does A's .tran
# returns the 'data' argument passed to B's tran. E.g.,
#
# in coroutine coA in coroutine coC in coroutine coB
# x = co.tran(coC) co.tran(coB) co.tran(coA,12)
# print x # 12
#
# The data-passing feature is taken from Icon, and greatly cuts
# the need to use global variables for inter-coroutine communication.
#
# .back( data=None )
# The same as .tran(invoker, data=None), where 'invoker' is the
# coroutine that most recently .tran'ed control to the coroutine
# doing the .back. This is akin to Icon's "&source".
#
# .detach( data=None )
# The same as .tran(main, data=None), where 'main' is the
# (unnameable!) coroutine that started it all. 'main' has all the
# rights of any other coroutine: upon receiving control, it can
# .tran to an arbitrary coroutine of its choosing, go .back to
# the .detach'er, or .kill the whole thing.
#
# .kill()
# Destroy all the coroutines, and return control to the main
# coroutine. None of the create'ed coroutines can be resumed after a
# .kill(). An EarlyExit exception does a .kill() automatically. It's
# a good idea to .kill() coroutines you're done with, since the
# current implementation consumes a thread for each coroutine that
# may be resumed.

import thread
import sync

class _CoEvent:
def __init__(self, func):
self.f = func
self.e = sync.event()

def __repr__(self):
if self.f is None:
return 'main coroutine'
else:
return 'coroutine for func ' + self.f.func_name

def __hash__(self):
return id(self)

def __cmp__(x,y):
return cmp(id(x), id(y))

def resume(self):
self.e.post()

def wait(self):
self.e.wait()
self.e.clear()

Killed = 'Coroutine.Killed'
EarlyExit = 'Coroutine.EarlyExit'

class Coroutine:
def __init__(self):
self.active = self.main = _CoEvent(None)
self.invokedby = {self.main: None}
self.killed = 0
self.value = None
self.terminated_by = None

def create(self, func, *args):
me = _CoEvent(func)
self.invokedby[me] = None
thread.start_new_thread(self._start, (me,) + args)
return me

def _start(self, me, *args):
me.wait()
if not self.killed:
try:
try:
apply(me.f, args)
except Killed:
pass
finally:
if not self.killed:
self.terminated_by = me
self.kill()

def kill(self):
if self.killed:
raise TypeError, 'kill() called on dead coroutines'
self.killed = 1
for coroutine in self.invokedby.keys():
coroutine.resume()

def back(self, data=None):
return self.tran( self.invokedby[self.active], data )

def detach(self, data=None):
return self.tran( self.main, data )

def tran(self, target, data=None):
if not self.invokedby.has_key(target):
raise TypeError, '.tran target ' + `target` + \
' is not an active coroutine'
if self.killed:
raise TypeError, '.tran target ' + `target` + ' is killed'
self.value = data
me = self.active
self.invokedby[target] = me
self.active = target
target.resume()

me.wait()
if self.killed:
if self.main is not me:
raise Killed
if self.terminated_by is not None:
raise EarlyExit, `self.terminated_by` + ' terminated early'

return self.value

# end of module

--- NEW FILE ---
# Coroutine example: controlling multiple instances of a single function

from Coroutine import *

# fringe visits a nested list in inorder, and detaches for each non-list
# element; raises EarlyExit after the list is exhausted
def fringe( co, list ):
for x in list:
if type(x) is type([]):
fringe(co, x)
else:
co.detach(x)

def printinorder( list ):
co = Coroutine()
f = co.create(fringe, co, list)
try:
while 1:
print co.tran(f),
except EarlyExit:
pass
print

printinorder([1,2,3]) # 1 2 3
printinorder([[[[1,[2]]],3]]) # ditto
x = [0, 1, [2, [3]], [4,5], [[[6]]] ]
printinorder(x) # 0 1 2 3 4 5 6

# fcmp lexicographically compares the fringes of two nested lists
def fcmp( l1, l2 ):
co1 = Coroutine(); f1 = co1.create(fringe, co1, l1)
co2 = Coroutine(); f2 = co2.create(fringe, co2, l2)
while 1:
try:
v1 = co1.tran(f1)
except EarlyExit:
try:
v2 = co2.tran(f2)
except EarlyExit:
return 0
co2.kill()
return -1
try:
v2 = co2.tran(f2)
except EarlyExit:
co1.kill()
return 1
if v1 != v2:
co1.kill(); co2.kill()
return cmp(v1,v2)

print fcmp(range(7), x) # 0; fringes are equal
print fcmp(range(6), x) # -1; 1st list ends early
print fcmp(x, range(6)) # 1; 2nd list ends early
print fcmp(range(8), x) # 1; 2nd list ends early
print fcmp(x, range(8)) # -1; 1st list ends early
print fcmp([1,[[2],8]],
[[[1],2],8]) # 0
print fcmp([1,[[3],8]],
[[[1],2],8]) # 1
print fcmp([1,[[2],8]],
[[[1],2],9]) # -1

# end of example

--- NEW FILE ---
# Coroutine example: general coroutine transfers
#
# The program is a variation of a Simula 67 program due to Dahl & Hoare,
# who in turn credit the original example to Conway.
#
# We have a number of input lines, terminated by a 0 byte. The problem
# is to squash them together into output lines containing 72 characters
# each. A semicolon must be added between input lines. Runs of blanks
# and tabs in input lines must be squashed into single blanks.
# Occurrences of "**" in input lines must be replaced by "^".
#
# Here's a test case:

test = """\
d = sqrt(b**2 - 4*a*c)
twoa = 2*a
L = -b/twoa
R = d/twoa
A1 = L + R
A2 = L - R\0
"""

# The program should print:

# d = sqrt(b^2 - 4*a*c);twoa = 2*a; L = -b/twoa; R = d/twoa; A1 = L + R;
#A2 = L - R
#done

# getline: delivers the next input line to its invoker
# disassembler: grabs input lines from getline, and delivers them one
# character at a time to squasher, also inserting a semicolon into
# the stream between lines
# squasher: grabs characters from disassembler and passes them on to
# assembler, first replacing "**" with "^" and squashing runs of
# whitespace
# assembler: grabs characters from squasher and packs them into lines
# with 72 character each, delivering each such line to putline;
# when it sees a null byte, passes the last line to putline and
# then kills all the coroutines
# putline: grabs lines from assembler, and just prints them

from Coroutine import *

def getline(text):
for line in string.splitfields(text, '\n'):
co.back(line)

def disassembler():
while 1:
card = co.tran(cogetline)
for i in range(len(card)):
co.tran(cosquasher, card[i])
co.tran(cosquasher, ';')

def squasher():
while 1:
ch = co.tran(codisassembler)
if ch == '*':
ch2 = co.tran(codisassembler)
if ch2 == '*':
ch = '^'
else:
co.tran(coassembler, ch)
ch = ch2
if ch in ' \t':
while 1:
ch2 = co.tran(codisassembler)
if ch2 not in ' \t':
break
co.tran(coassembler, ' ')
ch = ch2
co.tran(coassembler, ch)

def assembler():
line = ''
while 1:
ch = co.tran(cosquasher)
if ch == '\0':
break
if len(line) == 72:
co.tran(coputline, line)
line = ''
line = line + ch
line = line + ' ' * (72 - len(line))
co.tran(coputline, line)
co.kill()

def putline():
while 1:
line = co.tran(coassembler)
print line

import string
co = Coroutine()
cogetline = co.create(getline, test)
coputline = co.create(putline)
coassembler = co.create(assembler)
codisassembler = co.create(disassembler)
cosquasher = co.create(squasher)

co.tran(coputline)
print 'done'

# end of example

Index: README
==================================================================RCS file: /cvsroot/python/python/dist/src/Demo/threads/README,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -r1.7 -r1.8
*** README 1998/02/14 03:11:36 1.7
--- README 2000/11/08 15:17:49 1.8
***************
*** 9,10 ****
--- 9,14 ----
telnet.py Version of ../sockets/telnet.py using threads.
wpi.py Version of ../scripts/pi.py using threads (needs stdwin).
+
+ Coroutine.py Coroutines using threads, by Tim Peters (22 May 94)
+ fcmp.py Example of above, by Tim
+ squasher.py Another example of above, also by Tim



From python-dev@python.org Wed Nov 8 18:37:07 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 8 Nov 2000 10:37:07 -0800
Subject: [Python-checkins] CVS: python/dist/src/Objects rangeobject.c,2.20,2.21
Message-ID: <200011081837.KAA03207@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Objects
In directory slayer.i.sourceforge.net:/tmp/cvs-serv3195/Objects

Modified Files:
rangeobject.c
Log Message:

In the containment test, get the boundary condition right. ">" was used
where ">=" should have been.

This closes bug #121965.


Index: rangeobject.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Objects/rangeobject.c,v
retrieving revision 2.20
retrieving revision 2.21
diff -C2 -r2.20 -r2.21
*** rangeobject.c 2000/09/01 23:29:27 2.20
--- rangeobject.c 2000/11/08 18:37:05 2.21
***************
*** 194,200 ****
return -1;

! if (num < r->start || (num - r->start) % r->step)
return 0;
! if (num > (r->start + (r->len * r->step)))
return 0;
return 1;
--- 194,200 ----
return -1;

! if ((num < r->start) || ((num - r->start) % r->step))
return 0;
! if (num >= (r->start + (r->len * r->step)))
return 0;
return 1;



From python-dev@python.org Wed Nov 8 19:42:46 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 8 Nov 2000 11:42:46 -0800
Subject: [Python-checkins] CVS: python/dist/src/Objects rangeobject.c,2.21,2.22
Message-ID: <200011081942.LAA08968@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Objects
In directory slayer.i.sourceforge.net:/tmp/cvs-serv8961/Objects

Modified Files:
rangeobject.c
Log Message:

Fixed support for containment test when a negative step is used; this
*really* closes bug #121965.

Added three attributes to the xrange object: start, stop, and step. These
are the same as for the slice objects.


Index: rangeobject.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Objects/rangeobject.c,v
retrieving revision 2.21
retrieving revision 2.22
diff -C2 -r2.21 -r2.22
*** rangeobject.c 2000/11/08 18:37:05 2.21
--- rangeobject.c 2000/11/08 19:42:43 2.22
***************
*** 3,6 ****
--- 3,8 ----

#include "Python.h"
+ #include "structmember.h"
+ #include <string.h>

typedef struct {
***************
*** 176,179 ****
--- 178,183 ----
range_getattr(rangeobject *r, char *name)
{
+ PyObject *result;
+
static PyMethodDef range_methods[] = {
{"tolist", (PyCFunction)range_tolist, METH_VARARGS,
***************
*** 182,187 ****
{NULL, NULL}
};

! return Py_FindMethod(range_methods, (PyObject *) r, name);
}

--- 186,205 ----
{NULL, NULL}
};
+ static struct memberlist range_members[] = {
+ {"step", T_LONG, offsetof(rangeobject, step), RO},
+ {"start", T_LONG, offsetof(rangeobject, start), RO},
+ {"stop", T_LONG, 0, RO},
+ {NULL, 0, 0, 0}
+ };

! result = Py_FindMethod(range_methods, (PyObject *) r, name);
! if (result == NULL) {
! PyErr_Clear();
! if (strcmp("stop", name) == 0)
! result = PyInt_FromLong(r->start + (r->len * r->step));
! else
! result = PyMember_Get((char *)r, range_members, name);
! }
! return result;
}

***************
*** 194,212 ****
return -1;

! if ((num < r->start) || ((num - r->start) % r->step))
! return 0;
! if (num >= (r->start + (r->len * r->step)))
! return 0;
return 1;
}

static PySequenceMethods range_as_sequence = {
! (inquiry)range_length, /*sq_length*/
(binaryfunc)range_concat, /*sq_concat*/
(intargfunc)range_repeat, /*sq_repeat*/
(intargfunc)range_item, /*sq_item*/
(intintargfunc)range_slice, /*sq_slice*/
! 0, /*sq_ass_item*/
! 0, /*sq_ass_slice*/
(objobjproc)range_contains, /*sq_contains*/
};
--- 212,238 ----
return -1;

! if (r->step > 0) {
! if ((num < r->start) || ((num - r->start) % r->step))
! return 0;
! if (num >= (r->start + (r->len * r->step)))
! return 0;
! }
! else {
! if ((num > r->start) || ((num - r->start) % r->step))
! return 0;
! if (num <= (r->start + (r->len * r->step)))
! return 0;
! }
return 1;
}

static PySequenceMethods range_as_sequence = {
! (inquiry)range_length, /*sq_length*/
(binaryfunc)range_concat, /*sq_concat*/
(intargfunc)range_repeat, /*sq_repeat*/
(intargfunc)range_item, /*sq_item*/
(intintargfunc)range_slice, /*sq_slice*/
! 0, /*sq_ass_item*/
! 0, /*sq_ass_slice*/
(objobjproc)range_contains, /*sq_contains*/
};



From python-dev@python.org Wed Nov 8 19:51:28 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 8 Nov 2000 11:51:28 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib/test test_b2.py,1.19,1.20
Message-ID: <200011081951.LAA09686@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib/test
In directory slayer.i.sourceforge.net:/tmp/cvs-serv9678/Lib/test

Modified Files:
test_b2.py
Log Message:

Added test cases to detect regression on SourceForge bug #121965.


Index: test_b2.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/test/test_b2.py,v
retrieving revision 1.19
retrieving revision 1.20
diff -C2 -r1.19 -r1.20
*** test_b2.py 2000/10/23 17:22:07 1.19
--- test_b2.py 2000/11/08 19:51:25 1.20
***************
*** 255,258 ****
--- 255,272 ----
if tuple(xrange(0,10,2)) <> tuple(range(0,10,2)):
raise TestFailed, 'xrange(0,10,2)'
+ # regression tests for SourceForge bug #121695
+ def _range_test(r):
+ assert r.start != r.stop, 'Test not valid for passed-in xrange object.'
+ if r.stop in r:
+ raise TestFailed, 'r.stop in ' + `r`
+ if r.stop-r.step not in r:
+ raise TestFailed, 'r.stop-r.step not in ' + `r`
+ if r.start not in r:
+ raise TestFailed, 'r.start not in ' + `r`
+ if r.stop+r.step in r:
+ raise TestFailed, 'r.stop+r.step in ' + `r`
+ _range_test(xrange(10))
+ _range_test(xrange(9, -1, -1))
+ _range_test(xrange(0, 10, 2))

print 'zip'



From python-dev@python.org Wed Nov 8 20:23:02 2000
From: python-dev@python.org (Fred L. Drake)
Date: Wed, 8 Nov 2000 12:23:02 -0800
Subject: [Python-checkins] CVS: python/dist/src configure.in,1.178,1.179 config.h.in,2.78,2.79
Message-ID: <200011082023.MAA12997@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src
In directory slayer.i.sourceforge.net:/tmp/cvs-serv12982

Modified Files:
configure.in config.h.in
Log Message:

Remove AC_C_INLINE test from configure.in, since the only place the symbol
occurs in the Python sources appears to be as text in comments. We do not
want to interfere with C++ keywords!

This closes bug #119851.


Index: configure.in
==================================================================RCS file: /cvsroot/python/python/dist/src/configure.in,v
retrieving revision 1.178
retrieving revision 1.179
diff -C2 -r1.178 -r1.179
*** configure.in 2000/11/07 15:44:21 1.178
--- configure.in 2000/11/08 20:22:59 1.179
***************
*** 1008,1012 ****
AC_C_CHAR_UNSIGNED
AC_C_CONST
- AC_C_INLINE

works=no
--- 1008,1011 ----

Index: config.h.in
==================================================================RCS file: /cvsroot/python/python/dist/src/config.h.in,v
retrieving revision 2.78
retrieving revision 2.79
diff -C2 -r2.78 -r2.79
*** config.h.in 2000/10/09 21:48:02 2.78
--- config.h.in 2000/11/08 20:22:59 2.79
***************
*** 26,32 ****
#undef HAVE_TZNAME

- /* Define as __inline if that's what the C compiler calls it. */
- #undef inline
-
/* Define if on MINIX. */
#undef _MINIX
--- 26,29 ----



From python-dev@python.org Wed Nov 8 22:19:54 2000
From: python-dev@python.org (Barry Warsaw)
Date: Wed, 8 Nov 2000 14:19:54 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib smtplib.py,1.29,1.30
Message-ID: <200011082219.OAA01283@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv1265

Modified Files:
smtplib.py
Log Message:
SMTP.connect(): If the socket.connect() raises a socket.error, be sure
to call self.close() to reclaim some file descriptors, the reraise the
exception. Closes SF patch #102185 and SF bug #119833.


Index: smtplib.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/smtplib.py,v
retrieving revision 1.29
retrieving revision 1.30
diff -C2 -r1.29 -r1.30
*** smtplib.py 2000/09/01 06:40:07 1.29
--- smtplib.py 2000/11/08 22:19:47 1.30
***************
*** 215,219 ****
self.sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
if self.debuglevel > 0: print 'connect:', (host, port)
! self.sock.connect((host, port))
(code,msg)=self.getreply()
if self.debuglevel >0 : print "connect:", msg
--- 215,223 ----
self.sock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
if self.debuglevel > 0: print 'connect:', (host, port)
! try:
! self.sock.connect((host, port))
! except socket.error:
! self.close()
! raise
(code,msg)=self.getreply()
if self.debuglevel >0 : print "connect:", msg



From python-dev@python.org Thu Nov 9 18:05:26 2000
From: python-dev@python.org (Guido van Rossum)
Date: Thu, 9 Nov 2000 10:05:26 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib rfc822.py,1.49,1.50
Message-ID: <200011091805.KAA26538@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv26530

Modified Files:
rfc822.py
Log Message:
Implement the suggestion of bug_id2070: surround tell() call with
try/except.


Index: rfc822.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/rfc822.py,v
retrieving revision 1.49
retrieving revision 1.50
diff -C2 -r1.49 -r1.50
*** rfc822.py 2000/09/25 15:08:27 1.49
--- rfc822.py 2000/11/09 18:05:24 1.50
***************
*** 133,137 ****
while 1:
if tell:
! startofline = tell()
line = self.fp.readline()
if not line:
--- 133,141 ----
while 1:
if tell:
! try:
! startofline = tell()
! except IOError:
! startofline = tell = None
! self.seekable = 0
line = self.fp.readline()
if not line:



From python-dev@python.org Thu Nov 9 21:14:43 2000
From: python-dev@python.org (Guido van Rossum)
Date: Thu, 9 Nov 2000 13:14:43 -0800
Subject: [Python-checkins] CVS: python/dist/src configure,1.170,1.171
Message-ID: <200011092114.NAA11286@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src
In directory slayer.i.sourceforge.net:/tmp/cvs-serv11273

Modified Files:
configure
Log Message:
Committing autoconf output for
Fred.

Index: configure
==================================================================RCS file: /cvsroot/python/python/dist/src/configure,v
retrieving revision 1.170
retrieving revision 1.171
diff -C2 -r1.170 -r1.171
*** configure 2000/11/07 15:44:21 1.170
--- configure 2000/11/09 21:14:40 1.171
***************
*** 1,5 ****
#! /bin/sh

! # From configure.in Revision: 1.178

# Guess values for system-dependent variables and create Makefiles.
--- 1,5 ----
#! /bin/sh

! # From configure.in Revision: 1.179

# Guess values for system-dependent variables and create Makefiles.
***************
*** 4903,4952 ****
fi

- echo $ac_n "checking for inline""... $ac_c" 1>&6
- echo "configure:4907: checking for inline" >&5
- if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
- echo $ac_n "(cached) $ac_c" 1>&6
- else
- ac_cv_c_inline=no
- for ac_kw in inline __inline__ __inline; do
- cat > conftest.$ac_ext <<EOF
- #line 4914 "configure"
- #include "confdefs.h"
-
- int main() {
- } $ac_kw foo() {
- ; return 0; }
- EOF
- if { (eval echo configure:4921: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
- rm -rf conftest*
- ac_cv_c_inline=$ac_kw; break
- else
- echo "configure: failed program was:" >&5
- cat conftest.$ac_ext >&5
- fi
- rm -f conftest*
- done
-
- fi
-
- echo "$ac_t""$ac_cv_c_inline" 1>&6
- case "$ac_cv_c_inline" in
- inline | yes) ;;
- no) cat >> confdefs.h <<\EOF
- #define inline
- EOF
- ;;
- *) cat >> confdefs.h <<EOF
- #define inline $ac_cv_c_inline
- EOF
- ;;
- esac

-
works=no
echo $ac_n "checking for working volatile""... $ac_c" 1>&6
! echo "configure:4949: checking for working volatile" >&5
cat > conftest.$ac_ext <<EOF
! #line 4951 "configure"
#include "confdefs.h"

--- 4903,4912 ----
fi


works=no
echo $ac_n "checking for working volatile""... $ac_c" 1>&6
! echo "configure:4909: checking for working volatile" >&5
cat > conftest.$ac_ext <<EOF
! #line 4911 "configure"
#include "confdefs.h"

***************
*** 4955,4959 ****
; return 0; }
EOF
! if { (eval echo configure:4958: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
works=yes
--- 4915,4919 ----
; return 0; }
EOF
! if { (eval echo configure:4918: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
works=yes
***************
*** 4972,4978 ****
works=no
echo $ac_n "checking for working signed char""... $ac_c" 1>&6
! echo "configure:4975: checking for working signed char" >&5
cat > conftest.$ac_ext <<EOF
! #line 4977 "configure"
#include "confdefs.h"

--- 4932,4938 ----
works=no
echo $ac_n "checking for working signed char""... $ac_c" 1>&6
! echo "configure:4935: checking for working signed char" >&5
cat > conftest.$ac_ext <<EOF
! #line 4937 "configure"
#include "confdefs.h"

***************
*** 4981,4985 ****
; return 0; }
EOF
! if { (eval echo configure:4984: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
works=yes
--- 4941,4945 ----
; return 0; }
EOF
! if { (eval echo configure:4944: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
works=yes
***************
*** 4998,5004 ****
have_prototypes=no
echo $ac_n "checking for prototypes""... $ac_c" 1>&6
! echo "configure:5001: checking for prototypes" >&5
cat > conftest.$ac_ext <<EOF
! #line 5003 "configure"
#include "confdefs.h"
int foo(int x) { return 0; }
--- 4958,4964 ----
have_prototypes=no
echo $ac_n "checking for prototypes""... $ac_c" 1>&6
! echo "configure:4961: checking for prototypes" >&5
cat > conftest.$ac_ext <<EOF
! #line 4963 "configure"
#include "confdefs.h"
int foo(int x) { return 0; }
***************
*** 5007,5011 ****
; return 0; }
EOF
! if { (eval echo configure:5010: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
cat >> confdefs.h <<\EOF
--- 4967,4971 ----
; return 0; }
EOF
! if { (eval echo configure:4970: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
cat >> confdefs.h <<\EOF
***************
*** 5022,5028 ****
works=no
echo $ac_n "checking for variable length prototypes and stdarg.h""... $ac_c" 1>&6
! echo "configure:5025: checking for variable length prototypes and stdarg.h" >&5
cat > conftest.$ac_ext <<EOF
! #line 5027 "configure"
#include "confdefs.h"

--- 4982,4988 ----
works=no
echo $ac_n "checking for variable length prototypes and stdarg.h""... $ac_c" 1>&6
! echo "configure:4985: checking for variable length prototypes and stdarg.h" >&5
cat > conftest.$ac_ext <<EOF
! #line 4987 "configure"
#include "confdefs.h"

***************
*** 5041,5045 ****
; return 0; }
EOF
! if { (eval echo configure:5044: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
cat >> confdefs.h <<\EOF
--- 5001,5005 ----
; return 0; }
EOF
! if { (eval echo configure:5004: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
cat >> confdefs.h <<\EOF
***************
*** 5057,5063 ****
bad_prototypes=no
echo $ac_n "checking for bad exec* prototypes""... $ac_c" 1>&6
! echo "configure:5060: checking for bad exec* prototypes" >&5
cat > conftest.$ac_ext <<EOF
! #line 5062 "configure"
#include "confdefs.h"
#include <unistd.h>
--- 5017,5023 ----
bad_prototypes=no
echo $ac_n "checking for bad exec* prototypes""... $ac_c" 1>&6
! echo "configure:5020: checking for bad exec* prototypes" >&5
cat > conftest.$ac_ext <<EOF
! #line 5022 "configure"
#include "confdefs.h"
#include <unistd.h>
***************
*** 5066,5070 ****
; return 0; }
EOF
! if { (eval echo configure:5069: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
:
else
--- 5026,5030 ----
; return 0; }
EOF
! if { (eval echo configure:5029: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
:
else
***************
*** 5083,5092 ****
bad_forward=no
echo $ac_n "checking for bad static forward""... $ac_c" 1>&6
! echo "configure:5086: checking for bad static forward" >&5
if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
! #line 5091 "configure"
#include "confdefs.h"

--- 5043,5052 ----
bad_forward=no
echo $ac_n "checking for bad static forward""... $ac_c" 1>&6
! echo "configure:5046: checking for bad static forward" >&5
if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
! #line 5051 "configure"
#include "confdefs.h"

***************
*** 5104,5108 ****

EOF
! if { (eval echo configure:5107: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
:
--- 5064,5068 ----

EOF
! if { (eval echo configure:5067: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
:
***************
*** 5123,5129 ****
va_list_is_array=no
echo $ac_n "checking whether va_list is an array""... $ac_c" 1>&6
! echo "configure:5126: checking whether va_list is an array" >&5
cat > conftest.$ac_ext <<EOF
! #line 5128 "configure"
#include "confdefs.h"

--- 5083,5089 ----
va_list_is_array=no
echo $ac_n "checking whether va_list is an array""... $ac_c" 1>&6
! echo "configure:5086: checking whether va_list is an array" >&5
cat > conftest.$ac_ext <<EOF
! #line 5088 "configure"
#include "confdefs.h"

***************
*** 5138,5142 ****
; return 0; }
EOF
! if { (eval echo configure:5141: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
:
else
--- 5098,5102 ----
; return 0; }
EOF
! if { (eval echo configure:5101: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
:
else
***************
*** 5154,5163 ****
# sigh -- gethostbyname_r is a mess; it can have 3, 5 or 6 arguments :-(
echo $ac_n "checking for gethostbyname_r""... $ac_c" 1>&6
! echo "configure:5157: checking for gethostbyname_r" >&5
if eval "test \"`echo '$''{'ac_cv_func_gethostbyname_r'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5162 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
--- 5114,5123 ----
# sigh -- gethostbyname_r is a mess; it can have 3, 5 or 6 arguments :-(
echo $ac_n "checking for gethostbyname_r""... $ac_c" 1>&6
! echo "configure:5117: checking for gethostbyname_r" >&5
if eval "test \"`echo '$''{'ac_cv_func_gethostbyname_r'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5122 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
***************
*** 5182,5186 ****
; return 0; }
EOF
! if { (eval echo configure:5185: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_gethostbyname_r=yes"
--- 5142,5146 ----
; return 0; }
EOF
! if { (eval echo configure:5145: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_gethostbyname_r=yes"
***************
*** 5202,5210 ****

echo $ac_n "checking gethostbyname_r with 6 args""... $ac_c" 1>&6
! echo "configure:5205: checking gethostbyname_r with 6 args" >&5
OLD_CFLAGS=$CFLAGS
CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS"
cat > conftest.$ac_ext <<EOF
! #line 5209 "configure"
#include "confdefs.h"

--- 5162,5170 ----

echo $ac_n "checking gethostbyname_r with 6 args""... $ac_c" 1>&6
! echo "configure:5165: checking gethostbyname_r with 6 args" >&5
OLD_CFLAGS=$CFLAGS
CFLAGS="$CFLAGS $MY_CPPFLAGS $MY_THREAD_CPPFLAGS $MY_CFLAGS"
cat > conftest.$ac_ext <<EOF
! #line 5169 "configure"
#include "confdefs.h"

***************
*** 5223,5227 ****
; return 0; }
EOF
! if { (eval echo configure:5226: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*

--- 5183,5187 ----
; return 0; }
EOF
! if { (eval echo configure:5186: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*

***************
*** 5243,5249 ****
echo "$ac_t""no" 1>&6
echo $ac_n "checking gethostbyname_r with 5 args""... $ac_c" 1>&6
! echo "configure:5246: checking gethostbyname_r with 5 args" >&5
cat > conftest.$ac_ext <<EOF
! #line 5248 "configure"
#include "confdefs.h"

--- 5203,5209 ----
echo "$ac_t""no" 1>&6
echo $ac_n "checking gethostbyname_r with 5 args""... $ac_c" 1>&6
! echo "configure:5206: checking gethostbyname_r with 5 args" >&5
cat > conftest.$ac_ext <<EOF
! #line 5208 "configure"
#include "confdefs.h"

***************
*** 5262,5266 ****
; return 0; }
EOF
! if { (eval echo configure:5265: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*

--- 5222,5226 ----
; return 0; }
EOF
! if { (eval echo configure:5225: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*

***************
*** 5282,5288 ****
echo "$ac_t""no" 1>&6
echo $ac_n "checking gethostbyname_r with 3 args""... $ac_c" 1>&6
! echo "configure:5285: checking gethostbyname_r with 3 args" >&5
cat > conftest.$ac_ext <<EOF
! #line 5287 "configure"
#include "confdefs.h"

--- 5242,5248 ----
echo "$ac_t""no" 1>&6
echo $ac_n "checking gethostbyname_r with 3 args""... $ac_c" 1>&6
! echo "configure:5245: checking gethostbyname_r with 3 args" >&5
cat > conftest.$ac_ext <<EOF
! #line 5247 "configure"
#include "confdefs.h"

***************
*** 5299,5303 ****
; return 0; }
EOF
! if { (eval echo configure:5302: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*

--- 5259,5263 ----
; return 0; }
EOF
! if { (eval echo configure:5262: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*

***************
*** 5335,5344 ****
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
! echo "configure:5338: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5343 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
--- 5295,5304 ----
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
! echo "configure:5298: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5303 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
***************
*** 5363,5367 ****
; return 0; }
EOF
! if { (eval echo configure:5366: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
--- 5323,5327 ----
; return 0; }
EOF
! if { (eval echo configure:5326: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
***************
*** 5401,5410 ****
# Linux requires this for correct f.p. operations
echo $ac_n "checking for __fpu_control""... $ac_c" 1>&6
! echo "configure:5404: checking for __fpu_control" >&5
if eval "test \"`echo '$''{'ac_cv_func___fpu_control'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5409 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
--- 5361,5370 ----
# Linux requires this for correct f.p. operations
echo $ac_n "checking for __fpu_control""... $ac_c" 1>&6
! echo "configure:5364: checking for __fpu_control" >&5
if eval "test \"`echo '$''{'ac_cv_func___fpu_control'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5369 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
***************
*** 5429,5433 ****
; return 0; }
EOF
! if { (eval echo configure:5432: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func___fpu_control=yes"
--- 5389,5393 ----
; return 0; }
EOF
! if { (eval echo configure:5392: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func___fpu_control=yes"
***************
*** 5447,5451 ****
echo "$ac_t""no" 1>&6
echo $ac_n "checking for __fpu_control in -lieee""... $ac_c" 1>&6
! echo "configure:5450: checking for __fpu_control in -lieee" >&5
ac_lib_var=`echo ieee'_'__fpu_control | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
--- 5407,5411 ----
echo "$ac_t""no" 1>&6
echo $ac_n "checking for __fpu_control in -lieee""... $ac_c" 1>&6
! echo "configure:5410: checking for __fpu_control in -lieee" >&5
ac_lib_var=`echo ieee'_'__fpu_control | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
***************
*** 5455,5459 ****
LIBS="-lieee $LIBS"
cat > conftest.$ac_ext <<EOF
! #line 5458 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
--- 5415,5419 ----
LIBS="-lieee $LIBS"
cat > conftest.$ac_ext <<EOF
! #line 5418 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
***************
*** 5466,5470 ****
; return 0; }
EOF
! if { (eval echo configure:5469: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
--- 5426,5430 ----
; return 0; }
EOF
! if { (eval echo configure:5429: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
***************
*** 5499,5503 ****
# Check for --with-fpectl
echo $ac_n "checking for --with-fpectl""... $ac_c" 1>&6
! echo "configure:5502: checking for --with-fpectl" >&5
# Check whether --with-fpectl or --without-fpectl was given.
if test "${with_fpectl+set}" = set; then
--- 5459,5463 ----
# Check for --with-fpectl
echo $ac_n "checking for --with-fpectl""... $ac_c" 1>&6
! echo "configure:5462: checking for --with-fpectl" >&5
# Check whether --with-fpectl or --without-fpectl was given.
if test "${with_fpectl+set}" = set; then
***************
*** 5525,5529 ****
esac
echo $ac_n "checking for --with-libm=STRING""... $ac_c" 1>&6
! echo "configure:5528: checking for --with-libm=STRING" >&5
# Check whether --with-libm or --without-libm was given.
if test "${with_libm+set}" = set; then
--- 5485,5489 ----
esac
echo $ac_n "checking for --with-libm=STRING""... $ac_c" 1>&6
! echo "configure:5488: checking for --with-libm=STRING" >&5
# Check whether --with-libm or --without-libm was given.
if test "${with_libm+set}" = set; then
***************
*** 5546,5550 ****

echo $ac_n "checking for --with-libc=STRING""... $ac_c" 1>&6
! echo "configure:5549: checking for --with-libc=STRING" >&5
# Check whether --with-libc or --without-libc was given.
if test "${with_libc+set}" = set; then
--- 5506,5510 ----

echo $ac_n "checking for --with-libc=STRING""... $ac_c" 1>&6
! echo "configure:5509: checking for --with-libc=STRING" >&5
# Check whether --with-libc or --without-libc was given.
if test "${with_libc+set}" = set; then
***************
*** 5570,5579 ****
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
! echo "configure:5573: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5578 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
--- 5530,5539 ----
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
! echo "configure:5533: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5538 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
***************
*** 5598,5602 ****
; return 0; }
EOF
! if { (eval echo configure:5601: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
--- 5558,5562 ----
; return 0; }
EOF
! if { (eval echo configure:5561: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
***************
*** 5628,5632 ****
# check whether malloc(0) returns NULL or not
echo $ac_n "checking what malloc(0) returns""... $ac_c" 1>&6
! echo "configure:5631: checking what malloc(0) returns" >&5
if eval "test \"`echo '$''{'ac_cv_malloc_zero'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
--- 5588,5592 ----
# check whether malloc(0) returns NULL or not
echo $ac_n "checking what malloc(0) returns""... $ac_c" 1>&6
! echo "configure:5591: checking what malloc(0) returns" >&5
if eval "test \"`echo '$''{'ac_cv_malloc_zero'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
***************
*** 5636,5640 ****
else
cat > conftest.$ac_ext <<EOF
! #line 5639 "configure"
#include "confdefs.h"
#include <stdio.h>
--- 5596,5600 ----
else
cat > conftest.$ac_ext <<EOF
! #line 5599 "configure"
#include "confdefs.h"
#include <stdio.h>
***************
*** 5655,5659 ****
}
EOF
! if { (eval echo configure:5658: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_malloc_zero=nonnull
--- 5615,5619 ----
}
EOF
! if { (eval echo configure:5618: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_malloc_zero=nonnull
***************
*** 5681,5695 ****
ac_safe=`echo "wchar.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for wchar.h""... $ac_c" 1>&6
! echo "configure:5684: checking for wchar.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5689 "configure"
#include "confdefs.h"
#include <wchar.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
! { (eval echo configure:5694: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
--- 5641,5655 ----
ac_safe=`echo "wchar.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for wchar.h""... $ac_c" 1>&6
! echo "configure:5644: checking for wchar.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5649 "configure"
#include "confdefs.h"
#include <wchar.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
! { (eval echo configure:5654: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
***************
*** 5721,5730 ****
usable_wchar_t="unkown"
echo $ac_n "checking for usable wchar_t""... $ac_c" 1>&6
! echo "configure:5724: checking for usable wchar_t" >&5
if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
! #line 5729 "configure"
#include "confdefs.h"

--- 5681,5690 ----
usable_wchar_t="unkown"
echo $ac_n "checking for usable wchar_t""... $ac_c" 1>&6
! echo "configure:5684: checking for usable wchar_t" >&5
if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
! #line 5689 "configure"
#include "confdefs.h"

***************
*** 5740,5744 ****

EOF
! if { (eval echo configure:5743: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
cat >> confdefs.h <<\EOF
--- 5700,5704 ----

EOF
! if { (eval echo configure:5703: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
cat >> confdefs.h <<\EOF
***************
*** 5759,5763 ****
# check for endianness
echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
! echo "configure:5762: checking whether byte ordering is bigendian" >&5
if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
--- 5719,5723 ----
# check for endianness
echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
! echo "configure:5722: checking whether byte ordering is bigendian" >&5
if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
***************
*** 5766,5770 ****
# See if sys/param.h defines the BYTE_ORDER macro.
cat > conftest.$ac_ext <<EOF
! #line 5769 "configure"
#include "confdefs.h"
#include <sys/types.h>
--- 5726,5730 ----
# See if sys/param.h defines the BYTE_ORDER macro.
cat > conftest.$ac_ext <<EOF
! #line 5729 "configure"
#include "confdefs.h"
#include <sys/types.h>
***************
*** 5777,5785 ****
; return 0; }
EOF
! if { (eval echo configure:5780: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
# It does; now see whether it defined to BIG_ENDIAN or not.
cat > conftest.$ac_ext <<EOF
! #line 5784 "configure"
#include "confdefs.h"
#include <sys/types.h>
--- 5737,5745 ----
; return 0; }
EOF
! if { (eval echo configure:5740: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
# It does; now see whether it defined to BIG_ENDIAN or not.
cat > conftest.$ac_ext <<EOF
! #line 5744 "configure"
#include "confdefs.h"
#include <sys/types.h>
***************
*** 5792,5796 ****
; return 0; }
EOF
! if { (eval echo configure:5795: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_bigendian=yes
--- 5752,5756 ----
; return 0; }
EOF
! if { (eval echo configure:5755: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_bigendian=yes
***************
*** 5812,5816 ****
else
cat > conftest.$ac_ext <<EOF
! #line 5815 "configure"
#include "confdefs.h"
main () {
--- 5772,5776 ----
else
cat > conftest.$ac_ext <<EOF
! #line 5775 "configure"
#include "confdefs.h"
main () {
***************
*** 5825,5829 ****
}
EOF
! if { (eval echo configure:5828: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_bigendian=no
--- 5785,5789 ----
}
EOF
! if { (eval echo configure:5788: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_bigendian=no
***************
*** 5852,5856 ****
# or fills with zeros (like the Cray J90, according to Tim Peters).
echo $ac_n "checking whether right shift extends the sign bit""... $ac_c" 1>&6
! echo "configure:5855: checking whether right shift extends the sign bit" >&5
if eval "test \"`echo '$''{'ac_cv_rshift_extends_sign'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
--- 5812,5816 ----
# or fills with zeros (like the Cray J90, according to Tim Peters).
echo $ac_n "checking whether right shift extends the sign bit""... $ac_c" 1>&6
! echo "configure:5815: checking whether right shift extends the sign bit" >&5
if eval "test \"`echo '$''{'ac_cv_rshift_extends_sign'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
***************
*** 5861,5865 ****
else
cat > conftest.$ac_ext <<EOF
! #line 5864 "configure"
#include "confdefs.h"

--- 5821,5825 ----
else
cat > conftest.$ac_ext <<EOF
! #line 5824 "configure"
#include "confdefs.h"

***************
*** 5870,5874 ****

EOF
! if { (eval echo configure:5873: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_rshift_extends_sign=yes
--- 5830,5834 ----

EOF
! if { (eval echo configure:5833: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_rshift_extends_sign=yes
***************
*** 5902,5911 ****
EOF
echo $ac_n "checking for socklen_t""... $ac_c" 1>&6
! echo "configure:5905: checking for socklen_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_socklen_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5910 "configure"
#include "confdefs.h"
#include <sys/types.h>
--- 5862,5871 ----
EOF
echo $ac_n "checking for socklen_t""... $ac_c" 1>&6
! echo "configure:5865: checking for socklen_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_socklen_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
! #line 5870 "configure"
#include "confdefs.h"
#include <sys/types.h>
***************
*** 5936,5940 ****

echo $ac_n "checking for Modules/Setup""... $ac_c" 1>&6
! echo "configure:5939: checking for Modules/Setup" >&5
if test ! -f Modules/Setup ; then
if test ! -d Modules ; then
--- 5896,5900 ----

echo $ac_n "checking for Modules/Setup""... $ac_c" 1>&6
! echo "configure:5899: checking for Modules/Setup" >&5
if test ! -f Modules/Setup ; then
if test ! -d Modules ; then



From python-dev@python.org Fri Nov 10 00:06:42 2000
From: python-dev@python.org (Moshe Zadka)
Date: Thu, 9 Nov 2000 16:06:42 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0216.txt,1.4,1.5
Message-ID: <200011100006.QAA27456@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv27418

Modified Files:
pep-0216.txt
Log Message:
Adding more questions which sprang up in the doc-sig.


Index: pep-0216.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0216.txt,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -r1.4 -r1.5
*** pep-0216.txt 2000/11/07 09:11:04 1.4
--- pep-0216.txt 2000/11/10 00:06:39 1.5
***************
*** 98,101 ****
--- 98,107 ----
Unresolved Issues

+ Is there a way to escape characters in ST? If so, how?
+ (example: * at the beginning of a line without being bullet symbol)
+
+ Is my suggestion above for Python symbols compatible with ST-NG?
+ How hard would it be to extend ST-NG to support it?
+
How do we describe input and output types of functions?




From python-dev@python.org Fri Nov 10 13:17:51 2000
From: python-dev@python.org (Moshe Zadka)
Date: Fri, 10 Nov 2000 05:17:51 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0216.txt,1.5,1.6
Message-ID: <200011101317.FAA10169@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv9880

Modified Files:
pep-0216.txt
Log Message:
Added some examples.
Clarified the fact I'm talking about ST-NG.


Index: pep-0216.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0216.txt,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -r1.5 -r1.6
*** pep-0216.txt 2000/11/10 00:06:39 1.5
--- pep-0216.txt 2000/11/10 13:17:48 1.6
***************
*** 81,85 ****
--- 81,95 ----

a. A tag that means "this is a Python ``something'', guess what"
+
+ Example: In the sentence "The POP3 class", we need to markup "POP3"
+ so. The parser will be able to guess it is a class from the contents
+ of the poplib module, but we need to make it guess.
+
b. Tags that mean "this is a Python class/module/class var/instance var..."
+
+ Example: In the sentence "This can be a regular file or a StringIO object"
+ we need to markup "StringIO" as a Python class (the guesser might guess
+ it to be a module by mistake).
+
c. An easy way to include Python source code/Python interactive sessions
d. Emphasis/bold
***************
*** 88,92 ****
Docstring Basic Structure

! The documentation strings will be in StructuredText
(http://www.zope.org/Members/jim/StructuredTextWiki/StructuredTextNG)
Since StructuredText is not yet strong enough to handle (a) and (b)
--- 98,102 ----
Docstring Basic Structure

! The documentation strings will be in StructuredTextNG
(http://www.zope.org/Members/jim/StructuredTextWiki/StructuredTextNG)
Since StructuredText is not yet strong enough to handle (a) and (b)



From python-dev@python.org Fri Nov 10 19:04:22 2000
From: python-dev@python.org (Tim Peters)
Date: Fri, 10 Nov 2000 11:04:22 -0800
Subject: [Python-checkins] CVS: python/dist/src/Modules arraymodule.c,2.58,2.59
Message-ID: <200011101904.LAA21935@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Modules
In directory slayer.i.sourceforge.net:/tmp/cvs-serv21831/python/dist/src/modules

Modified Files:
arraymodule.c
Log Message:
Fix for SF bug 117402, crashes on str(array) and repr(array). This was an
unfortunate consequence of somebody switching from PyArg_Parse to
PyArg_ParseTuple but without changing the argument from a NULL to a tuple.


Index: arraymodule.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Modules/arraymodule.c,v
retrieving revision 2.58
retrieving revision 2.59
diff -C2 -r2.58 -r2.59
*** arraymodule.c 2000/09/26 05:46:01 2.58
--- arraymodule.c 2000/11/10 19:04:19 2.59
***************
*** 1192,1196 ****
int ok = 0;
int i, len;
- PyObject *t_empty = PyTuple_New(0);
PyObject *v;
len = a->ob_size;
--- 1192,1195 ----
***************
*** 1200,1206 ****
}
if (a->ob_descr->typecode == 'c') {
fprintf(fp, "array('c', ");
v = array_tostring(a, t_empty);
! Py_DECREF(t_empty);;
ok = PyObject_Print(v, fp, 0);
Py_XDECREF(v);
--- 1199,1206 ----
}
if (a->ob_descr->typecode == 'c') {
+ PyObject *t_empty = PyTuple_New(0);
fprintf(fp, "array('c', ");
v = array_tostring(a, t_empty);
! Py_DECREF(t_empty);
ok = PyObject_Print(v, fp, 0);
Py_XDECREF(v);
***************
*** 1232,1238 ****
}
if (a->ob_descr->typecode == 'c') {
sprintf(buf, "array('c', ");
s = PyString_FromString(buf);
! v = array_tostring(a, (PyObject *)NULL);
t = PyObject_Repr(v);
Py_XDECREF(v);
--- 1232,1240 ----
}
if (a->ob_descr->typecode == 'c') {
+ PyObject *t_empty = PyTuple_New(0);
sprintf(buf, "array('c', ");
s = PyString_FromString(buf);
! v = array_tostring(a, t_empty);
! Py_DECREF(t_empty);
t = PyObject_Repr(v);
Py_XDECREF(v);



From python-dev@python.org Sat Nov 11 02:47:13 2000
From: python-dev@python.org (Greg Ward)
Date: Fri, 10 Nov 2000 18:47:13 -0800
Subject: [Python-checkins] CVS: distutils/distutils dist.py,1.41,1.42
Message-ID: <200011110247.SAA07007@slayer.i.sourceforge.net>

Update of /cvsroot/python/distutils/distutils
In directory slayer.i.sourceforge.net:/tmp/cvs-serv6892/distutils

Modified Files:
dist.py
Log Message:
Jack Jansen: added 'get_command_list()' method, and Mac-specific code to
use it to generate a dialog for users to specify the command-line (because
providing a command-line with MacPython is so awkward).


Index: dist.py
==================================================================RCS file: /cvsroot/python/distutils/distutils/dist.py,v
retrieving revision 1.41
retrieving revision 1.42
diff -C2 -r1.41 -r1.42
*** dist.py 2000/10/14 04:06:40 1.41
--- dist.py 2000/11/11 02:47:11 1.42
***************
*** 173,176 ****
--- 173,182 ----
# It's only safe to query 'have_run' for a command class that has
# been instantiated -- a false value will be inserted when the
+ if sys.platform == 'mac':
+ import EasyDialogs
+ cmdlist = self.get_command_list()
+ self.script_args = EasyDialogs.GetArgv(
+ self.global_options + self.display_options, cmdlist)
+
# command object is created, and replaced with a true value when
# the command is successfully run. Thus it's probably best to use
***************
*** 658,661 ****
--- 664,699 ----
# print_commands ()

+ def get_command_list (self):
+ """Get a list of (command, description) tuples.
+ The list is divided into "standard commands" (listed in
+ distutils.command.__all__) and "extra commands" (mentioned in
+ self.cmdclass, but not a standard command). The descriptions come
+ from the command class attribute 'description'.
+ """
+ # Currently this is only used on Mac OS, for the Mac-only GUI
+ # Distutils interface (by Jack Jansen)
+
+ import distutils.command
+ std_commands = distutils.command.__all__
+ is_std = {}
+ for cmd in std_commands:
+ is_std[cmd] = 1
+
+ extra_commands = []
+ for cmd in self.cmdclass.keys():
+ if not is_std.get(cmd):
+ extra_commands.append(cmd)
+
+ rv = []
+ for cmd in (std_commands + extra_commands):
+ klass = self.cmdclass.get(cmd)
+ if not klass:
+ klass = self.get_command_class(cmd)
+ try:
+ description = klass.description
+ except AttributeError:
+ description = "(no description available)"
+ rv.append((cmd, description))
+ return rv

# -- Command class/object methods ----------------------------------



From python-dev@python.org Mon Nov 13 17:11:47 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 09:11:47 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib/dos-8x3 basehttp.py,1.7,NONE bastion.py,1.7,NONE cgihttps.py,1.9,NONE compilea.py,1.5,NONE configpa.py,1.10,NONE cookie.py,1.1,NONE fileinpu.py,1.4,NONE formatte.py,1.9,NONE gopherli.py,1.3,NONE htmlenti.py,1.2,NONE linecach.py,1.2,NONE macurl2p.py,1.6,NONE mimetool.py,1.8,NONE mimetype.py,1.6,NONE mimewrit.py,1.6,NONE multifil.py,1.6,NONE nturl2pa.py,1.5,NONE posixfil.py,1.10,NONE posixpat.py,1.13,NONE py_compi.py,1.10,NONE queue.py,1.8,NONE reconver.py,1.3,NONE regex_sy.py,1.3,NONE regex_te.py,1.1,NONE rlcomple.py,1.7,NONE robotpar.py,1.1,NONE simpleht.py,1.8,NONE socketse.py,1.11,NONE sre_comp.py,1.7,NONE sre_cons.py,1.5,NONE sre_pars.py,1.8,NONE statcach.py,1.2,NONE string_t.py,1.1,NONE stringio.py,1.7,NONE stringol.py,1.2,NONE telnetli.py,1.4,NONE test_arr.py,1.9,NONE test_ate.py,1.1,NONE test_aud.py,1.4,NONE test_aug.py,1.1,NONE test_bin.py,1.5,NONE test_bsd.py,1.3,NONE test_bui.py,1.1,NONE test_cfg.py,1.1,NONE test_cla.py,1.2,NONE tes!
t_cma.py,1.3,NONE test_com.py,1.1,NONE test_con.py,1.1,NONE test_coo.py,1.1,NONE test_cop.py,1.1,NONE test_cpi.py,1.3,NONE test_cry.py,1.2,NONE test_dos.py,1.1,NONE test_err.py,1.3,NONE test_exc.py,1.6,NONE test_ext.py,1.2,NONE test_fcn.py,1.9,NONE test_fil.py,1.1,NONE test_for.py,1.2,NONE test_gdb.py,1.2,NONE test_get.py,1.1,NONE test_gra.py,1.6,NONE test_gzi.py,1.2,NONE test_has.py,1.1,NONE test_ima.py,1.6,NONE test_img.py,1.4,NONE test_imp.py,1.1,NONE test_lar.py,1.1,NONE test_lin.py,1.3,NONE test_lon.py,1.2,NONE test_mat.py,1.6,NONE test_mim.py,1.1,NONE test_min.py,1.4,NONE test_mma.py,1.4,NONE test_ntp.py,1.3,NONE test_opc.py,1.4,NONE test_ope.py,1.5,NONE test_par.py,1.1,NONE test_pic.py,1.2,NONE test_pol.py,1.1,NONE test_pop.py,1.3,NONE test_pos.py,1.1,NONE test_pye.py,1.3,NONE test_reg.py,1.4,NONE test_rfc.py,1.3,NONE test_rgb.py,1.7,NONE test_rot.py,1.3,NONE test_sel.py,1.7,NONE test_sig.py,1.5,NONE test_soc.py,1.7,NONE test_str.py,1.13,NONE test_sun.py,1.3,NONE tes!
t_sup.py,1.4,NONE test_thr.py,1.4,NONE test_tim.py,1.7,NONE te!
st_tok.p
Message-ID: <200011131711.JAA18365@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib/dos-8x3
In directory slayer.i.sourceforge.net:/tmp/cvs-serv18354

Removed Files:
basehttp.py bastion.py cgihttps.py compilea.py configpa.py
cookie.py fileinpu.py formatte.py gopherli.py htmlenti.py
linecach.py macurl2p.py mimetool.py mimetype.py mimewrit.py
multifil.py nturl2pa.py posixfil.py posixpat.py py_compi.py
queue.py reconver.py regex_sy.py regex_te.py rlcomple.py
robotpar.py simpleht.py socketse.py sre_comp.py sre_cons.py
sre_pars.py statcach.py string_t.py stringio.py stringol.py
telnetli.py test_arr.py test_ate.py test_aud.py test_aug.py
test_bin.py test_bsd.py test_bui.py test_cfg.py test_cla.py
test_cma.py test_com.py test_con.py test_coo.py test_cop.py
test_cpi.py test_cry.py test_dos.py test_err.py test_exc.py
test_ext.py test_fcn.py test_fil.py test_for.py test_gdb.py
test_get.py test_gra.py test_gzi.py test_has.py test_ima.py
test_img.py test_imp.py test_lar.py test_lin.py test_lon.py
test_mat.py test_mim.py test_min.py test_mma.py test_ntp.py
test_opc.py test_ope.py test_par.py test_pic.py test_pol.py
test_pop.py test_pos.py test_pye.py test_reg.py test_rfc.py
test_rgb.py test_rot.py test_sel.py test_sig.py test_soc.py
test_str.py test_sun.py test_sup.py test_thr.py test_tim.py
test_tok.py test_typ.py test_uni.py test_unp.py test_url.py
test_use.py test_wav.py test_win.py test_xml.py test_zip.py
test_zli.py threadin.py tokenize.py tracebac.py userdict.py
userlist.py userstri.py webbrows.py
Log Message:
Removing DOS 8x3 support

--- basehttp.py DELETED ---

--- bastion.py DELETED ---

--- cgihttps.py DELETED ---

--- compilea.py DELETED ---

--- configpa.py DELETED ---

--- cookie.py DELETED ---

--- fileinpu.py DELETED ---

--- formatte.py DELETED ---

--- gopherli.py DELETED ---

--- htmlenti.py DELETED ---

--- linecach.py DELETED ---

--- macurl2p.py DELETED ---

--- mimetool.py DELETED ---

--- mimetype.py DELETED ---

--- mimewrit.py DELETED ---

--- multifil.py DELETED ---

--- nturl2pa.py DELETED ---

--- posixfil.py DELETED ---

--- posixpat.py DELETED ---

--- py_compi.py DELETED ---

--- queue.py DELETED ---

--- reconver.py DELETED ---

--- regex_sy.py DELETED ---

--- regex_te.py DELETED ---

--- rlcomple.py DELETED ---

--- robotpar.py DELETED ---

--- simpleht.py DELETED ---

--- socketse.py DELETED ---

--- sre_comp.py DELETED ---

--- sre_cons.py DELETED ---

--- sre_pars.py DELETED ---

--- statcach.py DELETED ---

--- string_t.py DELETED ---

--- stringio.py DELETED ---

--- stringol.py DELETED ---

--- telnetli.py DELETED ---

--- test_arr.py DELETED ---

--- test_ate.py DELETED ---

--- test_aud.py DELETED ---

--- test_aug.py DELETED ---

--- test_bin.py DELETED ---

--- test_bsd.py DELETED ---

--- test_bui.py DELETED ---

--- test_cfg.py DELETED ---

--- test_cla.py DELETED ---

--- test_cma.py DELETED ---

--- test_com.py DELETED ---

--- test_con.py DELETED ---

--- test_coo.py DELETED ---

--- test_cop.py DELETED ---

--- test_cpi.py DELETED ---

--- test_cry.py DELETED ---

--- test_dos.py DELETED ---

--- test_err.py DELETED ---

--- test_exc.py DELETED ---

--- test_ext.py DELETED ---

--- test_fcn.py DELETED ---

--- test_fil.py DELETED ---

--- test_for.py DELETED ---

--- test_gdb.py DELETED ---

--- test_get.py DELETED ---

--- test_gra.py DELETED ---

--- test_gzi.py DELETED ---

--- test_has.py DELETED ---

--- test_ima.py DELETED ---

--- test_img.py DELETED ---

--- test_imp.py DELETED ---

--- test_lar.py DELETED ---

--- test_lin.py DELETED ---

--- test_lon.py DELETED ---

--- test_mat.py DELETED ---

--- test_mim.py DELETED ---

--- test_min.py DELETED ---

--- test_mma.py DELETED ---

--- test_ntp.py DELETED ---

--- test_opc.py DELETED ---

--- test_ope.py DELETED ---

--- test_par.py DELETED ---

--- test_pic.py DELETED ---

--- test_pol.py DELETED ---

--- test_pop.py DELETED ---

--- test_pos.py DELETED ---

--- test_pye.py DELETED ---

--- test_reg.py DELETED ---

--- test_rfc.py DELETED ---

--- test_rgb.py DELETED ---

--- test_rot.py DELETED ---

--- test_sel.py DELETED ---

--- test_sig.py DELETED ---

--- test_soc.py DELETED ---

--- test_str.py DELETED ---

--- test_sun.py DELETED ---

--- test_sup.py DELETED ---

--- test_thr.py DELETED ---

--- test_tim.py DELETED ---

--- test_tok.py DELETED ---

--- test_typ.py DELETED ---

--- test_uni.py DELETED ---

--- test_unp.py DELETED ---

--- test_url.py DELETED ---

--- test_use.py DELETED ---

--- test_wav.py DELETED ---

--- test_win.py DELETED ---

--- test_xml.py DELETED ---

--- test_zip.py DELETED ---

--- test_zli.py DELETED ---

--- threadin.py DELETED ---

--- tokenize.py DELETED ---

--- tracebac.py DELETED ---

--- userdict.py DELETED ---

--- userlist.py DELETED ---

--- userstri.py DELETED ---

--- webbrows.py DELETED ---



From python-dev@python.org Mon Nov 13 17:22:01 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 09:22:01 -0800
Subject: [Python-checkins] CVS: python/dist/src/PC readme.txt,1.22,1.23 make8x3.py,1.3,NONE makesrc.exe,1.1,NONE pyth_w31.def,1.2,NONE python.wpj,1.7,NONE
Message-ID: <200011131722.JAA19441@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/PC
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19404

Modified Files:
readme.txt
Removed Files:
make8x3.py makesrc.exe pyth_w31.def python.wpj
Log Message:
Rip out Win3.1 and DOS support

Index: readme.txt
==================================================================RCS file: /cvsroot/python/python/dist/src/PC/readme.txt,v
retrieving revision 1.22
retrieving revision 1.23
diff -C2 -r1.22 -r1.23
*** readme.txt 2000/06/30 13:00:32 1.22
--- readme.txt 2000/11/13 17:21:58 1.23
***************
*** 2,6 ****
***********************************************************

! *** Note: the project files for MS VC++ 5.0 and 6.0 are now in the
*** PCbuild directory. See the file readme.txt there for build
*** instructions. There is some information below that might
--- 2,6 ----
***********************************************************

! *** Note: the project files for MS VC++ 6.0 are now in the
*** PCbuild directory. See the file readme.txt there for build
*** instructions. There is some information below that might
***************
*** 63,72 ****
skipped tests (these test unavailable optional features).

- src A subdirectory used only for VC++ version 1.5 Python
- source files. See below. The other compilers do not
- use it. They reference the actual distribution
- directories instead.

-
Additional files and subdirectories for 32-bit Windows
=====================================================--- 63,67 ----
***************
*** 86,131 ****


- Microsoft Visual C++ Version 1.5 (16-bit Windows)
- ================================================-
- Since VC++1.5 does not handle long file names, it is necessary
- to run the "makesrc.exe" program in this directory to copy
- Python files from the distribution to the directory "src"
- with shortened names. Included file names are shortened too.
- Do this before you attempt to build Python.
-
- The "makesrc.exe" program is a native NT program, and you must
- have NT, Windows 95 or Win32s to run it. Otherwise you will need
- to copy distribution files to src yourself.
-
- The makefiles are named *.mak and are located in directories
- starting with "vc15_". NOTE: When dependencies are scanned
- VC++ will create dependencies for directories which are not
- used because it fails to evaluate "#define" properly. You
- must manaully edit makefiles (*.mak) to remove references to
- "sys/" and other bad directories.
-
- vc15_lib A static Python library. Create this first because is
- is required for vc15_w31.
-
- vc15_w31 A Windows 3.1x Python QuickWin (console-mode)
- Python including sockets. Requires vc15_lib.
-
-
- Watcom C++ Version 10.6
- ======================-
- The project file for the Watcom compiler is ./python.wpj.
- It will build Watcom versions in the directories wat_*.
-
- wat_dos A 32-bit extended DOS Python (console-mode) using the
- dos4gw DOS extender. Sockets are not included.
-
- wat_os2 A 32-bit OS/2 Python (console-mode).
- Sockets are not included.
-
-
IBM VisualAge C/C++ for OS/2
===========================
See os2vacpp/readme.txt. This platform is supported by Jeff Rush.
--- 81,95 ----


IBM VisualAge C/C++ for OS/2
===========================
See os2vacpp/readme.txt. This platform is supported by Jeff Rush.
+
+
+ Note for Windows 3.x and DOS users
+ =================================+
+ Neither Windows 3.x nor DOS is supported any more. The last Python
+ version that supported these was Python 1.5.2; the support files were
+ present in Python 2.0 but weren't updated, and it is not our intention
+ to support these platforms for Python 2.x.

--- make8x3.py DELETED ---

--- makesrc.exe DELETED ---

--- pyth_w31.def DELETED ---

--- python.wpj DELETED ---



From python-dev@python.org Mon Nov 13 17:22:02 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 09:22:02 -0800
Subject: [Python-checkins] CVS: python/dist/src/PC/vc15_w31 _.c,1.2,NONE pyth_w31.mak,1.6,NONE pyth_w31.pdb,1.1,NONE pyth_w31.vcw,1.2,NONE pyth_w31.wsp,1.2,NONE
Message-ID: <200011131722.JAA19453@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/PC/vc15_w31
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19404/vc15_w31

Removed Files:
_.c pyth_w31.mak pyth_w31.pdb pyth_w31.vcw pyth_w31.wsp
Log Message:
Rip out Win3.1 and DOS support

--- _.c DELETED ---

--- pyth_w31.mak DELETED ---

--- pyth_w31.pdb DELETED ---

--- pyth_w31.vcw DELETED ---

--- pyth_w31.wsp DELETED ---



From python-dev@python.org Mon Nov 13 17:22:02 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 09:22:02 -0800
Subject: [Python-checkins] CVS: python/dist/src/PC/wat_os2 pyth_os2.lk1,1.3,NONE pyth_os2.mk1,1.4,NONE pyth_os2.tgt,1.5,NONE
Message-ID: <200011131722.JAA19463@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/PC/wat_os2
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19404/wat_os2

Removed Files:
pyth_os2.lk1 pyth_os2.mk1 pyth_os2.tgt
Log Message:
Rip out Win3.1 and DOS support

--- pyth_os2.lk1 DELETED ---

--- pyth_os2.mk1 DELETED ---

--- pyth_os2.tgt DELETED ---



From python-dev@python.org Mon Nov 13 17:22:02 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 09:22:02 -0800
Subject: [Python-checkins] CVS: python/dist/src/PC/vc15_lib _.c,1.2,NONE python.mak,1.7,NONE python.vcw,1.2,NONE python.wsp,1.3,NONE
Message-ID: <200011131722.JAA19448@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/PC/vc15_lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19404/vc15_lib

Removed Files:
_.c python.mak python.vcw python.wsp
Log Message:
Rip out Win3.1 and DOS support

--- _.c DELETED ---

--- python.mak DELETED ---

--- python.vcw DELETED ---

--- python.wsp DELETED ---



From python-dev@python.org Mon Nov 13 17:22:02 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 09:22:02 -0800
Subject: [Python-checkins] CVS: python/dist/src/PC/wat_dos pyth_dos.lk1,1.3,NONE pyth_dos.mk1,1.4,NONE pyth_dos.tgt,1.5,NONE
Message-ID: <200011131722.JAA19457@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/PC/wat_dos
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19404/wat_dos

Removed Files:
pyth_dos.lk1 pyth_dos.mk1 pyth_dos.tgt
Log Message:
Rip out Win3.1 and DOS support

--- pyth_dos.lk1 DELETED ---

--- pyth_dos.mk1 DELETED ---

--- pyth_dos.tgt DELETED ---



From python-dev@python.org Mon Nov 13 17:23:22 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 09:23:22 -0800
Subject: [Python-checkins] CVS: python/dist/src/PC/src readme.txt,1.1,NONE
Message-ID: <200011131723.JAA19606@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/PC/src
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19595

Removed Files:
readme.txt
Log Message:
Rip out Win3.1 and DOS support

--- readme.txt DELETED ---



From python-dev@python.org Mon Nov 13 17:24:15 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 09:24:15 -0800
Subject: [Python-checkins] CVS: python/dist/src/PC/utils makesrc.c,1.2,NONE makesrc.lk1,1.2,NONE makesrc.mk1,1.2,NONE makesrc.tgt,1.2,NONE utils.mk,1.2,NONE utils.wpj,1.2,NONE
Message-ID: <200011131724.JAA19715@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/PC/utils
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19707

Removed Files:
makesrc.c makesrc.lk1 makesrc.mk1 makesrc.tgt utils.mk
utils.wpj
Log Message:
Rip out Win3.1 and DOS support

--- makesrc.c DELETED ---

--- makesrc.lk1 DELETED ---

--- makesrc.mk1 DELETED ---

--- makesrc.tgt DELETED ---

--- utils.mk DELETED ---

--- utils.wpj DELETED ---



From python-dev@python.org Mon Nov 13 17:26:35 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 09:26:35 -0800
Subject: [Python-checkins] CVS: python/dist/src/Python import.c,2.153,2.154
Message-ID: <200011131726.JAA19973@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Python
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19962

Modified Files:
import.c
Log Message:
Rip out DOS-8x3 support.


Index: import.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Python/import.c,v
retrieving revision 2.153
retrieving revision 2.154
diff -C2 -r2.153 -r2.154
*** import.c 2000/10/03 16:02:05 2.153
--- import.c 2000/11/13 17:26:32 2.154
***************
*** 958,978 ****
)
buf[len++] = SEP;
! #ifdef IMPORT_8x3_NAMES
! /* see if we are searching in directory dos-8x3 */
! if (len > 7 && !strncmp(buf + len - 8, "dos-8x3", 7)){
! int j;
! char ch; /* limit name to 8 lower-case characters */
! for (j = 0; (ch = name[j]) && j < 8; j++)
! if (isupper(ch))
! buf[len++] = tolower(ch);
! else
! buf[len++] = ch;
! }
! else /* Not in dos-8x3, use the full name */
! #endif
! {
! strcpy(buf+len, name);
! len += namelen;
! }
#ifdef HAVE_STAT
if (stat(buf, &statbuf) == 0) {
--- 958,963 ----
)
buf[len++] = SEP;
! strcpy(buf+len, name);
! len += namelen;
#ifdef HAVE_STAT
if (stat(buf, &statbuf) == 0) {



From python-dev@python.org Mon Nov 13 17:29:34 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 09:29:34 -0800
Subject: [Python-checkins] CVS: python/dist/src/PC config.h,1.46,1.47
Message-ID: <200011131729.JAA20270@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/PC
In directory slayer.i.sourceforge.net:/tmp/cvs-serv20261

Modified Files:
config.h
Log Message:
Rip out DOS and Win16 support.


Index: config.h
==================================================================RCS file: /cvsroot/python/python/dist/src/PC/config.h,v
retrieving revision 1.46
retrieving revision 1.47
diff -C2 -r1.46 -r1.47
*** config.h 2000/08/31 19:23:01 1.46
--- config.h 2000/11/13 17:29:30 1.47
***************
*** 129,223 ****
#endif /* _MSC_VER && > 850 */

- #if defined(_MSC_VER) && _MSC_VER <= 850 /* presume this implies Win16 */
- /* Start of defines for 16-bit Windows using VC++ 1.5 */
- #define COMPILER "[MSC 16-bit]"
- #define PYTHONPATH ".;.\\lib;.\\lib\\plat-win;.\\lib\\dos-8x3"
- #define IMPORT_8x3_NAMES
- typedef int pid_t;
- #define WORD_BIT 16
- #define SIZEOF_INT 2
- #define SIZEOF_LONG 4
- #define SIZEOF_VOID_P 4
- #pragma warning(disable:4113)
- #define memcpy memmove /* memcpy dangerous pointer wrap in Win 3.1 */
- #define hypot _hypot
- #define SIGINT 2
- #include <stdio.h>
- /* Windows 3.1 will not tolerate any console io in a dll */
- #ifdef _USRDLL
- #include <time.h>
- #ifdef __cplusplus
- extern "C" {
- #endif
- #define stdin ((FILE *)0)
- #define stdout ((FILE *)1)
- #define stderr ((FILE *)2)
- #define fflush Py_fflush
- int Py_fflush(FILE *);
- #define fgets Py_fgets
- char *Py_fgets(char *, int, FILE *);
- #define fileno Py_fileno
- int Py_fileno(FILE *);
- #define fprintf Py_fprintf
- int Py_fprintf(FILE *, const char *, ...);
- #define printf Py_printf
- int Py_printf(const char *, ...);
- #define sscanf Py_sscanf
- int Py_sscanf(const char *, const char *, ...);
- clock_t clock();
- void _exit(int);
- void exit(int);
- int sscanf(const char *, const char *, ...);
- #ifdef __cplusplus
- }
- #endif
- #endif /* _USRDLL */
- #ifndef NETSCAPE_PI
- /* use sockets, but not in a Netscape dll */
- #define USE_SOCKET
- #endif
- #endif /* MS_WIN16 */
-
- /* The Watcom compiler defines __WATCOMC__ */
- #ifdef __WATCOMC__
- #define COMPILER "[Watcom]"
- #define PYTHONPATH ".;.\\lib;.\\lib\\plat-win;.\\lib\\dos-8x3"
- #define IMPORT_8x3_NAMES
- #include <ctype.h>
- #include <direct.h>
- typedef int mode_t;
- typedef int uid_t;
- typedef int gid_t;
- typedef int pid_t;
- #if defined(__NT__)
- #define NT /* NT is obsolete - please use MS_WIN32 instead */
- #define MS_WIN32
- #define MS_WINDOWS
- #define NT_THREADS
- #define USE_SOCKET
- #define WITH_THREAD
- #elif defined(__WINDOWS__)
- #define MS_WIN16
- #define MS_WINDOWS
- #endif
- #ifdef M_I386
- #define WORD_BIT 32
- #define SIZEOF_INT 4
- #define SIZEOF_LONG 4
- #define SIZEOF_VOID_P 4
- #else
- #define WORD_BIT 16
- #define SIZEOF_INT 2
- #define SIZEOF_LONG 4
- #define SIZEOF_VOID_P 4
- #endif
- #define VA_LIST_IS_ARRAY
- #define HAVE_CLOCK
- #define HAVE_STRFTIME
- #ifdef USE_DL_EXPORT
- #define DL_IMPORT(RTYPE) RTYPE __export
- #endif
- #endif /* __WATCOMC__ */
-
/* The Borland compiler defines __BORLANDC__ */
/* XXX These defines are likely incomplete, but should be easy to fix. */
--- 129,132 ----
***************
*** 269,280 ****

#else /* !_WIN32 */
! /* XXX These defines are likely incomplete, but should be easy to fix. */
!
! #define PYTHONPATH ".;.\\lib;.\\lib\\plat-win;.\\lib\\dos-8x3"
! #define IMPORT_8x3_NAMES
! #ifdef USE_DL_IMPORT
! #define DL_IMPORT(RTYPE) RTYPE __import
! #endif
!
#endif /* !_WIN32 */

--- 178,182 ----

#else /* !_WIN32 */
! #error "Only Win32 and later are supported"
#endif /* !_WIN32 */

***************
*** 416,423 ****
# define SIZEOF_HKEY 4
# endif
- #elif defined(MS_WIN16)
- # define PLATFORM "win16"
- #else
- # define PLATFORM "dos"
#endif

--- 318,321 ----



From python-dev@python.org Mon Nov 13 19:45:49 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 11:45:49 -0800
Subject: [Python-checkins] CVS: python/dist/src/Python thread_cthread.h,2.13,2.14
Message-ID: <200011131945.LAA04294@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Python
In directory slayer.i.sourceforge.net:/tmp/cvs-serv4274

Modified Files:
thread_cthread.h
Log Message:
Fix syntax error. Submitted by Bill Bumgarner. Apparently this is
still in use, for Apple Mac OSX.


Index: thread_cthread.h
==================================================================RCS file: /cvsroot/python/python/dist/src/Python/thread_cthread.h,v
retrieving revision 2.13
retrieving revision 2.14
diff -C2 -r2.13 -r2.14
*** thread_cthread.h 2000/09/01 23:29:28 2.13
--- thread_cthread.h 2000/11/13 19:45:45 2.14
***************
*** 16,20 ****
*/
int
! PyThread_start_new_thread(func, void (*func)(void *), void *arg)
{
int success = 0; /* init not needed when SOLARIS_THREADS and */
--- 16,20 ----
*/
int
! PyThread_start_new_thread(void (*func)(void *), void *arg)
{
int success = 0; /* init not needed when SOLARIS_THREADS and */



From python-dev@python.org Mon Nov 13 19:48:25 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 11:48:25 -0800
Subject: [Python-checkins] CVS: python/dist/src/Objects fileobject.c,2.91,2.92
Message-ID: <200011131948.LAA04697@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Objects
In directory slayer.i.sourceforge.net:/tmp/cvs-serv4689

Modified Files:
fileobject.c
Log Message:
Added _HAVE_BSDI and __APPLE__ to the list of platforms that require a
hack for TELL64()... Sounds like there's something else going on
really. Does anybody have a clue I can buy?


Index: fileobject.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Objects/fileobject.c,v
retrieving revision 2.91
retrieving revision 2.92
diff -C2 -r2.91 -r2.92
*** fileobject.c 2000/10/24 19:57:45 2.91
--- fileobject.c 2000/11/13 19:48:22 2.92
***************
*** 59,63 ****
#if defined(MS_WIN64)
#define TELL64 _telli64
! #elif defined(__NetBSD__) || defined(__OpenBSD__)
/* NOTE: this is only used on older
NetBSD prior to f*o() funcions */
--- 59,63 ----
#if defined(MS_WIN64)
#define TELL64 _telli64
! #elif defined(__NetBSD__) || defined(__OpenBSD__) || defined(_HAVE_BSDI) || defined(__APPLE__)
/* NOTE: this is only used on older
NetBSD prior to f*o() funcions */



From python-dev@python.org Mon Nov 13 20:21:11 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 12:21:11 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0042.txt,1.43,1.44
Message-ID: <200011132021.MAA09003@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv8993

Modified Files:
pep-0042.txt
Log Message:
Addtwo more wishes: kill thread, Python/python name conflict.


Index: pep-0042.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0042.txt,v
retrieving revision 1.43
retrieving revision 1.44
diff -C2 -r1.43 -r1.44
*** pep-0042.txt 2000/11/06 18:49:06 1.43
--- pep-0042.txt 2000/11/13 20:21:08 1.44
***************
*** 216,219 ****
--- 216,224 ----
<linuxqna@chollian.net>.]

+ - Killing a thread from another thread. Or maybe sending a
+ signal. Or maybe raising an asynchronous exception.
+
+ http://sourceforge.net/bugs/?funcÞtailbug&bug_id1115&group_idT70
+
Tools

***************
*** 253,256 ****
--- 258,270 ----

http://www.python.org/pipermail/python-dev/2000-October/016620.html
+
+ - There's a name conflict on case insensitive filesystems (in
+ particular Mac OSX) between the directory "Python" and the key
+ build target "python". That's currently solved by abusing the
+ --with-suffix option, but that's not ideal (since that also
+ causes the binary to be *installed* as python.exe). What should
+ be the solution?
+
+ http://sourceforge.net/bugs/?funcÞtailbug&bug_id2215&group_idT70





From python-dev@python.org Mon Nov 13 20:29:23 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 12:29:23 -0800
Subject: [Python-checkins] CVS: python/dist/src/Modules newmodule.c,2.28,2.29
Message-ID: <200011132029.MAA09988@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Modules
In directory slayer.i.sourceforge.net:/tmp/cvs-serv9978

Modified Files:
newmodule.c
Log Message:
Allow new.function() called with explicit 3rd arg of None, as
documented, and as is reasonable (since it is optional, but there's
another argument following it that may require you to specify a
value). This solves SF bug 121887.


Index: newmodule.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Modules/newmodule.c,v
retrieving revision 2.28
retrieving revision 2.29
diff -C2 -r2.28 -r2.29
*** newmodule.c 2000/10/10 22:07:18 2.28
--- newmodule.c 2000/11/13 20:29:20 2.29
***************
*** 71,75 ****
PyFunctionObject* newfunc;

! if (!PyArg_ParseTuple(args, "O!O!|SO!:function",
&PyCode_Type, &code,
&PyDict_Type, &globals,
--- 71,75 ----
PyFunctionObject* newfunc;

! if (!PyArg_ParseTuple(args, "O!O!|OO!:function",
&PyCode_Type, &code,
&PyDict_Type, &globals,
***************
*** 77,80 ****
--- 77,85 ----
&PyTuple_Type, &defaults))
return NULL;
+ if (name != Py_None && !PyString_Check(name)) {
+ PyErr_SetString(PyExc_TypeError,
+ "arg 3 (name) must be None or string");
+ return NULL;
+ }

newfunc = (PyFunctionObject *)PyFunction_New(code, globals);



From python-dev@python.org Mon Nov 13 20:31:00 2000
From: python-dev@python.org (Guido van Rossum)
Date: Mon, 13 Nov 2000 12:31:00 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib webbrowser.py,1.4,1.5
Message-ID: <200011132031.MAA10222@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv10204

Modified Files:
webbrowser.py
Log Message:
Typo for Mac code, fixing SF bug 12195.


Index: webbrowser.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/webbrowser.py,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -r1.4 -r1.5
*** webbrowser.py 2000/10/02 03:40:51 1.4
--- webbrowser.py 2000/11/13 20:30:57 1.5
***************
*** 216,220 ****
class InternetConfig:
def open(self, url, new=0):
! ic.launcurl(url)

def open_new(self, url):
--- 216,220 ----
class InternetConfig:
def open(self, url, new=0):
! ic.launchurl(url)

def open_new(self, url):



From python-dev@python.org Mon Nov 13 21:16:26 2000
From: python-dev@python.org (Trent Mick)
Date: Mon, 13 Nov 2000 13:16:26 -0800
Subject: [Python-checkins] CVS: python/dist/src/Objects fileobject.c,2.91,2.92
In-Reply-To: <200011131948.LAA04697@slayer.i.sourceforge.net>; from gvanrossum@users.sourceforge.net on Mon, Nov 13, 2000 at 11:48:25AM -0800
References: <200011131948.LAA04697@slayer.i.sourceforge.net>
Message-ID: <20001113131626.B4553@ActiveState.com>
On Mon, Nov 13, 2000 at 11:48:25AM -0800, Guido van Rossum wrote:
Update of /cvsroot/python/python/dist/src/Objects
In directory slayer.i.sourceforge.net:/tmp/cvs-serv4689

Modified Files:
fileobject.c
Log Message:
Added _HAVE_BSDI and __APPLE__ to the list of platforms that require a
hack for TELL64()... Sounds like there's something else going on
really. Does anybody have a clue I can buy?
Yes, there is. For all of these platforms HAVE_LARGEFILE_SUPPORT is defined
when it should not really be. Essentially, these platforms lie when they say
they support largefiles, at least according to the configure test for
HAVE_LARGEFILE_SUPPORT>

Trent


--
Trent Mick
TrentM@ActiveState.com


From python-dev@python.org Tue Nov 14 20:27:57 2000
From: python-dev@python.org (Tim Peters)
Date: Tue, 14 Nov 2000 12:27:57 -0800
Subject: [Python-checkins] CVS: python/nondist/peps pep-0042.txt,1.44,1.45
Message-ID: <200011142027.MAA26670@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/nondist/peps
In directory slayer.i.sourceforge.net:/tmp/cvs-serv26632/python/nondist/peps

Modified Files:
pep-0042.txt
Log Message:
Added SF Feature Request 121963: threads and IDLE don't mix.


Index: pep-0042.txt
==================================================================RCS file: /cvsroot/python/python/nondist/peps/pep-0042.txt,v
retrieving revision 1.44
retrieving revision 1.45
diff -C2 -r1.44 -r1.45
*** pep-0042.txt 2000/11/13 20:21:08 1.44
--- pep-0042.txt 2000/11/14 20:27:54 1.45
***************
*** 69,73 ****
be raised or removed. Removal would be hard because the
current compiler can overflow the C stack if the nesting is too
! deep.

http://sourceforge.net/bugs/?funcÞtailbug&bug_id5555&group_idT70
--- 69,73 ----
be raised or removed. Removal would be hard because the
current compiler can overflow the C stack if the nesting is too
! deep.

http://sourceforge.net/bugs/?funcÞtailbug&bug_id5555&group_idT70
***************
*** 184,188 ****

- urllib should support proxy definitions that contain just the
! host and port

http://sourceforge.net/bugs/?funcÞtailbug&bug_id0849&group_idT70
--- 184,188 ----

- urllib should support proxy definitions that contain just the
! host and port

http://sourceforge.net/bugs/?funcÞtailbug&bug_id0849&group_idT70
***************
*** 237,240 ****
--- 237,244 ----

http://sourceforge.net/bugs/?funcÞtailbug&bug_id0659&group_idT70
+
+ - IDLE has deep problems running threaded programs. Re-architect.
+
+ http://sourceforge.net/bugs/?funcÞtailbug&bug_id1963&group_idT70





From python-dev@python.org Tue Nov 14 20:44:57 2000
From: python-dev@python.org (Tim Peters)
Date: Tue, 14 Nov 2000 12:44:57 -0800
Subject: [Python-checkins] CVS: python/dist/src/Python compile.c,2.142,2.143 marshal.c,1.57,1.58
Message-ID: <200011142044.MAA27961@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Python
In directory slayer.i.sourceforge.net:/tmp/cvs-serv27853/python/dist/src/Python

Modified Files:
compile.c marshal.c
Log Message:
SF bug 119622: compile errors due to redundant atof decls. I don't understand
the bug report (for details, look at it), but agree there's no need for Python
to declare atof itself: we #include stdlib.h, and ANSI C sez atof is declared
there already.


Index: compile.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Python/compile.c,v
retrieving revision 2.142
retrieving revision 2.143
diff -C2 -r2.142 -r2.143
*** compile.c 2000/09/26 05:46:01 2.142
--- compile.c 2000/11/14 20:44:53 2.143
***************
*** 768,772 ****
parsenumber(struct compiling *co, char *s)
{
- extern double atof(const char *);
char *end;
long x;
--- 768,771 ----

Index: marshal.c
==================================================================RCS file: /cvsroot/python/python/dist/src/Python/marshal.c,v
retrieving revision 1.57
retrieving revision 1.58
diff -C2 -r1.57 -r1.58
*** marshal.c 2000/09/19 08:54:13 1.57
--- marshal.c 2000/11/14 20:44:53 1.58
***************
*** 404,408 ****
case TYPE_FLOAT:
{
- extern double atof(const char *);
char buf[256];
double dx;
--- 404,407 ----
***************
*** 423,427 ****
case TYPE_COMPLEX:
{
- extern double atof(const char *);
char buf[256];
Py_complex c;
--- 422,425 ----



From python-dev@python.org Tue Nov 14 21:36:09 2000
From: python-dev@python.org (Tim Peters)
Date: Tue, 14 Nov 2000 13:36:09 -0800
Subject: [Python-checkins] CVS: python/dist/src/Lib/test test_array.py,1.10,1.11
Message-ID: <200011142136.NAA01848@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Lib/test
In directory slayer.i.sourceforge.net:/tmp/cvs-serv1768/python/dist/src/Lib/test

Modified Files:
test_array.py
Log Message:
Verify that str(a) and repr(a) don't blow up (part of SF patch 102068).


Index: test_array.py
==================================================================RCS file: /cvsroot/python/python/dist/src/Lib/test/test_array.py,v
retrieving revision 1.10
retrieving revision 1.11
diff -C2 -r1.10 -r1.11
*** test_array.py 2000/10/23 17:22:07 1.10
--- test_array.py 2000/11/14 21:36:07 1.11
***************
*** 85,90 ****
--- 85,95 ----
a.tofile(f)
f.close()
+
+ # This block is just to verify that the operations don't blow up.
a.tolist()
a.tostring()
+ repr(a)
+ str(a)
+
if verbose:
print 'array of %s converted to a list: ' % a.typecode, a.tolist()



From python-dev@python.org Tue Nov 14 21:43:04 2000
From: python-dev@python.org (Tim Peters)
Date: Tue, 14 Nov 2000 13:43:04 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib librotor.tex,1.16,1.17
Message-ID: <200011142143.NAA02618@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv2579/python/dist/src/doc/lib

Modified Files:
librotor.tex
Log Message:
Fix for SF bug 122176: Error in rotor module documentation.


Index: librotor.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/librotor.tex,v
retrieving revision 1.16
retrieving revision 1.17
diff -C2 -r1.16 -r1.17
*** librotor.tex 2000/10/10 17:03:45 1.16
--- librotor.tex 2000/11/14 21:43:01 1.17
***************
*** 55,59 ****
\begin{methoddesc}[rotor]{decrypt}{ciphertext}
Reset the rotor object to its initial state and decrypt \var{ciphertext},
! returning a string containing the ciphertext. The plaintext string will
always be the same length as the ciphertext.
\end{methoddesc}
--- 55,59 ----
\begin{methoddesc}[rotor]{decrypt}{ciphertext}
Reset the rotor object to its initial state and decrypt \var{ciphertext},
! returning a string containing the plaintext. The plaintext string will
always be the same length as the ciphertext.
\end{methoddesc}
***************
*** 61,65 ****
\begin{methoddesc}[rotor]{decryptmore}{ciphertext}
Decrypt \var{ciphertext} without resetting the rotor object, and return a
! string containing the ciphertext.
\end{methoddesc}

--- 61,65 ----
\begin{methoddesc}[rotor]{decryptmore}{ciphertext}
Decrypt \var{ciphertext} without resetting the rotor object, and return a
! string containing the plaintext.
\end{methoddesc}




From python-dev@python.org Thu Nov 16 21:25:54 2000
From: python-dev@python.org (Guido van Rossum)
Date: Thu, 16 Nov 2000 13:25:54 -0800
Subject: [Python-checkins] CVS: python/dist/src/Demo/scripts queens.py,NONE,1.1
Message-ID: <200011162125.NAA19499@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Demo/scripts
In directory slayer.i.sourceforge.net:/tmp/cvs-serv19493

Added Files:
queens.py
Log Message:
A solution to the classic N queens problem.


--- NEW FILE ---
#! /usr/bin/env python

"""N queens problem.

The (well-known) problem is due to Niklaus Wirth.

This solution is inspired by Dijkstra (Structured Programming). It is
a classic recursive backtracking approach.

"""

N = 8 # Default; command line overrides

class Queens:

def __init__(self, n=N):
self.n = n
self.reset()

def reset(self):
n = self.n
self.y = [None]*n # Where is the queen in column x
self.row = [0]*n # Is row[y] safe?
self.up = [0] * (2*n-1) # Is upward diagonal[x-y] safe?
self.down = [0] * (2*n-1) # Is downward diagonal[x+y] safe?
self.nfound = 0 # Instrumentation

def solve(self, x=0): # Recursive solver
for y in range(self.n):
if self.safe(x, y):
self.place(x, y)
if x+1 == self.n:
self.display()
else:
self.solve(x+1)
self.remove(x, y)

def safe(self, x, y):
return not self.row[y] and not self.up[x-y] and not self.down[x+y]

def place(self, x, y):
self.y[x] = y
self.row[y] = 1
self.up[x-y] = 1
self.down[x+y] = 1

def remove(self, x, y):
self.y[x] = None
self.row[y] = 0
self.up[x-y] = 0
self.down[x+y] = 0

silent = 0 # If set, count solutions only

def display(self):
self.nfound = self.nfound + 1
if self.silent:
return
print '+-' + '--'*self.n + '+'
for y in range(self.n-1, -1, -1):
print '|',
for x in range(self.n):
if self.y[x] == y:
print "Q",
else:
print ".",
print '|'
print '+-' + '--'*self.n + '+'

def main():
import sys
silent = 0
n = N
if sys.argv[1:2] == ['-n']:
silent = 1
del sys.argv[1]
if sys.argv[1:]:
n = int(sys.argv[1])
q = Queens(n)
q.silent = silent
q.solve()
print "Found", q.nfound, "solutions."

if __name__ == "__main__":
main()



From python-dev@python.org Fri Nov 17 18:04:09 2000
From: python-dev@python.org (Fred L. Drake)
Date: Fri, 17 Nov 2000 10:04:09 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib libhttplib.tex,1.21,1.22
Message-ID: <200011171804.KAA22174@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv22137/lib

Modified Files:
libhttplib.tex
Log Message:

Fixed typos and bug in the second example, reported by Scott Schram
<schram@users.sourceforge.net>.

This closes bug #122236.


Index: libhttplib.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/libhttplib.tex,v
retrieving revision 1.21
retrieving revision 1.22
diff -C2 -r1.21 -r1.22
*** libhttplib.tex 2000/06/28 22:09:20 1.21
--- libhttplib.tex 2000/11/17 18:04:03 1.22
***************
*** 138,148 ****
h = httplib.HTTP("www.musi-cal.com:80")
h.putrequest("POST", "/cgi-bin/query")
h.putheader("Content-length", "%d" % len(params))
h.putheader('Accept', 'text/plain')
h.putheader('Host', 'www.musi-cal.com')
h.endheaders()
! >>> h.send(paramstring)
reply, msg, hdrs = h.getreply()
! >>> print errcode # should be 200
data = h.getfile().read() # get the raw HTML
\end{verbatim}
--- 138,149 ----
h = httplib.HTTP("www.musi-cal.com:80")
h.putrequest("POST", "/cgi-bin/query")
+ >>> h.putheader("Content-type", "application/x-www-form-urlencoded")
h.putheader("Content-length", "%d" % len(params))
h.putheader('Accept', 'text/plain')
h.putheader('Host', 'www.musi-cal.com')
h.endheaders()
! >>> h.send(params)
reply, msg, hdrs = h.getreply()
! >>> print reply # should be 200
data = h.getfile().read() # get the raw HTML
\end{verbatim}



From python-dev@python.org Fri Nov 17 18:20:56 2000
From: python-dev@python.org (Fred L. Drake)
Date: Fri, 17 Nov 2000 10:20:56 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/ext ext.tex,1.88,1.89
Message-ID: <200011171820.KAA24075@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/ext
In directory slayer.i.sourceforge.net:/tmp/cvs-serv23994/ext

Modified Files:
ext.tex
Log Message:

Corrected a number of typos reported by Gilles Civario
<gcivario@users.sourceforge.net>.

This closes bug #122562.


Index: ext.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/ext/ext.tex,v
retrieving revision 1.88
retrieving revision 1.89
diff -C2 -r1.88 -r1.89
*** ext.tex 2000/11/02 21:49:17 1.88
--- ext.tex 2000/11/17 18:20:33 1.89
***************
*** 736,740 ****
This variant on \samp{s\#} is used for encoding Unicode and objects
convertible to Unicode into a character buffer. It reads one C
! variable and stores into two C variables, the first one a pointer to
an encoding name string (\var{encoding}), the second a pointer to a
pointer to a character buffer (\var{**buffer}, the buffer used for
--- 736,740 ----
This variant on \samp{s\#} is used for encoding Unicode and objects
convertible to Unicode into a character buffer. It reads one C
! variable and stores into three C variables, the first one a pointer to
an encoding name string (\var{encoding}), the second a pointer to a
pointer to a character buffer (\var{**buffer}, the buffer used for
***************
*** 887,892 ****

\item[\samp{;}]
! The list of format units ends here; the string after the colon is used
! as the error message \emph{instead} of the default error message.
Clearly, \samp{:} and \samp{;} mutually exclude each other.

--- 887,892 ----

\item[\samp{;}]
! The list of format units ends here; the string after the semicolon is
! used as the error message \emph{instead} of the default error message.
Clearly, \samp{:} and \samp{;} mutually exclude each other.

***************
*** 1101,1113 ****
Unicode object. If the Unicode buffer pointer is \NULL, the length
is ignored and \code{None} is returned.
-
- \item[\samp{u} (Unicode string) {[Py_UNICODE *]}]
- Convert a null-terminated buffer of Unicode (UCS-2) data to a Python Unicode
- object. If the Unicode buffer pointer is \NULL{}, \code{None} is returned.
-
- \item[\samp{u\#} (Unicode string) {[Py_UNICODE *, int]}]
- Convert a Unicode (UCS-2) data buffer and its length to a Python Unicode
- object. If the Unicode buffer pointer is \NULL{}, the length is ignored and
- \code{None} is returned.

\item[\samp{i} (integer) {[int]}]
--- 1101,1104 ----



From python-dev@python.org Fri Nov 17 19:05:14 2000
From: python-dev@python.org (Fred L. Drake)
Date: Fri, 17 Nov 2000 11:05:14 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/ref ref2.tex,1.19,1.20
Message-ID: <200011171905.LAA31784@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/ref
In directory slayer.i.sourceforge.net:/tmp/cvs-serv31740/ref

Modified Files:
ref2.tex
Log Message:

Note that readframes() returns data in linear format, even if the original
is encoded in u-LAW format. Based on suggestion from Anthony Baxter
<anthony_baxter@users.sourceforge.net>.

This closes bug #122273.


Index: ref2.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/ref/ref2.tex,v
retrieving revision 1.19
retrieving revision 1.20
diff -C2 -r1.19 -r1.20
*** ref2.tex 2000/08/24 20:06:04 1.19
--- ref2.tex 2000/11/17 19:05:11 1.20
***************
*** 396,399 ****
--- 396,405 ----
(even mixing raw strings and triple quoted strings).

+
+ \subsection{Unicode literals \label{unicode}}
+
+ XXX explain more here...
+
+
\subsection{Numeric literals\label{numbers}}




From python-dev@python.org Fri Nov 17 19:05:14 2000
From: python-dev@python.org (Fred L. Drake)
Date: Fri, 17 Nov 2000 11:05:14 -0800
Subject: [Python-checkins] CVS: python/dist/src/Doc/lib liblocale.tex,1.18,1.19 libsunau.tex,1.3,1.4
Message-ID: <200011171905.LAA31780@slayer.i.sourceforge.net>

Update of /cvsroot/python/python/dist/src/Doc/lib
In directory slayer.i.sourceforge.net:/tmp/cvs-serv31740/lib

Modified Files:
liblocale.tex libsunau.tex
Log Message:

Note that readframes() returns data in linear format, even if the original
is encoded in u-LAW format. Based on suggestion from Anthony Baxter
<anthony_baxter@users.sourceforge.net>.

This closes bug #122273.


Index: liblocale.tex
==================================================================RCS file: /cvsroot/python/python/dist/src/Doc/lib/liblocale.tex,v
retrieving revision 1.18
retrieving revision 1.19
diff -C2 -r1.18 -r1.19
*** liblocale.tex 2000/10/25 20:59:52 1.18
--- liblocale.tex 2000/11/17 19:05:11 1.19
***************
*** 62,65 ****
--- 62,99 ----
This dictionary has the following strings as keys:

+ \begin{tableiii}{l|l|l}{code}{Key}{Category}{Meaning}
+ \lineiii{'decimal_point'}{\constant{LC_NUMERIC}}
+ {Decimal point character.}
+ \lineiii{'grouping'}{\constant{LC_NUMERIC}}
+ {Sequence of numbers specifying which relative positions
+ the \code{'thousands_sep'} is expected. If the sequence is
+ terminated with \constant{CHAR_MAX}, no further grouping
+ is performed. If the sequence terminates with a \code{0},
+ the last group size is repeatedly used.}
+ \lineiii{'thousands_sep'}{\constant{LC_NUMERIC}}
+ {Character used between groups.}\hline
+ \lineiii{'int_curr_symbol'}{\constant{LC_MONETARY}}
+ {International currency symbol.}
+ \lineiii{'currency_symbol'}{\constant{LC_MONETARY