Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | bpo-33691: Add _PyAST_GetDocString(). (GH-7236) | Serhiy Storchaka | 2018-05-30 | 1 | -30/+15 |
| | |||||
* | bpo-32911: Revert bpo-29463. (GH-7121) (GH-7197) | Serhiy Storchaka | 2018-05-29 | 1 | -13/+42 |
| | | | | | | Remove the docstring attribute of AST types and restore docstring expression as a first stmt in their body. Co-authored-by: INADA Naoki <methane@users.noreply.github.com> | ||||
* | bpo-33475: Fix and improve converting annotations to strings. (GH-6774) | Serhiy Storchaka | 2018-05-17 | 1 | -1/+1 |
| | |||||
* | bpo-33363: raise SyntaxError for async for/with outside async functions (#6616) | Zsolt Dollenstein | 2018-04-27 | 1 | -0/+7 |
| | |||||
* | bpo-33334: Support NOP and EXTENDED_ARG in dis.stack_effect(). (#6566) | Serhiy Storchaka | 2018-04-25 | 1 | -0/+4 |
| | | | Added tests to ensure that all defined opcodes are supported. | ||||
* | bpo-33298: Wrap only constants with _PyCode_ConstantKey() in the compiler. ↵ | Serhiy Storchaka | 2018-04-20 | 1 | -104/+117 |
| | | | | (GH-6512) | ||||
* | bpo-33299: Return an object itself for some types in _PyCode_ConstantKey(). ↵ | Serhiy Storchaka | 2018-04-19 | 1 | -4/+6 |
| | | | | (GH-6513) | ||||
* | bpo-33270: Intern names for all anonymous code objects (#6472) | Zackery Spytz | 2018-04-15 | 1 | -4/+4 |
| | |||||
* | bpo-33132: Fix more reference counting issues in the compiler. (GH-6323) | Serhiy Storchaka | 2018-03-31 | 1 | -4/+2 |
| | |||||
* | bpo-33132: Fix reference counting issues in the compiler. (GH-6209) | Serhiy Storchaka | 2018-03-24 | 1 | -19/+12 |
| | |||||
* | bpo-33041: Rework compiling an "async for" loop. (#6142) | Serhiy Storchaka | 2018-03-23 | 1 | -96/+22 |
| | | | | | | | | * Added new opcode END_ASYNC_FOR. * Setting global StopAsyncIteration no longer breaks "async for" loops. * Jumping into an "async for" loop is now disabled. * Jumping out of an "async for" loop no longer corrupts the stack. * Simplify the compiler. | ||||
* | bpo-32489: Allow 'continue' in 'finally' clause. (GH-5822) | Serhiy Storchaka | 2018-03-18 | 1 | -4/+0 |
| | |||||
* | bpo-33041: Add missed error checks when compile "async for" (#6053) | Serhiy Storchaka | 2018-03-10 | 1 | -14/+7 |
| | | | and remove redundant code. | ||||
* | bpo-33041: Fixed bytecode generation for "async for" with a complex target. ↵ | Serhiy Storchaka | 2018-03-10 | 1 | -2/+2 |
| | | | | | | (#6052) A StopAsyncIteration raised on assigning or unpacking will be now propagated instead of stopping the iteration. | ||||
* | bpo-17611. Move unwinding of stack for "pseudo exceptions" from interpreter ↵ | Serhiy Storchaka | 2018-02-22 | 1 | -165/+244 |
| | | | | | | | | | to compiler. (GH-5006) Co-authored-by: Mark Shannon <mark@hotpy.org> Co-authored-by: Antoine Pitrou <antoine@python.org> | ||||
* | bpo-32550. Remove the STORE_ANNOTATION bytecode. (GH-5181) | Mark Shannon | 2018-01-30 | 1 | -6/+10 |
| | |||||
* | String annotations [PEP 563] (#4390) | Guido van Rossum | 2018-01-26 | 1 | -2/+24 |
| | | | | | | | | * Document `from __future__ import annotations` * Provide plumbing and tests for `from __future__ import annotations` * Implement unparsing the AST back to string form This is required for PEP 563 and as such only implements a part of the unparsing process that covers expressions. | ||||
* | bpo-31113: Get rid of recursion in the compiler for normal control flow. (#3015) | Serhiy Storchaka | 2018-01-11 | 1 | -78/+104 |
| | |||||
* | bpo-24340: Fix estimation of the code stack size. (#5076) | Serhiy Storchaka | 2018-01-09 | 1 | -37/+90 |
| | |||||
* | bpo-32439: Clean up the code for compiling comparison expressions. (#5029) | Serhiy Storchaka | 2017-12-30 | 1 | -23/+20 |
| | |||||
* | bpo-32372: Move __debug__ optimization to the AST level. (#4925) | Serhiy Storchaka | 2017-12-25 | 1 | -18/+8 |
| | |||||
* | bpo-32365: Fix a reference leak when compile __debug__. (#4916) | Serhiy Storchaka | 2017-12-18 | 1 | -4/+4 |
| | | | It was introduced in bpo-27169. | ||||
* | bpo-27169: The __debug__ constant is now optimized out at compile time. (#4880) | Serhiy Storchaka | 2017-12-15 | 1 | -30/+15 |
| | | | This fixes also bpo-22091. | ||||
* | bpo-29469: Move constant folding to AST optimizer (GH-2858) | INADA Naoki | 2017-12-14 | 1 | -0/+4 |
| | |||||
* | bpo-32176: Set CO_NOFREE in the code object constructor (GH-4675) | Nick Coghlan | 2017-12-03 | 1 | -5/+0 |
| | | | | | | | | Previously, CO_NOFREE was set in the compiler, which meant it could end up being set incorrectly when code objects were created directly. Setting it in the constructor based on freevars and cellvars ensures it is always accurate, regardless of how the code object is defined. | ||||
* | Add the const qualifier to "char *" variables that refer to literal strings. ↵ | Serhiy Storchaka | 2017-11-11 | 1 | -1/+1 |
| | | | | (#4370) | ||||
* | bpo-31708: Allow async generator expressions in synchronous functions (#3905) | Yury Selivanov | 2017-10-06 | 1 | -1/+1 |
| | |||||
* | bpo-31709: Drop support for asynchronous __aiter__. (#3903) | Yury Selivanov | 2017-10-06 | 1 | -6/+0 |
| | |||||
* | bpo-31338 (#3374) | Barry Warsaw | 2017-09-15 | 1 | -2/+1 |
| | | | | | | | * Add Py_UNREACHABLE() as an alias to abort(). * Use Py_UNREACHABLE() instead of assert(0) * Convert more unreachable code to use Py_UNREACHABLE() * Document Py_UNREACHABLE() and a few other macros. | ||||
* | bpo-31286, bpo-30024: Fixed stack usage in absolute imports with (#3217) | Serhiy Storchaka | 2017-08-29 | 1 | -10/+16 |
| | | | binding a submodule to a name. | ||||
* | bpo-30923: Silence fall-through warnings included in -Wextra since gcc-7.0. ↵ | Stefan Krah | 2017-08-21 | 1 | -2/+3 |
| | | | | (#3157) | ||||
* | bpo-30501: Make the compiler producing optimized code for condition ↵ | Serhiy Storchaka | 2017-06-11 | 1 | -41/+137 |
| | | | | expressions. (#1851) | ||||
* | bpo-30024: Circular imports involving absolute imports with binding (#1264) | Serhiy Storchaka | 2017-05-09 | 1 | -2/+2 |
| | | | a submodule to a name are now supported. | ||||
* | bpo-29878: Add global instances of int for 0 and 1. (#852) | Serhiy Storchaka | 2017-03-30 | 1 | -16/+3 |
| | |||||
* | bpo-29463: Add docstring field to some AST nodes. (#46) | INADA Naoki | 2017-02-22 | 1 | -48/+16 |
| | | | | | | | | | | | * bpo-29463: Add docstring field to some AST nodes. ClassDef, ModuleDef, FunctionDef, and AsyncFunctionDef has docstring field for now. It was first statement of there body. * fix document. thanks travis! * doc fixes | ||||
* | bpo-29607: Fix stack_effect computation for CALL_FUNCTION_EX (#202) | Matthieu Dartiailh | 2017-02-21 | 1 | -1/+1 |
| | |||||
* | Issue #28959: Added private macro PyDict_GET_SIZE for retrieving the size of ↵ | Serhiy Storchaka | 2016-12-16 | 1 | -17/+9 |
| | | | | dict. | ||||
* | Issue #26110: Add LOAD_METHOD/CALL_METHOD opcodes. | Yury Selivanov | 2016-12-14 | 1 | -0/+37 |
| | | | | | | | Special thanks to INADA Naoki for pushing the patch through the last mile, Serhiy Storchaka for reviewing the code, and to Victor Stinner for suggesting the idea (originally implemented in the PyPy project). | ||||
* | Issue #28739: f-string expressions no longer accepted as docstrings and | Serhiy Storchaka | 2016-12-11 | 1 | -1/+2 |
|\ | | | | | | | by ast.literal_eval() even if they do not include subexpressions. | ||||
| * | Issue #28739: f-string expressions no longer accepted as docstrings and | Serhiy Storchaka | 2016-12-11 | 1 | -1/+2 |
| | | | | | | | | by ast.literal_eval() even if they do not include subexpressions. | ||||
* | | Merge #23722 from 3.6 | Nick Coghlan | 2016-12-05 | 1 | -2/+6 |
|\ \ | |/ | |||||
| * | Issue #23722: improve __classcell__ compatibility | Nick Coghlan | 2016-12-05 | 1 | -2/+6 |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Handling zero-argument super() in __init_subclass__ and __set_name__ involved moving __class__ initialisation to type.__new__. This requires cooperation from custom metaclasses to ensure that the new __classcell__ entry is passed along appropriately. The initial implementation of that change resulted in abruptly broken zero-argument super() support in metaclasses that didn't adhere to the new requirements (such as Django's metaclass for Model definitions). The updated approach adopted here instead emits a deprecation warning for those cases, and makes them work the same way they did in Python 3.5. This patch also improves the related class machinery documentation to cover these details and to include more reader-friendly cross-references and index entries. | ||||
* | | Issue #28823: Simplified compiling with opcode BUILD_MAP_UNPACK. | Serhiy Storchaka | 2016-11-28 | 1 | -5/+2 |
| | | |||||
* | | Added the const qualifier to char* variables that refer to readonly internal | Serhiy Storchaka | 2016-11-20 | 1 | -1/+1 |
|/ | | | | UTF-8 represenatation of Unicode objects. | ||||
* | Issue #28701: Replace PyUnicode_CompareWithASCIIString with ↵ | Serhiy Storchaka | 2016-11-16 | 1 | -5/+5 |
|\ | | | | | | | | | | | _PyUnicode_EqualToASCIIString. The latter function is more readable, faster and doesn't raise exceptions. | ||||
| * | Issue #28701: Replace PyUnicode_CompareWithASCIIString with ↵ | Serhiy Storchaka | 2016-11-16 | 1 | -5/+5 |
| | | | | | | | | | | | | _PyUnicode_EqualToASCIIString. The latter function is more readable, faster and doesn't raise exceptions. | ||||
* | | Issue #28257: Improved error message when pass a non-iterable as | Serhiy Storchaka | 2016-10-02 | 1 | -2/+2 |
| | | | | | | | | a var-positional argument. Added opcode BUILD_TUPLE_UNPACK_WITH_CALL. | ||||
* | | Issue #27213: Fixed different issues with reworked CALL_FUNCTION* opcodes. | Serhiy Storchaka | 2016-09-11 | 1 | -5/+4 |
| | | | | | | | | | | | | | | | | | | | | | | * BUILD_TUPLE_UNPACK and BUILD_MAP_UNPACK_WITH_CALL no longer generated with single tuple or dict. * Restored more informative error messages for incorrect var-positional and var-keyword arguments. * Removed code duplications in _PyEval_EvalCodeWithName(). * Removed redundant runtime checks and parameters in _PyStack_AsDict(). * Added a workaround and enabled previously disabled test in test_traceback. * Removed dead code from the dis module. | ||||
* | | Issue #28076: Variable annotations should be mangled for private names. | Guido van Rossum | 2016-09-11 | 1 | -1/+7 |
| | | | | | | | | By Ivan Levkivskyi. | ||||
* | | Issue #27129: Replaced wordcode related magic constants with macros. | Serhiy Storchaka | 2016-09-11 | 1 | -6/+7 |
| | |