]> granicus.if.org Git - python/commit
bpo-37500: Make sure dead code does not generate bytecode but also detect syntax...
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Mon, 29 Jul 2019 14:47:30 +0000 (07:47 -0700)
committerGitHub <noreply@github.com>
Mon, 29 Jul 2019 14:47:30 +0000 (07:47 -0700)
commit9ea738e580f58c3d2f9b0d56561d57b9e9412973
tree68cc99aed67b5c29da48fe0e6242f9367bb36474
parentcf52bd0b9b1c1b7ecdd91e1ebebd15ae5c213a2c
bpo-37500: Make sure dead code does not generate bytecode but also detect syntax errors (GH-14612)

https://bugs.python.org/issue37500

Add a new field to the compiler structure that allows to be configured
so no bytecode is emitted. In this way is possible to detect errors by
walking the nodes while preserving optimizations.

https://bugs.python.org/issue37500
(cherry picked from commit 18c5f9d44dde37c0fae5585a604c6027825252d2)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
Lib/test/test_compile.py
Lib/test/test_syntax.py
Lib/test/test_sys_settrace.py
Python/compile.c