]> granicus.if.org Git - python/log
python
23 years agoexperimental UCS-4 support: made compare a bit more robust, in case
Fredrik Lundh [Tue, 26 Jun 2001 16:39:36 +0000 (16:39 +0000)]
experimental UCS-4 support: made compare a bit more robust, in case
sizeof(Py_UNICODE) >= sizeof(long).  also changed surrogate expansion
to work if sizeof(Py_UNICODE) > 2.

23 years agoexperimental UCS-4 support: don't assume that MS_WIN32 implies
Fredrik Lundh [Tue, 26 Jun 2001 15:11:00 +0000 (15:11 +0000)]
experimental UCS-4 support: don't assume that MS_WIN32 implies
HAVE_USABLE_WCHAR_T

23 years agoAdded a note about recompiling OSAm before distributing.
Jack Jansen [Tue, 26 Jun 2001 08:06:59 +0000 (08:06 +0000)]
Added a note about recompiling OSAm before distributing.

24 years agoFixed typo in doc string.
Just van Rossum [Tue, 26 Jun 2001 06:57:12 +0000 (06:57 +0000)]
Fixed typo in doc string.

24 years agoFixed bug that prevented shared libs that are submodules of a
Just van Rossum [Tue, 26 Jun 2001 06:54:33 +0000 (06:54 +0000)]
Fixed bug that prevented shared libs that are submodules of a
package to be loaded from a PYD resource.

24 years agoSF bug #436207: "if 0: yield x" is ignored.
Tim Peters [Tue, 26 Jun 2001 03:36:28 +0000 (03:36 +0000)]
SF bug #436207:  "if 0: yield x" is ignored.
Not anymore <wink>.  Pure hack.  Doesn't fix any other "if 0:" glitches.

24 years agoTeach the types module about generators. Thanks to James Althoff on the
Tim Peters [Mon, 25 Jun 2001 19:46:25 +0000 (19:46 +0000)]
Teach the types module about generators.  Thanks to James Althoff on the
Iterators list for bringing it up!

24 years agoReturn self.trace_dispatch from dispatch_return() to enable stepping through generato...
Just van Rossum [Mon, 25 Jun 2001 18:01:24 +0000 (18:01 +0000)]
Return self.trace_dispatch from dispatch_return() to enable stepping through generators. (An alternative would be to create a new "yield" debugger event, but that involves many more changes, and might break Bdb subclasses.)

24 years agoUpdated link to zlib's home page.
Fred Drake [Mon, 25 Jun 2001 15:30:13 +0000 (15:30 +0000)]
Updated link to zlib's home page.

24 years agoWaitNextEvent short vs. unsigned short fix.
Jack Jansen [Mon, 25 Jun 2001 08:48:05 +0000 (08:48 +0000)]
WaitNextEvent short vs. unsigned short fix.

24 years agoInitial revision
Steven M. Gava [Mon, 25 Jun 2001 07:23:57 +0000 (07:23 +0000)]
Initial revision

24 years agoRemove const-ness in inet_pton declaration.
Martin v. Löwis [Mon, 25 Jun 2001 06:38:03 +0000 (06:38 +0000)]
Remove const-ness in inet_pton declaration.

24 years agoReplace snprintf with sprintf.
Martin v. Löwis [Mon, 25 Jun 2001 06:37:02 +0000 (06:37 +0000)]
Replace snprintf with sprintf.

24 years agoRepair indentation in comment.
Tim Peters [Mon, 25 Jun 2001 01:30:12 +0000 (01:30 +0000)]
Repair indentation in comment.
Add a temporary driver to help track down remaining leak(s).

24 years agoFix typos in inet_pton/inet_ntop.
Martin v. Löwis [Sun, 24 Jun 2001 21:35:43 +0000 (21:35 +0000)]
Fix typos in inet_pton/inet_ntop.

24 years agoProvide a definition for offsetof.
Martin v. Löwis [Sun, 24 Jun 2001 21:28:42 +0000 (21:28 +0000)]
Provide a definition for offsetof.

24 years agoEmulate inet_{pton,ntop} on systems that don't provide it.
Martin v. Löwis [Sun, 24 Jun 2001 21:18:26 +0000 (21:18 +0000)]
Emulate inet_{pton,ntop} on systems that don't provide it.

24 years agoMove USE_TOOLBOX_OBJECT_GLUE into acconfig.h.
Martin v. Löwis [Sun, 24 Jun 2001 20:59:45 +0000 (20:59 +0000)]
Move USE_TOOLBOX_OBJECT_GLUE into acconfig.h.

24 years agoChanged some comments. Removed the caution about clearing globs, since
Tim Peters [Sun, 24 Jun 2001 20:24:16 +0000 (20:24 +0000)]
Changed some comments.  Removed the caution about clearing globs, since
clearing a shallow copy _run_examples() makes itself can't hurt anything.

24 years agoClear the copy of the globs dict after running examples. This helps to
Tim Peters [Sun, 24 Jun 2001 20:02:47 +0000 (20:02 +0000)]
Clear the copy of the globs dict after running examples.  This helps to
break cycles, which are a special problem when running generator tests
that provoke exceptions by invoking the .next() method of a named
generator-iterator:  then the iterator is named in globs, and the
iterator's frame gets a tracekback object pointing back to globs, and
gc doesn't chase these types so the cycle leaks.

Also changed _run_examples() to make a copy of globs itself, so its
callers (direct and indirect) don't have to (and changed the callers
to stop making their own copies); *that* much is a change I've been
meaning to make for a long time (it's more robust the new way).

Here's a way to provoke the symptom without doctest; it leaks at a
prodigious rate; if the last two "source" lines are replaced with
    g().next()
the iterator isn't named and then there's no leak:

source = """\
def g():
    yield 1/0

k = g()
k.next()
"""

code = compile(source, "<source>", "exec")

def f(globs):
    try:
        exec code in globs
    except ZeroDivisionError:
        pass

while 1:
    f(globals().copy())

After this change, running test_generators in an infinite loop still leaks,
but reduced from a flood to a trickle.

24 years agodoctest systematically leaked memory when handling an exception in an
Tim Peters [Sun, 24 Jun 2001 18:59:01 +0000 (18:59 +0000)]
doctest systematically leaked memory when handling an exception in an
example (an obvious trackback cycle).  Repaired.
Bugfix candidate.

24 years agoAdded a "generate k-combinations of a list" example posted to c.l.py.
Tim Peters [Sun, 24 Jun 2001 10:14:27 +0000 (10:14 +0000)]
Added a "generate k-combinations of a list" example posted to c.l.py.

24 years agoNew tests to provoke SyntaxErrors unique to generators. Minor fiddling
Tim Peters [Sun, 24 Jun 2001 07:10:02 +0000 (07:10 +0000)]
New tests to provoke SyntaxErrors unique to generators.  Minor fiddling
of other tests.

24 years agodoctest doesn't handle intentional SyntaxError exceptions gracefully,
Tim Peters [Sun, 24 Jun 2001 06:46:58 +0000 (06:46 +0000)]
doctest doesn't handle intentional SyntaxError exceptions gracefully,
because it picks up the first line of traceback.format_exception_only()
instead of the last line.  Pick up the last line instead!

24 years agoAnother variant of the 2-3-5 test, mixing generators with a LazyList class.
Tim Peters [Sun, 24 Jun 2001 05:47:06 +0000 (05:47 +0000)]
Another variant of the 2-3-5 test, mixing generators with a LazyList class.
Good news:  Some of this stuff is pretty sophisticated (read nuts), and
I haven't bumped into a bug yet.
Bad news:  If I run the doctest in an infinite loop, memory is clearly
leaking.

24 years agoPure brute-force hackery to allow Python to build on Windows again,
Tim Peters [Sun, 24 Jun 2001 05:08:52 +0000 (05:08 +0000)]
Pure brute-force hackery to allow Python to build on Windows again,
because I need to make progress and don't have time now to think about
whatever it is the new code is trying to accomplish.

24 years agoMore tests.
Tim Peters [Sun, 24 Jun 2001 03:44:52 +0000 (03:44 +0000)]
More tests.

24 years agoAdd a recursive Sieve of Eratosthenes prime generator. Not practical,
Tim Peters [Sat, 23 Jun 2001 21:01:47 +0000 (21:01 +0000)]
Add a recursive Sieve of Eratosthenes prime generator.  Not practical,
but it's a heck of a good generator exerciser (think about it <wink>).

24 years agoAdd all the examples from PEP 255, and a few email examples.
Tim Peters [Sat, 23 Jun 2001 20:45:43 +0000 (20:45 +0000)]
Add all the examples from PEP 255, and a few email examples.

24 years agoNew std test for generators, initially populated with doctests NeilS put
Tim Peters [Sat, 23 Jun 2001 20:27:04 +0000 (20:27 +0000)]
New std test for generators, initially populated with doctests NeilS put
together.

24 years agoProperly use &&. Closes bug #434988.
Martin v. Löwis [Sat, 23 Jun 2001 19:58:46 +0000 (19:58 +0000)]
Properly use &&. Closes bug #434988.

24 years agoProperly use &&. Closes bug #434989.
Martin v. Löwis [Sat, 23 Jun 2001 19:55:38 +0000 (19:55 +0000)]
Properly use &&. Closes bug #434989.

24 years agoPatch #401196: Configuration machinery for IPv6.
Martin v. Löwis [Sat, 23 Jun 2001 16:30:13 +0000 (16:30 +0000)]
Patch #401196: Configuration machinery for IPv6.
Contributed by Jun-ichiro "itojun" Hagino. get{addr,name}info emulation
code taken from WIDE.

24 years agoFix typo
Andrew M. Kuchling [Sat, 23 Jun 2001 16:26:44 +0000 (16:26 +0000)]
Fix typo

24 years agoCorrect erroneous description of precmd.
Eric S. Raymond [Sat, 23 Jun 2001 14:42:43 +0000 (14:42 +0000)]
Correct erroneous description of precmd.

24 years agoChange the semantics of "return" in generators, as discussed on the
Tim Peters [Sat, 23 Jun 2001 06:19:16 +0000 (06:19 +0000)]
Change the semantics of "return" in generators, as discussed on the
Iterators list and Python-Dev; e.g., these all pass now:

def g1():
    try:
        return
    except:
        yield 1
assert list(g1()) == []

def g2():
    try:
        return
    finally:
        yield 1
assert list(g2()) == [1]

def g3():
    for i in range(3):
        yield None
    yield None
assert list(g3()) == [None] * 4

compile.c:  compile_funcdef and com_return_stmt:  Just van Rossum's patch
to compile the same code for "return" regardless of function type (this
goes back to the previous scheme of returning Py_None).

ceval.c:  gen_iternext:  take a return (but not a yield) of Py_None as
meaning the generator is exhausted.

24 years agoRemove some bogus trailing whitespace.
Fred Drake [Sat, 23 Jun 2001 06:16:52 +0000 (06:16 +0000)]
Remove some bogus trailing whitespace.

24 years agoFix minor markup nits.
Fred Drake [Sat, 23 Jun 2001 06:06:52 +0000 (06:06 +0000)]
Fix minor markup nits.

24 years agoUse a named reference to another chapter instead of hard coding the
Fred Drake [Sat, 23 Jun 2001 06:06:21 +0000 (06:06 +0000)]
Use a named reference to another chapter instead of hard coding the
chapter number.  This also makes the reference a hyperlink in the HTML
version.

24 years agogen_iternext(): Don't assume that the current thread state's frame is
Tim Peters [Sat, 23 Jun 2001 05:47:56 +0000 (05:47 +0000)]
gen_iternext():  Don't assume that the current thread state's frame is
not NULL.  I don't think it can be NULL from Python code, but if using
generators via the C API I expect a NULL frame is possible.

24 years agoFix a very minor (but annoying when looking for things!) markup nit.
Fred Drake [Sat, 23 Jun 2001 05:27:20 +0000 (05:27 +0000)]
Fix a very minor (but annoying when looking for things!) markup nit.

24 years agoPyFrameObject: rename f_stackbottom to f_stacktop, since it points to
Tim Peters [Sat, 23 Jun 2001 05:26:56 +0000 (05:26 +0000)]
PyFrameObject:  rename f_stackbottom to f_stacktop, since it points to
the next free valuestack slot, not to the base (in America, stacks push
and pop at the top -- they mutate at the bottom in Australia <winK>).
eval_frame():  assert that f_stacktop isn't NULL upon entry.
frame_delloc():  avoid ordered pointer comparisons involving f_stacktop
when f_stacktop is NULL.

24 years agoAdd "yeild" to the list of keywords.
Fred Drake [Sat, 23 Jun 2001 05:26:52 +0000 (05:26 +0000)]
Add "yeild" to the list of keywords.

Fix a very minor (but annoying when looking for things!) markup nit.

24 years agoConsistently use semi-colons after the last property for each selector.
Fred Drake [Sat, 23 Jun 2001 04:53:43 +0000 (04:53 +0000)]
Consistently use semi-colons after the last property for each selector.

24 years agoGive the pattern used to pick out a source anchor a more specific pattern.
Fred Drake [Sat, 23 Jun 2001 04:35:09 +0000 (04:35 +0000)]
Give the pattern used to pick out a source anchor a more specific pattern.

24 years agoAdded several names.
Fred Drake [Sat, 23 Jun 2001 03:17:02 +0000 (03:17 +0000)]
Added several names.

24 years agoContributed updates from Harald Hanche-Olsen, giving details of the branch
Fred Drake [Sat, 23 Jun 2001 03:16:29 +0000 (03:16 +0000)]
Contributed updates from Harald Hanche-Olsen, giving details of the branch
cuts for the complex math functions.  Includes a brief description of
what branch cuts are.

24 years agoAdded support for our new \infinity and \plusminus macros, and the
Fred Drake [Sat, 23 Jun 2001 03:13:30 +0000 (03:13 +0000)]
Added support for our new \infinity and \plusminus macros, and the
standard \textbar macro (not supported in many versions of LaTeX2HTML).

Added newline to error message.

24 years ago\infinity,
Fred Drake [Sat, 23 Jun 2001 03:11:45 +0000 (03:11 +0000)]
\infinity,
\plusminus:  New macros to allow us to avoid math mode for these symbols.

24 years agoMiscellaneous code cleanups.
Fred Drake [Sat, 23 Jun 2001 03:06:01 +0000 (03:06 +0000)]
Miscellaneous code cleanups.

Make sure we do not lose track of the build directory -- convert a user-
supplied directory to an absolute path.

24 years agoDisallow 'yield' in a 'try' block when there's a 'finally' clause.
Tim Peters [Sat, 23 Jun 2001 02:07:08 +0000 (02:07 +0000)]
Disallow 'yield' in a 'try' block when there's a 'finally' clause.
Derived from Thomas Wouters's patch on the Iterators list, but doesn't
try to read c->c_block[c->c_nblocks].

24 years agoRemove an extra tab character.
Fred Drake [Fri, 22 Jun 2001 18:36:07 +0000 (18:36 +0000)]
Remove an extra tab character.

24 years agoRe-organize a little, clean up some markup.
Fred Drake [Fri, 22 Jun 2001 18:21:53 +0000 (18:21 +0000)]
Re-organize a little, clean up some markup.

Added some comments about sys.exit(), SystemExit, and preventing restricted
code from exiting the interpreter.

This closes SF bug #434743.

24 years agoAdd sha and _sre to the list of allowed built-in modules.
Fred Drake [Fri, 22 Jun 2001 18:19:16 +0000 (18:19 +0000)]
Add sha and _sre to the list of allowed built-in modules.

24 years agoCorrected an error in the information on supporting weak references in
Fred Drake [Fri, 22 Jun 2001 17:20:29 +0000 (17:20 +0000)]
Corrected an error in the information on supporting weak references in
extension types (the docs reflected a development version of the API).

This closes SF bug #435066.

24 years agoAdjust to understand use of either single- or double-quotes to quote
Fred Drake [Fri, 22 Jun 2001 17:11:30 +0000 (17:11 +0000)]
Adjust to understand use of either single- or double-quotes to quote
attribute values, and make the logic surrounding the platform
annotations just a little easier to read.  Also make the platform
notes appear in the generated page; they were supposed to, but did not.

24 years agoAdd the new texinputs/license.tex to the shared dependencies.
Fred Drake [Fri, 22 Jun 2001 17:07:02 +0000 (17:07 +0000)]
Add the new texinputs/license.tex to the shared dependencies.

24 years agoThis is a trivial command line utility to print MD5 checksums.
Guido van Rossum [Fri, 22 Jun 2001 16:05:48 +0000 (16:05 +0000)]
This is a trivial command line utility to print MD5 checksums.
I published it on the web as http://www.python.org/2.1/md5sum.py
so I thought I might as well check it in.

Works with Python 1.5.2 and later.

Works like the Linux tool ``mdfsum file ...'' except it doesn't take
any options or read stdin.

24 years agoFix & clean up the information about building Python with large file support
Fred Drake [Fri, 22 Jun 2001 16:01:20 +0000 (16:01 +0000)]
Fix & clean up the information about building Python with large file support
for Linux.

This closes SF bug #434975.

24 years agoChanged the order of the buttons for EasyDialogs.AskYesNoCancel() from the unusual...
Just van Rossum [Fri, 22 Jun 2001 15:09:56 +0000 (15:09 +0000)]
Changed the order of the buttons for EasyDialogs.AskYesNoCancel() from the unusual [cancel, no, yes] to the more standard [no, cancel, yes].

24 years agoRecord Windows build number for 2.0.1 final.
Tim Peters [Fri, 22 Jun 2001 02:06:04 +0000 (02:06 +0000)]
Record Windows build number for 2.0.1 final.

24 years agodon't blow up when the charno SyntaxError value is None
Just van Rossum [Thu, 21 Jun 2001 21:52:15 +0000 (21:52 +0000)]
don't blow up when the charno SyntaxError value is None

24 years agorepaired expandselection and uncomment breakage
Just van Rossum [Thu, 21 Jun 2001 17:51:17 +0000 (17:51 +0000)]
repaired expandselection and uncomment breakage

24 years agoAdded support for the gc module (!).
Just van Rossum [Thu, 21 Jun 2001 14:50:03 +0000 (14:50 +0000)]
Added support for the gc module (!).

24 years agoSomehow, under certain circumstances, config.h and rename1.h would pop back up.
Guido van Rossum [Thu, 21 Jun 2001 12:34:50 +0000 (12:34 +0000)]
Somehow, under certain circumstances, config.h and rename1.h would pop back up.
Try to see if 'cvs delete' fixes this.

24 years agoTeach the UNPACK_SEQUENCE opcode how to tease an iterable object into
Tim Peters [Thu, 21 Jun 2001 02:49:55 +0000 (02:49 +0000)]
Teach the UNPACK_SEQUENCE opcode how to tease an iterable object into
giving up the goods.
NEEDS DOC CHANGES

24 years agoTry to avoid creating reference cycles involving generators. Only keep a
Neil Schemenauer [Thu, 21 Jun 2001 02:41:10 +0000 (02:41 +0000)]
Try to avoid creating reference cycles involving generators.  Only keep a
reference to f_back when its really needed.  Do a little whitespace
normalization as well.  This whole file is a big war between tabs and spaces
but now is probably not the time to reindent everything.

24 years agoGot rid of a silly #if.
Jack Jansen [Wed, 20 Jun 2001 21:44:38 +0000 (21:44 +0000)]
Got rid of a silly #if.

24 years agoMove license information to a less annoying location in the document.
Fred Drake [Wed, 20 Jun 2001 21:39:12 +0000 (21:39 +0000)]
Move license information to a less annoying location in the document.

Add documentation for PyErr_SetFromErrnoWithFilename().

24 years agoUpdate to include the license information in a less annoying place.
Fred Drake [Wed, 20 Jun 2001 21:37:34 +0000 (21:37 +0000)]
Update to include the license information in a less annoying place.

24 years agoSeparate the copyright statements and license text; include some new
Fred Drake [Wed, 20 Jun 2001 21:34:35 +0000 (21:34 +0000)]
Separate the copyright statements and license text; include some new
comments regarding the history of Python licensing from Guido.

24 years agoSeparate the version number and release status into two separate values.
Fred Drake [Wed, 20 Jun 2001 21:33:13 +0000 (21:33 +0000)]
Separate the version number and release status into two separate values.

24 years agoUpdate to use the newly separated values $PACKAGE_VERSION and $RELEASE_INFO.
Fred Drake [Wed, 20 Jun 2001 21:31:36 +0000 (21:31 +0000)]
Update to use the newly separated values $PACKAGE_VERSION and $RELEASE_INFO.

Normalize all HTML attributes to be written as name="value" instead of
name='value'.

24 years agoDon't use extern when we mean staticforward (OSX gcc is picky about it).
Jack Jansen [Wed, 20 Jun 2001 21:31:28 +0000 (21:31 +0000)]
Don't use extern when we mean staticforward (OSX gcc is picky about it).
Blacklist SendControlMessage: it's signature has changed between Universal Headers 3.3 and 3.4.

24 years agoAdded support for new \setreleaseinfo macro.
Fred Drake [Wed, 20 Jun 2001 21:29:30 +0000 (21:29 +0000)]
Added support for new \setreleaseinfo macro.
Normalize all generated HTML so that attribute names come out as
name="value" instead of name='value'.
Changed the target of RFC links to point to the hypertext RFCs at
www.faqs.org instead of the plain text RFCs at www.ietf.org.

24 years ago{Is,Set}AntiAliasedTextEnabled don't exist on MacOS 8.5.5 and earlier. For now: cop...
Jack Jansen [Wed, 20 Jun 2001 21:29:19 +0000 (21:29 +0000)]
{Is,Set}AntiAliasedTextEnabled don't exist on MacOS 8.5.5 and earlier. For now: cop out and blacklist them.

24 years agoANSIfied function headers to shut up compiler warnings on OSX/Mach-o.
Jack Jansen [Wed, 20 Jun 2001 21:22:23 +0000 (21:22 +0000)]
ANSIfied function headers to shut up compiler warnings on OSX/Mach-o.

24 years agoAdded a const to shut up a compiler warning.
Jack Jansen [Wed, 20 Jun 2001 21:21:07 +0000 (21:21 +0000)]
Added a const to shut up a compiler warning.

24 years agoReversed the order of the checks for None or a Dialog where a Window is expected...
Jack Jansen [Wed, 20 Jun 2001 21:20:22 +0000 (21:20 +0000)]
Reversed the order of the checks for None or a Dialog where a Window is expected so it doesn't crash under OSX/Mach-o.

24 years agoAdd a little more support for describing version information. This
Fred Drake [Wed, 20 Jun 2001 21:17:09 +0000 (21:17 +0000)]
Add a little more support for describing version information.  This
is not pretty, but does what is needed.

24 years agoRemoved some unused routines under Carbon. They caused compile errors with UH34.
Jack Jansen [Wed, 20 Jun 2001 20:55:05 +0000 (20:55 +0000)]
Removed some unused routines under Carbon. They caused compile errors with UH34.

24 years agoAdapted to Universal Headers 3.4: new refcontype and use UPP names in stead of Proc...
Jack Jansen [Wed, 20 Jun 2001 20:53:38 +0000 (20:53 +0000)]
Adapted to Universal Headers 3.4: new refcontype and use UPP names in stead of Proc names for callback creation.

24 years agoAdapted for Universal Headers 3.4: refcon type has changed (sigh) and use modern...
Jack Jansen [Wed, 20 Jun 2001 20:50:19 +0000 (20:50 +0000)]
Adapted for Universal Headers 3.4: refcon type has changed (sigh) and use modern (UPP in stead of Proc) names for callback object creation.

24 years agoOverride bdb's canonic() method with a no-op: with bdb's version we couldn't edit...
Just van Rossum [Wed, 20 Jun 2001 19:57:55 +0000 (19:57 +0000)]
Override bdb's canonic() method with a no-op: with bdb's version we couldn't edit breakpoints in file-less ("Untitled" script windows). Besides, we did't need it as we always use full path names anyway.

24 years agowrite(): Karl Eichwalder points out that the #, flag comments should
Barry Warsaw [Wed, 20 Jun 2001 19:41:40 +0000 (19:41 +0000)]
write(): Karl Eichwalder points out that the #, flag comments should
be outputted just before the msgid lines.

24 years agogen_iternext(): repair subtle refcount problem.
Tim Peters [Wed, 20 Jun 2001 06:57:32 +0000 (06:57 +0000)]
gen_iternext():  repair subtle refcount problem.
NeilS, please check!  This came from staring at your genbug.py, but I'm
not sure it plugs all possible holes.  Without this, I caught a
frameobject refcount going negative, and it was also the cause (in debug
build) of _Py_ForgetReference's attempt to forget an object with already-
NULL _ob_prev and _ob_next pointers -- although I'm still not entirely
sure how!  Part of the difficulty is that frameobjects are stored on a
free list that gets recycled very quickly, so if there's a stray pointer
to one of them it never looks like an insane frameobject (never goes
trough the free() mangling MS debug forces, etc).

24 years agoRemove unused code.
Neil Schemenauer [Wed, 20 Jun 2001 00:39:28 +0000 (00:39 +0000)]
Remove unused code.

24 years agoAdd a bunch of sample strings to test soft line breaks of varying end
Barry Warsaw [Tue, 19 Jun 2001 22:48:42 +0000 (22:48 +0000)]
Add a bunch of sample strings to test soft line breaks of varying end
cases.

24 years agoencode(): Fixed the handling of soft line breaks for lines over 76
Barry Warsaw [Tue, 19 Jun 2001 22:48:10 +0000 (22:48 +0000)]
encode(): Fixed the handling of soft line breaks for lines over 76
characters in length.  Remember that when calculating the soft breaks,
the trailing `=' sign counts against the max length!

24 years agomade 7-bit-clean.
Just van Rossum [Tue, 19 Jun 2001 21:38:42 +0000 (21:38 +0000)]
made 7-bit-clean.

24 years agoSome long overdue maintainance. Made all IDE sources 7-bit-clean, to avoid any furthe...
Just van Rossum [Tue, 19 Jun 2001 21:37:33 +0000 (21:37 +0000)]
Some long overdue maintainance. Made all IDE sources 7-bit-clean, to avoid any further encoding conversion troubles.

24 years ago- _filename_to_abs() didn't cater for .. components in the pathname. Fixed.
Jack Jansen [Tue, 19 Jun 2001 21:23:11 +0000 (21:23 +0000)]
- _filename_to_abs() didn't cater for .. components in the pathname. Fixed.
- compile() didn't return a (empty) list of objects. Fixed.
- the various _fix_xxx_args() methods weren't called (are they new or did I overlook them?). Fixed.

24 years agoThe test used int(time.time()) to get a random number, but this doesn't work on the...
Jack Jansen [Tue, 19 Jun 2001 20:20:05 +0000 (20:20 +0000)]
The test used int(time.time()) to get a random number, but this doesn't work on the mac (where times are bigger than ints). Changed to int(time.time()%1000000).

24 years agoAn import MacOS was missing after the code-rearranging. Added.
Jack Jansen [Tue, 19 Jun 2001 20:11:36 +0000 (20:11 +0000)]
An import MacOS was missing after the code-rearranging. Added.

24 years agoTest by Martin v. Loewis for the new UTF-16 codec handling of BOM
Marc-André Lemburg [Tue, 19 Jun 2001 20:09:28 +0000 (20:09 +0000)]
Test by Martin v. Loewis for the new UTF-16 codec handling of BOM
marks.

24 years agoThis patch by Martin v. Loewis changes the UTF-16 codec to only
Marc-André Lemburg [Tue, 19 Jun 2001 20:07:51 +0000 (20:07 +0000)]
This patch by Martin v. Loewis changes the UTF-16 codec to only
write a BOM at the start of the stream and also to only read it as
BOM at the start of a stream.

Subsequent reading/writing of BOMs will read/write the BOM as ZWNBSP
character. This is in sync with the Unicode specifications.

Note that UTF-16 files will now *have* to start with a BOM mark
in order to be readable by the codec.

24 years agowrite(): It's been generally agreed on the i18n-sig that the docstring
Barry Warsaw [Tue, 19 Jun 2001 19:54:19 +0000 (19:54 +0000)]
write(): It's been generally agreed on the i18n-sig that the docstring
marker should be output as a #, flag, e.g. "#, docstring".

24 years agoDocument the new encodestring() and decodestring() functions. Also,
Barry Warsaw [Tue, 19 Jun 2001 19:44:42 +0000 (19:44 +0000)]
Document the new encodestring() and decodestring() functions.  Also,
add some description of what the quotetabs argument does for the
encode*() functions.  Finally, add a "see also" pointing to the base64
module.

24 years agoFixed -D emulation for symbols with a value, as specified with the define_macros...
Just van Rossum [Tue, 19 Jun 2001 19:44:02 +0000 (19:44 +0000)]
Fixed -D emulation for symbols with a value, as specified with the define_macros Extension argument.

24 years agoA unittest-based test for the quopri module.
Barry Warsaw [Tue, 19 Jun 2001 19:08:13 +0000 (19:08 +0000)]
A unittest-based test for the quopri module.