Commit Graph

23426 Commits

Author SHA1 Message Date
Jack Jansen
c4ff194bdd Fixed the last two bgen-based modules to be buildable on OSX. 2002-08-05 21:13:07 +00:00
Jeremy Hylton
53d527ad18 Initial prototype of framer: a tool to build the frame for extension modules. 2002-08-05 18:29:45 +00:00
Jeremy Hylton
f4d32df19d Remove function definition from cStringIO.h.
xxxPyCObject_Import() seems to be a copy of PyCObject_Import().
2002-08-05 18:20:01 +00:00
Fred Drake
5f8a23f32f Since the errno module is needed by os._execvpe(), and that is used by the
setup.py (indirectly) script to build the standard dynamically loaded
modules, the errno module is being made static so it will always be
available.
Closes SF bug #591205 (needed on trunk only).
2002-08-05 18:06:17 +00:00
Guido van Rossum
2805428d92 SF patch 590294: os._execvpe security fix (Zack Weinberg). 2002-08-05 16:14:46 +00:00
Guido van Rossum
aed51d8121 SF patch 590294: os._execvpe security fix (Zack Weinberg).
1) Do not attempt to exec a file which does not exist
just to find out what error the operating system
returns. This is an exploitable race on all platforms
that support symbolic links.

2) Immediately re-raise the exception if we get an
error other than errno.ENOENT or errno.ENOTDIR. This
may need to be adapted for other platforms.

(As a security issue, this should be considered for 2.1
and 2.2 as well as 2.3.)
2002-08-05 16:13:24 +00:00
Jack Jansen
aaebdd6a02 Enable building of Carbon toolbox modules with unix-Python. 2002-08-05 15:39:30 +00:00
Jack Jansen
ff8dec7427 Got rid of staticforward. 2002-08-05 15:36:57 +00:00
Jack Jansen
a4741ffe63 This can now run under unix-Python too. You have to pass the folder
to search on the command line in that case.
2002-08-05 15:33:44 +00:00
Jack Jansen
ac7cb05415 Fixed to run better in unix-Python, and to cater for bgenlocations
possibly being missing.
2002-08-05 15:32:30 +00:00
Fred Drake
40813b1dbc Typo: "now" --> "the new" 2002-08-05 15:24:19 +00:00
Martin v. Löwis
98ce7b7ef1 IDLE support for PEP 263. 2002-08-05 15:11:26 +00:00
Jack Jansen
6573f31874 Moved bgenlocations to the Mac/Lib directory. Not perfect, but better than
where it was: it is really a configuration file, not a normal module.

By moving it into Mac/Lib we can now also store the location of bgen
itself in there, which is needed because bgen isn't installed.
2002-08-05 14:56:04 +00:00
Martin v. Löwis
eade4a1580 Patch #590913: PEP 263 support. 2002-08-05 14:55:21 +00:00
Martin v. Löwis
5428fff111 Use ascii_letters to avoid UnicodeErrors. 2002-08-05 14:53:52 +00:00
Guido van Rossum
de392d3f3f Add a small description of PEP 263. 2002-08-05 14:17:20 +00:00
Jack Jansen
cf0a2cfdb2 Added a cast to shut up a compiler warning. 2002-08-05 14:14:05 +00:00
Jack Jansen
ace9d955b0 Renamed Py_Main to PyMac_Main as it has a different signature than the "normal" Py_Main, and that signature has appeared in a .h file. 2002-08-05 14:13:31 +00:00
Jack Jansen
3bd3fedeca Added _IBCarbon module. 2002-08-05 14:12:24 +00:00
Raymond Hettinger
bc552ce1b8 SF 582071 clarified the .split() method's docstring to note that sep=None
will trigger splitting on any whitespace.
2002-08-05 06:28:21 +00:00
Raymond Hettinger
acb45d72b4 Note that True and False are pickable objects 2002-08-05 03:55:36 +00:00
Kurt B. Kaiser
8dcdb77132 GvR provided solution to the socket rebinding timeout problem.
M PyShell.py
M rpc.py
M run.py
2002-08-05 03:52:10 +00:00
Martin v. Löwis
725bb233b9 Add 1 to lineno in deprecation warning. Fixes #590888. 2002-08-05 01:49:16 +00:00
Martin v. Löwis
4c561b36a0 Test whether a Cyrillic text correctly appears in a Unicode literal. 2002-08-05 01:32:09 +00:00
Tim Peters
6782d6aa91 We don't really need the name of the test in the "test skipped" msg, and
having it there causes the line to wrap.
2002-08-04 22:55:35 +00:00
Tim Peters
283ead8bf2 Oops! Forgot the closing paren. 2002-08-04 22:52:30 +00:00
Tim Peters
32ef169339 Finally got around to figuring out and documenting why this test fails
on Windows.  The test_sequence() ERROR is easily repaired if we're
willing to add an os.unlink() line to mhlib's updateline().  The
test_listfolders FAIL I gave up on -- I don't remember enough about Unix
link esoterica to recall why a link count of 2 is something a well-
written program should be keenly interested in <wink>.
2002-08-04 22:35:31 +00:00
Jack Jansen
a30d1447cf Build the _IBCarbon module. 2002-08-04 22:04:25 +00:00
Jack Jansen
83f5c38403 The definitions for IBCarbonRuntime.h 2002-08-04 22:03:36 +00:00
Jack Jansen
acbaefd796 Updated to something that works on my system, and regenerated module. 2002-08-04 21:59:37 +00:00
Jack Jansen
7ea8143fe5 Specify pathnames in a way that works on both OS9 and OSX.
You'll still have to manually edit it, though...
2002-08-04 21:56:12 +00:00
Jack Jansen
bae7734eef Use universal newline input when scanning header files. 2002-08-04 21:55:25 +00:00
Jack Jansen
0c069924e5 Donovan Preston's interface to IBCarbon, allowing you to use Interface
Builder carbon NIB files from Python. As-is, I may need to twiddle a few
things as he donated this long ago.

Donovan is now one of the four people in the world who know how to drive
bgen!
2002-08-04 21:34:24 +00:00
Jack Jansen
84a016417a Changes to the OSX section:
- steer people away from installing with sudo
- warn that fink-installed software may cause trouble
- explain why you might want a framework build and point people to
  Mac/OSX/README.
2002-08-04 21:19:55 +00:00
Jack Jansen
c736b8df09 Use the -n option of ln in stead of -h, as it also works with other ln's
people may have (fink, gnu).
2002-08-04 21:17:20 +00:00
Skip Montanaro
04d80f87d7 small speedup for constant and name access
see sf #506436
2002-08-04 21:03:35 +00:00
Martin v. Löwis
1ee99d31d9 Make pgen compile with pydebug. Duplicate normalized names, as it may
be longer than the old string.
2002-08-04 20:10:29 +00:00
Martin v. Löwis
cd280fb59c Group statements properly. 2002-08-04 18:28:44 +00:00
Tim Peters
2c3f9c6f04 Repaired a fatal compiler error in the debug build: it's not clear what
this was trying to assert, but the name it referenced didn't exist.
2002-08-04 17:58:34 +00:00
Tim Peters
919603b27a Squash compiler wng about signed-vs-unsigned mismatch. 2002-08-04 17:56:42 +00:00
Tim Peters
66860f6da4 Sped the usual case for sorting by calling PyObject_RichCompareBool
directly when no comparison function is specified.  This saves a layer
of function call on every compare then.  Measured speedups:

 i    2**i  *sort  \sort  /sort  3sort  +sort  %sort  ~sort  =sort  !sort
15   32768  12.5%   0.0%   0.0% 100.0%   0.0%  50.0% 100.0% 100.0% -50.0%
16   65536   8.7%   0.0%   0.0%   0.0%   0.0%   0.0%  12.5%   0.0%   0.0%
17  131072   8.0%  25.0%   0.0%  25.0%   0.0%  14.3%   5.9%   0.0%   0.0%
18  262144   6.3% -10.0%  12.5%  11.1%   0.0%   6.3%   5.6%  12.5%   0.0%
19  524288   5.3%   5.9%   0.0%   5.6%   0.0%   5.9%   5.4%   0.0%   2.9%
20 1048576   5.3%   2.9%   2.9%   5.1%   2.8%   1.3%   5.9%   2.9%   4.2%

The best indicators are those that take significant time (larger i), and
where sort doesn't do very few compares (so *sort and ~sort benefit most
reliably).  The large numbers are due to roundoff noise combined with
platform variability; e.g., the 14.3% speedup for %sort at i=17 reflects
a printed elapsed time of 0.18 seconds falling to 0.17, but a change in
the last digit isn't really meaningful (indeed, if it really took 0.175
seconds, one electron having a lazy nanosecond could shift it to either
value <wink>).  Similarly the 25% at 3sort i=17 was a meaningless change
from 0.05 to 0.04.  However, almost all the "meaningless changes" were
in the same direction, which is good.  The before-and-after times for
*sort are clearest:

before after
  0.18  0.16
  0.25  0.23
  0.54  0.50
  1.18  1.11
  2.57  2.44
  5.58  5.30
2002-08-04 17:47:26 +00:00
Martin v. Löwis
00f1e3f5a5 Patch #534304: Implement phase 1 of PEP 263. 2002-08-04 17:29:52 +00:00
Martin v. Löwis
a729daf2e4 Add encoding declaration. 2002-08-04 17:28:33 +00:00
Martin v. Löwis
09776b7afd Add encoding declaration. 2002-08-04 17:22:59 +00:00
Steve Holden
c8389c91c2 Remove a syntax error in the example, spotted by Walter Hofman. 2002-08-04 15:27:25 +00:00
Martin v. Löwis
d6359c55cc Always link libpython.so with LIBS. Fixes #589422. 2002-08-04 12:38:50 +00:00
Martin v. Löwis
7d6e19d70c Add trace_frame. Fixes #534864. Backported to 2.2. 2002-08-04 08:24:49 +00:00
Martin v. Löwis
5a39530274 Add recursion counter for pickling. Fixes #576084.
2.2 bugfix candidate (may cause RuntimeError for applications that
currently work fine).
2002-08-04 08:20:23 +00:00
Andrew MacIntyre
161ad0e16b OS/2 EMX now supported 2002-08-04 07:25:58 +00:00
Tim Peters
8d30b1e673 I don't know what's going on with this test, but the last change from
Piers obviously couldn't have passed on any platform.  Fiddling it so it
works (for a meaning of "works" no stronger than "doesn't fail" <wink>).
2002-08-04 06:53:18 +00:00