Commit Graph

2719 Commits

Author SHA1 Message Date
Benjamin Peterson
9f4f48114f Use PyErr_WarnPy3k throughout 2008-04-27 03:01:45 +00:00
Benjamin Peterson
a692c4df63 Added PyErr_WarnPy3k function. (issue 2671) I will be converting current Py3k warnings to the use of this function soon. 2008-04-27 02:28:02 +00:00
Christian Heimes
6f34109384 I finally got the time to update and merge Mark's and my trunk-math branch. The patch is collaborated work of Mark Dickinson and me. It was mostly done a few months ago. The patch fixes a lot of loose ends and edge cases related to operations with NaN, INF, very small values and complex math.
The patch also adds acosh, asinh, atanh, log1p and copysign to all platforms. Finally it fixes differences between platforms like different results or exceptions for edge cases. Have fun :)
2008-04-18 23:13:07 +00:00
Benjamin Peterson
858a77099e Fix indentation in sysmodule.c 2008-04-18 20:45:33 +00:00
Amaury Forgeot d'Arc
f9e7ebe165 Correct a refleak found by "regrtest.py -R:: test_structmembers"
Some other minor updates in _warnings.c:
- make a function static
- rename a shadowing local variable
2008-04-14 20:07:48 +00:00
Georg Brandl
41a0a37c08 Improve -X error message. 2008-04-13 20:50:29 +00:00
Benjamin Peterson
820b51c170 #2627 Let it be known what pgen generates 2008-04-13 20:35:56 +00:00
Christian Heimes
6715352848 Use PyString_InternFromString instead of PyString_FromString for static vars 2008-04-13 09:33:24 +00:00
Brett Cannon
40f0a87666 Fix a bug in PySys_HasWarnOption() where it was not properly checking the
length of the list storing the warning options.
2008-04-13 00:18:44 +00:00
Brett Cannon
e974689038 Re-implement the 'warnings' module in C. This allows for usage of the
'warnings' code in places where it was previously not possible (e.g., the
parser). It could also potentially lead to a speed-up in interpreter start-up
if the C version of the code (_warnings) is imported over the use of the
Python version in key places.

Closes issue #1631171.
2008-04-12 23:44:07 +00:00
Christian Heimes
7a98d2730c Applied patch #2617 from Frank Wierzbicki wit some extras from me
-J and -X are now reserved for Jython and non-standard arguments (e.g. IronPython). I've added some extra comments to make sure the reservation don't get missed in the future.
2008-04-12 13:03:03 +00:00
Georg Brandl
e34c21c2a0 Make AST nodes pickleable. 2008-03-30 20:20:39 +00:00
Georg Brandl
1721e75749 Fix error message -- "expects either 0 or 0 arguments" 2008-03-30 19:43:27 +00:00
Georg Brandl
2c55c597fa Make _fields attr for no fields consistent with _attributes attr. 2008-03-30 19:00:49 +00:00
Georg Brandl
c52ed59473 #2505: allow easier creation of AST nodes. 2008-03-30 07:01:47 +00:00
Georg Brandl
a48f3ab895 Patch #2511: Give the "excepthandler" AST item proper attributes by making it a Sum. 2008-03-30 06:40:17 +00:00
Georg Brandl
f2bfd54d6f Properly check for consistency with the third argument of
compile() when compiling an AST node.
2008-03-29 13:24:23 +00:00
Amaury Forgeot d'Arc
69b747b735 Fix a reference leak found by Georg, when compiling a class nested in another class.
Now "regrtest.py -R:: test_compile" is satisfied.

Will backport.
2008-03-28 20:30:50 +00:00
Amaury Forgeot d'Arc
473445c964 Silence a compilation warning 2008-03-28 20:17:51 +00:00
Georg Brandl
fc8eef3c78 Patch #1810 by Thomas Lee, reviewed by myself:
allow compiling Python AST objects into code objects
in compile().
2008-03-28 12:11:56 +00:00
Neal Norwitz
d183bdd6fb Revert r61969 which added casts to Py_CHARMASK to avoid compiler warnings.
Rather than sprinkle casts throughout the code, change Py_CHARMASK to
always cast it's result to an unsigned char.  This should ensure we
do the right thing when accessing an array with the result.
2008-03-28 04:58:51 +00:00
Christian Heimes
61e4590ec9 Build bots are working again - removing the hack 2008-03-27 10:35:52 +00:00
Christian Heimes
81caa790b6 Quick 'n dirty hack: Increase the magic by 2 to force a rebuild of pyc/pyo files on the build bots 2008-03-27 09:02:33 +00:00
Neal Norwitz
231346e23f Fix warnings about using char as an array subscript. This is not portable
since char is signed on some platforms and unsigned on others.
2008-03-27 04:40:50 +00:00
Amaury Forgeot d'Arc
df70e05d22 C89 compliance: Microsoft compilers want variable declarations at the top 2008-03-26 23:07:43 +00:00