Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | pop the loop block even for infinite while loops (closes #23048) | Benjamin Peterson | 2014-12-13 | 1 | -3/+2 |
| | |||||
* | Issue #22453: Fexed reference leaks when format error messages in ceval.c. | Serhiy Storchaka | 2014-11-18 | 1 | -6/+6 |
| | | | | Warn against the use of leaking macro PyObject_REPR(). | ||||
* | Issue #21523: Fix over-pessimistic computation of the stack effect of some ↵ | Antoine Pitrou | 2014-05-23 | 1 | -2/+6 |
| | | | | | | | opcodes in the compiler. This also fixes a quadratic compilation time issue noticeable when compiling code with a large number of "and" and "or" operators. | ||||
* | Issue #17645: convert an assert() into a proper exception in _Py_Mangle(). | Antoine Pitrou | 2013-04-06 | 1 | -2/+5 |
| | |||||
* | remove unused variable | Meador Inge | 2012-07-18 | 1 | -1/+1 |
| | |||||
* | Issue #15368: fixing variable typo. | Meador Inge | 2012-07-18 | 1 | -1/+1 |
| | |||||
* | Issue #15368: make bytecode generation deterministic. | Meador Inge | 2012-07-18 | 1 | -2/+22 |
| | |||||
* | don't let a tuple msg be interpreted as arguments to AssertionError (closes ↵ | Benjamin Peterson | 2011-10-27 | 1 | -4/+2 |
| | | | | #13268) | ||||
* | Fix misindents in compile.c (for Benjamin). | Antoine Pitrou | 2010-06-22 | 1 | -11/+11 |
| | | | | Of course, whoever used the wrong indentation rules needs to be spanked. | ||||
* | Untabify C files. Will watch buildbots. | Antoine Pitrou | 2010-05-09 | 1 | -3128/+3128 |
| | |||||
* | Backported PyCapsule from 3.1, and converted most uses of | Larry Hastings | 2010-03-25 | 1 | -7/+9 |
| | | | | CObject to PyCapsule. | ||||
* | prevent lambda functions from having docstrings #8164 | Benjamin Peterson | 2010-03-17 | 1 | -0/+5 |
| | |||||
* | normalize exceptions passed to the __exit__ method #7853 | Benjamin Peterson | 2010-02-05 | 1 | -0/+3 |
| | | | | | | | | | In Python 2.x, exceptions in finally blocks are not normalized. Since with statements are implemented using finally blocks, ceval.c had to be tweaked to distinguish between with finally blocks and normal ones. A test for the finalization of generators containing with statements was also added. | ||||
* | Issue #2333: Backport set and dict comprehensions syntax. | Alexandre Vassalotti | 2010-01-11 | 1 | -42/+152 |
| | |||||
* | Issue #2335: Backport set literals syntax from Python 3.x. | Alexandre Vassalotti | 2010-01-09 | 1 | -0/+6 |
| | |||||
* | Issue #1678380: When distinguishing between -0.0 and 0.0 in | Mark Dickinson | 2009-11-28 | 1 | -26/+15 |
| | | | | | | compiler_add_o, use copysign instead of examining the first and last bytes of the double. The latter method fails for little-endian ARM, OABI, where doubles are little-endian but with the words swapped. | ||||
* | turn goto into do while loop | Benjamin Peterson | 2009-11-20 | 1 | -36/+31 |
| | |||||
* | Allow core Python build to succeed under WITHOUT_COMPLEX. The module build ↵ | Mark Dickinson | 2009-10-15 | 1 | -3/+6 |
| | | | | stage still fails. | ||||
* | Issue #1754094: Improve the stack depth calculation in the compiler. | Neil Schemenauer | 2009-10-14 | 1 | -12/+21 |
| | | | | | There should be no other effect than a small decrease in memory use. Patch by Christopher Tur Lesniewski-Laas. | ||||
* | remove tmpname support since it's no longer used | Benjamin Peterson | 2009-06-21 | 1 | -2/+0 |
| | |||||
* | remove unused 'encoding' member from the compiler struct | Benjamin Peterson | 2009-06-17 | 1 | -4/+0 |
| | |||||
* | when no module is given in a 'from' relative import, make ImportFrom.module NULL | Benjamin Peterson | 2009-06-13 | 1 | -10/+18 |
| | |||||
* | Fix nearly all compilation warnings under Apple gcc-4.0. Tested with OPT="-g | Jeffrey Yasskin | 2009-05-29 | 1 | -12/+0 |
| | | | | | | -Wall -Wstrict-prototypes -Werror" in both --with-pydebug mode and --without. There's still a batch of non-prototype warnings in Xlib.h that I don't know how to fix. | ||||
* | take into account the fact that SETUP_WITH pushes a finally block | Benjamin Peterson | 2009-05-25 | 1 | -1/+1 |
| | |||||
* | add a SETUP_WITH opcode | Benjamin Peterson | 2009-05-25 | 1 | -56/+9 |
| | | | | | It speeds up the with statement and correctly looks up the special methods involved. | ||||
* | Issue #6042: | Jeffrey Yasskin | 2009-05-23 | 1 | -51/+3 |
| | | | | | | | | | | | | | | | lnotab-based tracing is very complicated and isn't documented very well. There were at least 3 comment blocks purporting to document co_lnotab, and none did a very good job. This patch unifies them into Objects/lnotab_notes.txt which tries to completely capture the current state of affairs. I also discovered that we've attached 2 layers of patches to the basic tracing scheme. The first layer avoids jumping to instructions that don't start a line, to avoid problems in if statements and while loops. The second layer discovered that jumps backward do need to trace at instructions that don't start a line, so it added extra lnotab entries for 'while' and 'for' loops, and added a special case for backward jumps within the same line. I replaced these patches by just treating forward and backward jumps differently. | ||||
* | Backport r69961 to trunk, replacing JUMP_IF_{TRUE,FALSE} with | Jeffrey Yasskin | 2009-02-28 | 1 | -53/+33 |
| | | | | | | POP_JUMP_IF_{TRUE,FALSE} and JUMP_IF_{TRUE,FALSE}_OR_POP. This avoids executing a POP_TOP on each conditional and sometimes allows the peephole optimizer to skip a JUMP_ABSOLUTE entirely. It speeds up list comprehensions significantly. | ||||
* | more flags which only work for function blocks | Benjamin Peterson | 2009-01-31 | 1 | -6/+4 |
| | |||||
* | add explanatory comment | Benjamin Peterson | 2009-01-31 | 1 | -0/+2 |
| | |||||
* | #4077: No need to append \n when calling Py_FatalError | Amaury Forgeot d'Arc | 2009-01-17 | 1 | -1/+1 |
| | | | | + fix a declaration to make it match the one in pythonrun.h | ||||
* | #4748 lambda generators shouldn't return values | Benjamin Peterson | 2008-12-27 | 1 | -1/+6 |
| | |||||
* | Issue #2183: Simplify and optimize bytecode for list comprehensions. | Antoine Pitrou | 2008-12-17 | 1 | -26/+7 |
| | |||||
* | check for assignment to __debug__ during AST generation | Benjamin Peterson | 2008-11-08 | 1 | -6/+0 |
| | | | | Also, give assignment to None a better error message | ||||
* | Merge in release25-maint r60793: | Gregory P. Smith | 2008-06-11 | 1 | -4/+28 |
| | | | | | | Added checks for integer overflows, contributed by Google. Some are only available if asserts are left in the code, in cases where they can't be triggered from Python code. | ||||
* | This reverts r63675 based on the discussion in this thread: | Gregory P. Smith | 2008-06-09 | 1 | -47/+47 |
| | | | | | | | http://mail.python.org/pipermail/python-dev/2008-June/079988.html Python 2.6 should stick with PyString_* in its codebase. The PyBytes_* names in the spirit of 3.0 are available via a #define only. See the email thread. | ||||
* | Renamed PyString to PyBytes | Christian Heimes | 2008-05-26 | 1 | -47/+47 |
| | |||||
* | Patch #2511: Give the "excepthandler" AST item proper attributes by making ↵ | Georg Brandl | 2008-03-30 | 1 | -7/+7 |
| | | | | it a Sum. | ||||
* | Fix a reference leak found by Georg, when compiling a class nested in ↵ | Amaury Forgeot d'Arc | 2008-03-28 | 1 | -0/+1 |
| | | | | | | | | another class. Now "regrtest.py -R:: test_compile" is satisfied. Will backport. | ||||
* | Patch #1810 by Thomas Lee, reviewed by myself: | Georg Brandl | 2008-03-28 | 1 | -6/+14 |
| | | | | | allow compiling Python AST objects into code objects in compile(). | ||||
* | Add a warning for code like: | Neal Norwitz | 2008-03-15 | 1 | -0/+8 |
| | | | | | | | | | | assert (0, 'message') An empty tuple does not create a warning. While questionable usage: assert (), 'message' should not display a warning. Tested manually. The warning message could be improved. Feel free to update it. | ||||
* | Speed up with statements by storing the __exit__ method on the stack instead ↵ | Nick Coghlan | 2008-03-07 | 1 | -14/+6 |
| | | | | of in a temp variable (bumps the magic number for pyc files) | ||||
* | Fix indentation | Neal Norwitz | 2008-02-25 | 1 | -1/+1 |
| | |||||
* | Patch #1759: Backport of PEP 3129 class decorators | Christian Heimes | 2008-02-23 | 1 | -2/+11 |
| | | | | with some help from Georg | ||||
* | Cast a struct to a void pointer so as to do a type-safe pointer comparison | Brett Cannon | 2008-02-07 | 1 | -3/+3 |
| | | | | (mistmatch found by clang). | ||||
* | Change r60575 broke test_compile: | Amaury Forgeot d'Arc | 2008-02-05 | 1 | -0/+3 |
| | | | | there is no need to emit co_lnotab item when both offsets are zeros. | ||||
* | #1750076: Debugger did not step on every iteration of a while statement. | Amaury Forgeot d'Arc | 2008-02-04 | 1 | -14/+15 |
| | | | | | | | | | | | | The mapping between bytecode offsets and source lines (lnotab) did not contain an entry for the beginning of the loop. Now it does, and the lnotab can be a bit larger: in particular, several statements on the same line generate several entries. However, this does not bother the settrace function, which will trigger only one 'line' event. The lnotab seems to be exactly the same as with python2.4. | ||||
* | Issue #1678380. Fix a bug that identifies 0j and -0j when they appear | Mark Dickinson | 2008-01-31 | 1 | -12/+47 |
| | | | | | in the same code unit. The fix is essentially the same as the fix for a previous bug identifying 0. and -0. | ||||
* | static PyObject* variables should use PyString_InternFromString() instead of ↵ | Christian Heimes | 2008-01-28 | 1 | -2/+2 |
| | | | | PyObject_FromString() to store a python string in a function level static var. | ||||
* | #1920: when considering a block starting by "while 0", the compiler ↵ | Amaury Forgeot d'Arc | 2008-01-24 | 1 | -1/+4 |
| | | | | | | | | | | | | | | | | | optimized the whole construct away, even when an 'else' clause is present:: while 0: print("no") else: print("yes") did not generate any code at all. Now the compiler emits the 'else' block, like it already does for 'if' statements. Will backport. | ||||
* | Add comments | Raymond Hettinger | 2007-12-20 | 1 | -3/+3 |
| |