]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
bpo-38870: Implement a precedence algorithm in ast.unparse (GH-17377)
authorBatuhan Taşkaya <47358913+isidentical@users.noreply.github.com>
Sun, 1 Mar 2020 20:12:17 +0000 (23:12 +0300)
committerGitHub <noreply@github.com>
Sun, 1 Mar 2020 20:12:17 +0000 (20:12 +0000)
commit397b96f6d7a89f778ebc0591e32216a8183fe667
treebca7cb5940e1a5cb1cdc80b3578a238dfac318d1
parent185903de12de8837bf0dc0008a16e5e56c66a019
bpo-38870: Implement a precedence algorithm in ast.unparse (GH-17377)

Implement a simple precedence algorithm for ast.unparse in order to avoid redundant
parenthesis for nested structures in the final output.
Lib/ast.py
Lib/test/test_ast.py
Lib/test/test_unparse.py