[issue39235] Generator expression has wrong line/col info when inside a Call object

2020-01-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: If somebody want to backport tests to 3.8, he must check manually all end positions. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed versions: -Python 3.7 ___ Python tracker

[issue39235] Generator expression has wrong line/col info when inside a Call object

2020-01-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: New changeset 850a8856e120f8cba15e557a0e791f93b43d6989 by Serhiy Storchaka in branch 'master': bpo-39235: Check end_lineno and end_col_offset of AST nodes. (GH-17926) https://github.com/python/cpython/commit/850a8856e120f8cba15e557a0e791f93b43d6989

[issue39235] Generator expression has wrong line/col info when inside a Call object

2020-01-09 Thread miss-islington
miss-islington added the comment: New changeset 33e033da3c1472b0aa2ae3cff06649a1ae4aa37f by Miss Islington (bot) in branch '3.8': bpo-39235: Fix end location for genexp in call args (GH-17925) https://github.com/python/cpython/commit/33e033da3c1472b0aa2ae3cff06649a1ae4aa37f --

[issue39235] Generator expression has wrong line/col info when inside a Call object

2020-01-09 Thread miss-islington
Change by miss-islington : -- pull_requests: +17334 pull_request: https://github.com/python/cpython/pull/17927 ___ Python tracker ___

[issue39235] Generator expression has wrong line/col info when inside a Call object

2020-01-09 Thread miss-islington
miss-islington added the comment: New changeset a796d8ef9dd1af65f7e4d7a857b56f35b7cb6e78 by Miss Islington (bot) (Guido van Rossum) in branch 'master': bpo-39235: Fix end location for genexp in call args (GH-17925)

[issue39235] Generator expression has wrong line/col info when inside a Call object

2020-01-09 Thread Serhiy Storchaka
Change by Serhiy Storchaka : -- pull_requests: +17333 pull_request: https://github.com/python/cpython/pull/17926 ___ Python tracker ___

[issue39235] Generator expression has wrong line/col info when inside a Call object

2020-01-09 Thread Guido van Rossum
Change by Guido van Rossum : -- keywords: +patch pull_requests: +17332 stage: -> patch review pull_request: https://github.com/python/cpython/pull/17925 ___ Python tracker

[issue39235] Generator expression has wrong line/col info when inside a Call object

2020-01-09 Thread Guido van Rossum
Guido van Rossum added the comment: OK, so I looked into this (sine we can't wait for Serhiy). The problem was probably introduced when Ivan added end lineno/column attributes to parse tree nodes. The offending copy_location() call copies the begin and end locations from the given node

[issue39235] Generator expression has wrong line/col info when inside a Call object

2020-01-06 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: >Do you think it is okay to just remove the call to copy_location? I think that because in that case the parenthesis is collapsed with function call parenthesis, the position of the AST node for the generator expression should point to the left

[issue39235] Generator expression has wrong line/col info when inside a Call object

2020-01-06 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: Do you think it is okay to just remove the call to copy_location? -- ___ Python tracker ___

[issue39235] Generator expression has wrong line/col info when inside a Call object

2020-01-06 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: I think that was introduced in https://bugs.python.org/issue31241 -- nosy: +pablogsal ___ Python tracker ___

[issue39235] Generator expression has wrong line/col info when inside a Call object

2020-01-06 Thread Lysandros Nikolaou
New submission from Lysandros Nikolaou : A normal generator expression like (i for i in a) produces the following AST: Module( body=[ Expr( value=GeneratorExp( elt=Name( id="i", ctx=Load(), lineno=1, col_offset=1, end_lineno=1,