]> granicus.if.org Git - python/log
python
23 years agoaudioop_ratecv() again: settle for a sloppier upper bound that's less
Tim Peters [Fri, 7 Dec 2001 00:37:39 +0000 (00:37 +0000)]
audioop_ratecv() again:  settle for a sloppier upper bound that's less
obnoxious to compute and easier to explain.  No compromise on safety.

23 years agos/it/if/ in descriptions of spawn mode argument.
Tim Peters [Thu, 6 Dec 2001 23:37:17 +0000 (23:37 +0000)]
s/it/if/ in descriptions of spawn mode argument.

23 years agoFor ratecv, document that None should be the initial state argument (when
Tim Peters [Thu, 6 Dec 2001 23:16:09 +0000 (23:16 +0000)]
For ratecv, document that None should be the initial state argument (when
I was squashing spurious overflows in the implementation, I got hung up
on this point).

23 years agoVisious hackery to solve a build-control problem related to our use of
Fred Drake [Thu, 6 Dec 2001 22:59:54 +0000 (22:59 +0000)]
Visious hackery to solve a build-control problem related to our use of
distutils for the library modules built as shared objects.  A better solution
appears possible, but with the threat that the distutils becomes more
magical ("complex").
This closes SF bug #458343.

23 years agoDon't fail on importing things with undefined references. Unfortunately we
Jack Jansen [Thu, 6 Dec 2001 22:58:56 +0000 (22:58 +0000)]
Don't fail on importing things with undefined references. Unfortunately we
still fail on importing modules that link with libraries that fail
their initialization code (such as windowing libraries when we don't have
access to the window server) and that is what I really wanted to fix.

23 years agoSilly mistake in build directory extension fix.
Jack Jansen [Thu, 6 Dec 2001 22:36:17 +0000 (22:36 +0000)]
Silly mistake in build directory extension fix.

23 years agoWrap some long lines.
Fred Drake [Thu, 6 Dec 2001 22:24:47 +0000 (22:24 +0000)]
Wrap some long lines.

23 years agoCleaned up Mac OS X section to the current state of affairs.
Jack Jansen [Thu, 6 Dec 2001 21:49:02 +0000 (21:49 +0000)]
Cleaned up Mac OS X section to the current state of affairs.

23 years agoTest wether we are building on a case-insensitive filesystem (such
Jack Jansen [Thu, 6 Dec 2001 21:47:20 +0000 (21:47 +0000)]
Test wether we are building on a case-insensitive filesystem (such
as OSX HFS+) and if so add an extension to the python executable, but
only in the build directory, not on the installed python.

23 years ago[Bug #475009] Tighten the pattern for the first line, so we don't
Andrew M. Kuchling [Thu, 6 Dec 2001 21:29:28 +0000 (21:29 +0000)]
[Bug #475009] Tighten the pattern for the first line, so we don't
   adjust it when a versioned interpreter is supplied (#!.../python2 ...)

23 years agoFix for SF bug #489671 (Neil Norwitz): memory leak in test_richcmp.
Guido van Rossum [Thu, 6 Dec 2001 21:28:18 +0000 (21:28 +0000)]
Fix for SF bug #489671 (Neil Norwitz): memory leak in test_richcmp.

Had nothing to do with rich comparisons -- some stack cleanup code was
lost as a result of merging in Neil Schemenauer's generators patch.
Reinserted the stack cleanup code, skipping it when yielding.

23 years agosys.platform is now "darwin" without digits appended.
Jack Jansen [Thu, 6 Dec 2001 21:14:00 +0000 (21:14 +0000)]
sys.platform is now "darwin" without digits appended.

23 years agoWhitespace normalization.
Fred Drake [Thu, 6 Dec 2001 21:01:19 +0000 (21:01 +0000)]
Whitespace normalization.

23 years agoWhitespace normalization.
Fred Drake [Thu, 6 Dec 2001 20:51:35 +0000 (20:51 +0000)]
Whitespace normalization.

23 years agoUse a version number of 0.0.0 instead of ???. The latter leads to
Thomas Heller [Thu, 6 Dec 2001 20:44:19 +0000 (20:44 +0000)]
Use a version number of 0.0.0 instead of ???.  The latter leads to
invalid filenames on Windows when building without specifying a
version number in the setup script.

See also
http://mail.python.org/pipermail/distutils-sig/2001-November/002656.html

Bugfix candidate.

23 years agoDocument that PyString_FromString() cannot take NULL as a parameter.
Fred Drake [Thu, 6 Dec 2001 20:38:15 +0000 (20:38 +0000)]
Document that PyString_FromString() cannot take NULL as a parameter.
This closes SF bug #489872.

23 years agoPyString_FromString: this requires its argument be non-NULL, but doesn't
Tim Peters [Thu, 6 Dec 2001 20:29:32 +0000 (20:29 +0000)]
PyString_FromString:  this requires its argument be non-NULL, but doesn't
check it.  Added an assert() to that effect.

23 years agoFix for #489669 (Neil Norwitz): memory leak in test_descr (unicode).
Guido van Rossum [Thu, 6 Dec 2001 20:03:56 +0000 (20:03 +0000)]
Fix for #489669 (Neil Norwitz): memory leak in test_descr (unicode).

This is best reproduced by

  while 1:
      class U(unicode):
          pass
      U(u"xxxxxx")

The unicode_dealloc() code wasn't properly freeing the str and defenc
fields of the Unicode object when freeing a subtype instance.  Fixed
this by a subtle refactoring that actually reduces the amount of code
slightly.

23 years agoUndefine addrinfo.h constants if the system header defined them.
Martin v. Löwis [Thu, 6 Dec 2001 19:04:35 +0000 (19:04 +0000)]
Undefine addrinfo.h constants if the system header defined them.
Fixes #486099.

23 years agoAttribute nodes did not always get their ownerDocument and ownerElement
Fred Drake [Thu, 6 Dec 2001 18:27:48 +0000 (18:27 +0000)]
Attribute nodes did not always get their ownerDocument and ownerElement
properly set.  This fixes that.

23 years agoBe more careful about accessing attributes of the parent: if Tk has not been
Fred Drake [Thu, 6 Dec 2001 16:51:41 +0000 (16:51 +0000)]
Be more careful about accessing attributes of the parent: if Tk has not been
initialized, this will be None, but the functions will still work (there will
simply be a bogus parent on the screen).  Allowing the parent to be None
is useful when testing the functions from an interactive interpreter.

Add an optional keyword paramter "show" to the _QueryString class; when given
it is used to set the -show option to the entry widget.  This allows passing
show="*" or the like to askstring(), making it useful for requesting
passwords/passphrases from the user.
This closes SF bug #438517.

Changed a docstring to be less font-lock-hostile.

23 years ago[Bug #459270] Fix incorrect filename for system-wide config file
Andrew M. Kuchling [Thu, 6 Dec 2001 16:34:53 +0000 (16:34 +0000)]
[Bug #459270] Fix incorrect filename for system-wide config file

23 years ago[Bug #459270] Fix incorrect docstring
Andrew M. Kuchling [Thu, 6 Dec 2001 16:32:05 +0000 (16:32 +0000)]
[Bug #459270] Fix incorrect docstring

23 years ago[Bug #480882] Remove now-pointless check for existence for _curses_panel.c;
Andrew M. Kuchling [Thu, 6 Dec 2001 15:57:16 +0000 (15:57 +0000)]
[Bug #480882] Remove now-pointless check for existence for _curses_panel.c;
Bugfix candidate.

23 years agoFix memory leak in dict_to_map(), SF bug [ #485152 ] memory leak in test_scope.
Jeremy Hylton [Thu, 6 Dec 2001 15:48:16 +0000 (15:48 +0000)]
Fix memory leak in dict_to_map(), SF bug [ #485152 ] memory leak in test_scope.

PyCell_Set() incremenets the reference count, so the earlier XINCREF
causes a leak.

Also make a number of small performance improvements to the code on
the assumption that most of the time variables are not rebound across
a FastToLocals() / LocalsToFast() pair.

Replace uses of PyCell_Set() and PyCell_Get() with PyCell_SET() and
PyCell_GET(), since the frame is guaranteed to contain cells.

23 years agoLittle stuff.
Jeremy Hylton [Thu, 6 Dec 2001 15:18:48 +0000 (15:18 +0000)]
Little stuff.

Add a missing DECREF in an obscure corner.  If the str() or repr() of
an object passed to a string interpolation -- e.g. "%s" % obj --
returns a non-string, the returned object was leaked.

Repair an indentation glitch.

Replace a bunch of PyString_AsString() calls (and their ilk) with
macros.

23 years agoFix [ #489673 ] memory leak in test_symtable: Free the st_future slot.
Jeremy Hylton [Thu, 6 Dec 2001 14:34:58 +0000 (14:34 +0000)]
Fix [ #489673 ] memory leak in test_symtable: Free the st_future slot.

The st_future slot of the symtable is not freed by PySymtable_Free()
because it is shared by the symtable and compiling structs in
compiel.c.  Since it is shared, it is explicitly deallocated when the
compiling struct is freed.

23 years agoFix a typo (probably caused by autocompletion <blush>) that caused a
Guido van Rossum [Thu, 6 Dec 2001 14:09:56 +0000 (14:09 +0000)]
Fix a typo (probably caused by autocompletion <blush>) that caused a
leak when a class defined a __metaclass__.  This fixes the problem
reported on python-dev by Ping; I dunno if it's the same as SF bug
#489669 (since that mentions Unicode).

23 years agoSF bug #488514: -Qnew needs work
Tim Peters [Thu, 6 Dec 2001 06:23:26 +0000 (06:23 +0000)]
SF bug #488514: -Qnew needs work
Big Hammer to implement -Qnew as PEP 238 says it should work (a global
option affecting all instances of "/").

pydebug.h, main.c, pythonrun.c:  define a private _Py_QnewFlag flag, true
iff -Qnew is passed on the command line.  This should go away (as the
comments say) when true division becomes The Rule.  This is
deliberately not exposed to runtime inspection or modification:  it's
a one-way one-shot switch to pretend you're using Python 3.

ceval.c:  when _Py_QnewFlag is set, treat BINARY_DIVIDE as
BINARY_TRUE_DIVIDE.

test_{descr, generators, zipfile}.py:  fiddle so these pass under
-Qnew too.  This was just a matter of s!/!//! in test_generators and
test_zipfile.  test_descr was trickier, as testbinop() is passed
assumptions that "/" is the same as calling a "__div__" method; put
a temporary hack there to call "__truediv__" instead when the method
name is "__div__" and 1/2 evaluates to 0.5.

Three standard tests still fail under -Qnew (on Windows; somebody
please try the Linux tests with -Qnew too!  Linux runs a whole bunch
of tests Windows doesn't):
    test_augassign
    test_class
    test_coercion
I can't stay awake longer to stare at this (be my guest).  Offhand
cures weren't obvious, nor was it even obvious that cures are possible
without major hackery.

Question:  when -Qnew is in effect, should calls to __div__ magically
change into calls to __truediv__?  See "major hackery" at tail end of
last paragraph <wink>.

23 years agoFix appendChild() and insertBefore() (and replaceChild() indirectly) when
Fred Drake [Thu, 6 Dec 2001 04:32:18 +0000 (04:32 +0000)]
Fix appendChild() and insertBefore() (and replaceChild() indirectly) when
the node being added is a fragment node.
This closes SF bug #487929.

23 years agoSF patch #489680 (David Abrahams): h2py uses nonexistent method splitfields()
Guido van Rossum [Thu, 6 Dec 2001 03:31:04 +0000 (03:31 +0000)]
SF patch #489680 (David Abrahams): h2py uses nonexistent method splitfields()

23 years agoWarning message about unfound file was missing trailing \n.
Guido van Rossum [Thu, 6 Dec 2001 03:28:17 +0000 (03:28 +0000)]
Warning message about unfound file was missing trailing \n.

23 years agoSF patch #489680 (David Abrahams): h2py uses nonexistent method splitfields()
Guido van Rossum [Thu, 6 Dec 2001 03:24:30 +0000 (03:24 +0000)]
SF patch #489680 (David Abrahams): h2py uses nonexistent method splitfields()

23 years agoThe previous checkin to clear __slots__ variables did a little bit of
Guido van Rossum [Thu, 6 Dec 2001 02:35:58 +0000 (02:35 +0000)]
The previous checkin to clear __slots__ variables did a little bit of
the work each time it found another base class.  All the work is
contiguous, so we might as well do it all at once at the end.

23 years agoReplace sprintf() with PyOS_snprintf().
Jack Jansen [Wed, 5 Dec 2001 23:27:58 +0000 (23:27 +0000)]
Replace sprintf() with PyOS_snprintf().

23 years agosys.platform on Mac OS X is now "darwin", without any version number appended.
Jack Jansen [Wed, 5 Dec 2001 23:27:32 +0000 (23:27 +0000)]
sys.platform on Mac OS X is now "darwin", without any version number appended.
This should probably go into NEWS (who's responsible for that?).

23 years agoLink more modules with weak import, and add CarbonAccessors.o to all relevant PowerPC...
Jack Jansen [Wed, 5 Dec 2001 22:46:23 +0000 (22:46 +0000)]
Link more modules with weak import, and add CarbonAccessors.o to all relevant PowerPC toolbox modules. This, in combination with recent IDE mods, makes the IDE work again under MacOS 8.1.

23 years agoFix SF bug #489581: __slots__ leak.
Guido van Rossum [Wed, 5 Dec 2001 22:45:48 +0000 (22:45 +0000)]
Fix SF bug #489581: __slots__ leak.

It was easier than I thought, assuming that no other things contribute
to the instance size besides slots -- a pretty good bet.  With a test
suite, no less!

23 years agoDefine NDEBUG if Py_DEBUG isn't defined.
Jack Jansen [Wed, 5 Dec 2001 22:44:45 +0000 (22:44 +0000)]
Define NDEBUG if Py_DEBUG isn't defined.

23 years agoRe-enabled debugging prints in poplib & documented the set_debuglevel()
Fred Drake [Wed, 5 Dec 2001 22:37:21 +0000 (22:37 +0000)]
Re-enabled debugging prints in poplib & documented the set_debuglevel()
method.
This closes SF patch #486079.

23 years agoaudioop_ratecv(): I left a potentially unsafe multiply unchecked
Tim Peters [Wed, 5 Dec 2001 22:30:21 +0000 (22:30 +0000)]
audioop_ratecv():  I left a potentially unsafe multiply unchecked
yesterday -- repair that.  Also renamed the silly size_times_nchannels
to bytes_per_frame.

23 years agoAdded a missing period at the end of an error message.
Fred Drake [Wed, 5 Dec 2001 22:27:47 +0000 (22:27 +0000)]
Added a missing period at the end of an error message.

23 years agoFix memory leak in the parser module: There were two leaks in
Fred Drake [Wed, 5 Dec 2001 22:10:44 +0000 (22:10 +0000)]
Fix memory leak in the parser module:  There were two leaks in
parser_tuple2st() and a failure to propogate an error in
build_node_children() (masking yet another leak, of course!).
This closes SF bug #485133 (confirmed by Insure++).

23 years agoasyncore.loop() description contributed by Skip Montanaro.
Fred Drake [Wed, 5 Dec 2001 21:37:50 +0000 (21:37 +0000)]
asyncore.loop() description contributed by Skip Montanaro.
This closes SF bug #489513.

23 years agoAt the PythonLabs meeting someone mentioned it would make Jim really
Guido van Rossum [Wed, 5 Dec 2001 19:46:42 +0000 (19:46 +0000)]
At the PythonLabs meeting someone mentioned it would make Jim really
happy if one could delete the __dict__ attribute of an instance.  I
love to make Jim happy, so here goes...

- New-style objects now support deleting their __dict__.  This is for
  all intents and purposes equivalent to assigning a brand new empty
  dictionary, but saves space if the object is not used further.

23 years agoSeparate the script portion from the library portion; everything that
Fred Drake [Wed, 5 Dec 2001 15:58:29 +0000 (15:58 +0000)]
Separate the script portion from the library portion; everything that
pertains to the script is now in the if __name__ == "__main__" block.
This is in response to a commenton python-dev from Neal Norwitz.

23 years agoAs of OS X 10.1.1 the version numbering scheme has changed. Convert all "darwin*...
Jack Jansen [Wed, 5 Dec 2001 15:54:29 +0000 (15:54 +0000)]
As of OS X 10.1.1 the version numbering scheme has changed. Convert all "darwin*" to "darwin" and use that for testing.

23 years agochanges to use new tabpages classes
Steven M. Gava [Wed, 5 Dec 2001 07:54:07 +0000 (07:54 +0000)]
changes to use new tabpages classes

23 years agoremove cruft from other project
Steven M. Gava [Wed, 5 Dec 2001 06:39:18 +0000 (06:39 +0000)]
remove cruft from other project

23 years agocleaner tabbed-page mini implementation through classes
Steven M. Gava [Wed, 5 Dec 2001 06:32:46 +0000 (06:32 +0000)]
cleaner tabbed-page mini implementation through classes

23 years agoSF bug 482574: audioop.ratecv crashes.
Tim Peters [Wed, 5 Dec 2001 06:05:07 +0000 (06:05 +0000)]
SF bug 482574:  audioop.ratecv crashes.
Bugfix candidate.
A numerically naive computation of output buffer size caused crashes
and spurious MemoryErrors for reasonable arguments.
audioop_ratecv():  Avoid spurious overflow by careful reworking of the
buffer size computations, triggering MemoryError if and only if the
final buffer size can't be represented in a C int (although
PyString_FromStringAndSize may legitimately raise MemoryError even if
it does fit in a C int).  All reasonable arguments should work as
intended now, and all unreasonable arguments should be cuaght.

23 years agoAdd a note to the description of the interaction between the softspace
Fred Drake [Wed, 5 Dec 2001 05:46:25 +0000 (05:46 +0000)]
Add a note to the description of the interaction between the softspace
attribute of file objects, the print statement, and other file operations.
This closes SF bug #484857.

Fix minor markup nits.

23 years agoAdded documentation of the sendall() method, and a note to the send() method
Fred Drake [Wed, 5 Dec 2001 05:25:59 +0000 (05:25 +0000)]
Added documentation of the sendall() method, and a note to the send() method
that it does not guarantee that all data is sent.
This closes SF patch #474307.

23 years agoChange new tests to use integer division (// instead of /).
Tim Peters [Wed, 5 Dec 2001 00:30:09 +0000 (00:30 +0000)]
Change new tests to use integer division (// instead of /).

23 years agoSF bug #488480: integer multiply to return -max_int-1.
Tim Peters [Tue, 4 Dec 2001 23:05:10 +0000 (23:05 +0000)]
SF bug #488480: integer multiply to return -max_int-1.
int_mul():  new and vastly simpler overflow checking.  Whether it's
faster or slower will likely vary across platforms, favoring boxes
with fast floating point.  OTOH, we no longer have to worry about
people shipping broken LONG_BIT definitions <0.9 wink>.

23 years agoAdded entry for the "cgitb" module docs.
Fred Drake [Tue, 4 Dec 2001 22:48:17 +0000 (22:48 +0000)]
Added entry for the "cgitb" module docs.

23 years agoDocumentation for the "cgitb" module.
Fred Drake [Tue, 4 Dec 2001 22:47:42 +0000 (22:47 +0000)]
Documentation for the "cgitb" module.

23 years agoMake sure to propogate errors that arise when profiling data cannot be
Fred Drake [Tue, 4 Dec 2001 21:40:53 +0000 (21:40 +0000)]
Make sure to propogate errors that arise when profiling data cannot be
written to the log file, and turn off the profiler.
This closes SF bug #483925.

23 years agoAnother no-longer-nameless contributor...
Guido van Rossum [Tue, 4 Dec 2001 21:33:34 +0000 (21:33 +0000)]
Another no-longer-nameless contributor...

23 years agoAdd note about fixed hash() of mutable objects.
Guido van Rossum [Tue, 4 Dec 2001 21:02:07 +0000 (21:02 +0000)]
Add note about fixed hash() of mutable objects.

23 years agoDefine NDEBUG when compiling a release build on Unix.
Fred Drake [Tue, 4 Dec 2001 20:55:47 +0000 (20:55 +0000)]
Define NDEBUG when compiling a release build on Unix.
This is the Unix portion of the fix for SF bug #489052.

23 years agoImport the keyword module instead of relying on our own list of
Guido van Rossum [Tue, 4 Dec 2001 20:39:36 +0000 (20:39 +0000)]
Import the keyword module instead of relying on our own list of
reserved words.  No longer need to import string.

23 years agoPut the keywords back in alphabetical order. Apparently somebody
Guido van Rossum [Tue, 4 Dec 2001 20:38:44 +0000 (20:38 +0000)]
Put the keywords back in alphabetical order.  Apparently somebody
didn't use reswords.py, as the comment clearly states. :-(

23 years agoStop defining NDEBUG in Python.h, because it can interfere with
Tim Peters [Tue, 4 Dec 2001 20:06:11 +0000 (20:06 +0000)]
Stop defining NDEBUG in Python.h, because it can interfere with
extensions that #include Python.h.  See (rejected) patch 487634 for
more detail.  I'll open a new bug report for the rest needed here.

23 years agoInclude a warning that scripts should not have the same name as standard
Fred Drake [Tue, 4 Dec 2001 19:47:46 +0000 (19:47 +0000)]
Include a warning that scripts should not have the same name as standard
modules, or the module cannot be properly imported.  (Based on a suggestion
sent to python-docs.)

Update the displayed dir() of the sys and __builtin__ module with Python 2.2.

23 years agoTalk about str() in the discussion of string representations of values, and
Fred Drake [Tue, 4 Dec 2001 19:20:43 +0000 (19:20 +0000)]
Talk about str() in the discussion of string representations of values, and
give examples for which str() and repr() yield different results.
This closes SF bug #485446.

23 years agoAdd "file" argument to Hook constructor.
Ka-Ping Yee [Tue, 4 Dec 2001 18:45:17 +0000 (18:45 +0000)]
Add "file" argument to Hook constructor.
By default, save sys.stdout in self.file when a Hook instance is created
    (e.g. when cgitb.enable() is called).

23 years agoAddress SF patch #485789 (Stefan Schwarzer).
Guido van Rossum [Tue, 4 Dec 2001 17:43:22 +0000 (17:43 +0000)]
Address SF patch #485789 (Stefan Schwarzer).

$BROWSER should be split on os.pathsep, not on ":".

23 years agoFix SF bug #486144: Uninitialized __slot__ vrbl is None.
Guido van Rossum [Tue, 4 Dec 2001 17:13:22 +0000 (17:13 +0000)]
Fix SF bug #486144: Uninitialized __slot__ vrbl is None.

There's now a new structmember code, T_OBJECT_EX, which is used for
all __slot__ variables (except __weakref__, which has special behavior
anyway).  This new code raises AttributeError when the variable is
NULL rather than converting NULL to None.

23 years agoFix SF bug #479967: Appearantly I broke something that made the index
Fred Drake [Tue, 4 Dec 2001 17:03:54 +0000 (17:03 +0000)]
Fix SF bug #479967:  Appearantly I broke something that made the index
insertion work.  This fix makes things at least somewhat more explicit, and
adds a little sanity checking (and verbosity!) to
add_bbl_and_idx_dummy_commands().

23 years agoAdd a note that the rgbimg module is only built on 32-bit machines (prompted
Fred Drake [Tue, 4 Dec 2001 16:49:00 +0000 (16:49 +0000)]
Add a note that the rgbimg module is only built on 32-bit machines (prompted
by a question to webmaster).
Re-wrapped a long line.

23 years agolong_mul(): The PyNumber_Multiply() call can return a long if the
Guido van Rossum [Tue, 4 Dec 2001 16:36:39 +0000 (16:36 +0000)]
long_mul(): The PyNumber_Multiply() call can return a long if the
result would overflow an int.  Check for this.  (SF bug #488482, Armin
Rigo.)

23 years agoRemove meaningless comment.
Fred Drake [Tue, 4 Dec 2001 16:32:04 +0000 (16:32 +0000)]
Remove meaningless comment.

23 years agoFix SF bug #486144: Uninitialized __slot__ vrbl is None.
Guido van Rossum [Tue, 4 Dec 2001 16:23:42 +0000 (16:23 +0000)]
Fix SF bug #486144: Uninitialized __slot__ vrbl is None.

There's now a new structmember code, T_OBJECT_EX, which is used for
all __slot__ variables (except __weakref__, which has special behavior
anyway).  This new code raises AttributeError when the variable is
NULL rather than converting NULL to None.

23 years agoPyObject_Generic{Get,Set}Attr(): ensure that the attribute name is a
Guido van Rossum [Tue, 4 Dec 2001 15:54:53 +0000 (15:54 +0000)]
PyObject_Generic{Get,Set}Attr(): ensure that the attribute name is a
string object (or a Unicode that's trivially converted to ASCII).

PyObject_GetAttr(): add an 'else' to the Unicode test like
PyObject_SetAttr() already has.

23 years agoA tiny but useful script that fires off a search on Google.
Guido van Rossum [Tue, 4 Dec 2001 15:23:47 +0000 (15:23 +0000)]
A tiny but useful script that fires off a search on Google.
(Not sure if this is legal according to the Google terms of service. :-)

23 years agoPatch by Jason Harper to allow IDE to work again under MacOS 8.1. Plus appearance...
Jack Jansen [Tue, 4 Dec 2001 13:30:29 +0000 (13:30 +0000)]
Patch by Jason Harper to allow IDE to work again under MacOS 8.1. Plus appearance support for Wlist frames and focussing. Plus commented-out appearance support for the same for Wtext, which still needs some work.

23 years agoThe parser now also needs to link with mysnprintf.o.
Guido van Rossum [Tue, 4 Dec 2001 03:54:08 +0000 (03:54 +0000)]
The parser now also needs to link with mysnprintf.o.

23 years agoPyGrammar_LabelRepr(): sprintf -> PyOS_snprintf.
Tim Peters [Tue, 4 Dec 2001 03:36:01 +0000 (03:36 +0000)]
PyGrammar_LabelRepr():  sprintf -> PyOS_snprintf.

23 years agoThe parser doesn't need its own implementation of assert, and having its
Tim Peters [Tue, 4 Dec 2001 03:18:48 +0000 (03:18 +0000)]
The parser doesn't need its own implementation of assert, and having its
own interfered with including Python.h.  Remove Python's assert.h.

23 years agoUpdate docs to reflect new compile() and compileFile()
Jeremy Hylton [Tue, 4 Dec 2001 02:48:52 +0000 (02:48 +0000)]
Update docs to reflect new compile() and compileFile()

23 years agoSF bug #488687 reported by Neal Norwitz
Jeremy Hylton [Tue, 4 Dec 2001 02:41:46 +0000 (02:41 +0000)]
SF bug #488687 reported by Neal Norwitz

The error for assignment to __debug__ used ste->ste_opt_lineno instead
of n->n_lineno.  The latter was at best incorrect; often the slot was
uninitialized.  Two fixes here: Use the correct lineno for the error.
Initialize ste_opt_lineno in PySymtable_New(); while there are no
current cases where it is referenced unless it has already been
assigned to, there is no harm in initializing it.

23 years agoMore sprintf -> PyOS_snprintf.
Tim Peters [Tue, 4 Dec 2001 01:11:32 +0000 (01:11 +0000)]
More sprintf -> PyOS_snprintf.

23 years agoSlightly improved indexing for the string-% operator, thanks to comments
Fred Drake [Mon, 3 Dec 2001 22:15:56 +0000 (22:15 +0000)]
Slightly improved indexing for the string-% operator, thanks to comments
from Skip Montanaro.  There is one weirdness in the final index for HTML, but
that is low priority.

23 years agoUpdate lambda description to reflect nested scopes. This was noted by
Fred Drake [Mon, 3 Dec 2001 21:47:37 +0000 (21:47 +0000)]
Update lambda description to reflect nested scopes.  This was noted by
Andrew Koenig.

23 years agoAdded documentation on the ScrolledText module.
Fred Drake [Mon, 3 Dec 2001 21:18:30 +0000 (21:18 +0000)]
Added documentation on the ScrolledText module.

23 years agoOops! Forgot the value parameter.
Andrew M. Kuchling [Mon, 3 Dec 2001 20:58:29 +0000 (20:58 +0000)]
Oops!  Forgot the value parameter.

23 years agoAdd __delete__ method of properties
Andrew M. Kuchling [Mon, 3 Dec 2001 20:55:37 +0000 (20:55 +0000)]
Add __delete__ method of properties
Reflow paragraph

23 years agoposix_execve(), posix_spawnve(), posix_putenv():
Tim Peters [Mon, 3 Dec 2001 20:41:00 +0000 (20:41 +0000)]
posix_execve(), posix_spawnve(), posix_putenv():
sprintf -> PyOS_snprintf.  This is the last of this
stuff I intend to do.

23 years agoFix the final two issues in Armin Rigo's SF bug #488477: apply_slice()
Guido van Rossum [Mon, 3 Dec 2001 19:45:06 +0000 (19:45 +0000)]
Fix the final two issues in Armin Rigo's SF bug #488477: apply_slice()
and assign_slice() weren't properly DECREF'ing the temporary slice
object they created.  (Shame on me. :-)

23 years agounpack_iterable(): Add a missing DECREF in an error case. Reported by
Guido van Rossum [Mon, 3 Dec 2001 19:33:25 +0000 (19:33 +0000)]
unpack_iterable(): Add a missing DECREF in an error case.  Reported by
Armin Rigo (SF bug #488477).  Added a testcase to test_unpack_iter()
in test_iter.py.

23 years agoremoved some dead code.
Just van Rossum [Mon, 3 Dec 2001 19:27:38 +0000 (19:27 +0000)]
removed some dead code.

23 years agodecode(), encode(): Accepting the minor optimizations from SF patch
Barry Warsaw [Mon, 3 Dec 2001 19:26:40 +0000 (19:26 +0000)]
decode(), encode(): Accepting the minor optimizations from SF patch
#486375, but not the rest of it, since that changes the documented
semantics of encode().

23 years agofunction_call(): Remove a bogus (and I mean *really* bogus) call to
Guido van Rossum [Mon, 3 Dec 2001 19:22:38 +0000 (19:22 +0000)]
function_call(): Remove a bogus (and I mean *really* bogus) call to
Py_DECREF(arg) after the PyErr_NoMemory() call.  (Armin Rigo, SF bug
#488477.)

23 years agoAdd a scalar product to the example list comprehensions based on a suggestion
Fred Drake [Mon, 3 Dec 2001 18:54:33 +0000 (18:54 +0000)]
Add a scalar product to the example list comprehensions based on a suggestion
sent to python-docs.

23 years agoLIBSUBDIRS: Add test/data so it gets installed and test_email.py can
Barry Warsaw [Mon, 3 Dec 2001 18:51:41 +0000 (18:51 +0000)]
LIBSUBDIRS: Add test/data so it gets installed and test_email.py can
pass.  Closes SF # 485080

23 years agoMinor clarification of the zip() description, based on a comment sent to
Fred Drake [Mon, 3 Dec 2001 18:35:05 +0000 (18:35 +0000)]
Minor clarification of the zip() description, based on a comment sent to
python-docs.

23 years agoMake no assumption about how modules are built when referring to them; this
Fred Drake [Mon, 3 Dec 2001 18:33:13 +0000 (18:33 +0000)]
Make no assumption about how modules are built when referring to them; this
can vary by platform and installation.
Based on suggestion to python-docs.

23 years agoRe-word the intro slightly to avoid reader misunderstanding: strings are not
Fred Drake [Mon, 3 Dec 2001 18:27:22 +0000 (18:27 +0000)]
Re-word the intro slightly to avoid reader misunderstanding: strings are not
mutable!  We do not want to shock anyone.
This closes SF bug #483805.

Re-factor so that the description of the "access" keyword parameter is not
repeated in both the descriptions of mmap().  Also, only make sure the first
description of mmap() appears in the index.  The the index link is followed,
the first is now used to locate the page on the screen; chances are really good
both will be visible.  This avoids the problem that the index entry for the
second is selected and the first version is not visible, making the reader
consider that mmap() is not available on Windows.

23 years agoRemoved old and broken AE-based browser controller, use webbrowser.py
Just van Rossum [Mon, 3 Dec 2001 18:11:36 +0000 (18:11 +0000)]
Removed old and broken AE-based browser controller, use webbrowser.py
instead. This fixes bug #488420.