[issue40147] Move checking for duplicated keywords to the compiler

2020-04-05 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:


New changeset 08050e959e6c40839cd2c9e5f6a4fd1513e3d605 by Zackery Spytz in 
branch 'master':
bpo-40147: Fix a compiler warning on Windows in Python/compile.c (GH-19389)
https://github.com/python/cpython/commit/08050e959e6c40839cd2c9e5f6a4fd1513e3d605


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40147] Move checking for duplicated keywords to the compiler

2020-04-05 Thread Zackery Spytz


Change by Zackery Spytz :


--
nosy: +ZackerySpytz
nosy_count: 2.0 -> 3.0
pull_requests: +18752
pull_request: https://github.com/python/cpython/pull/19389

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40147] Move checking for duplicated keywords to the compiler

2020-04-03 Thread Pablo Galindo Salgado


Change by Pablo Galindo Salgado :


--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40147] Move checking for duplicated keywords to the compiler

2020-04-03 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:


New changeset 254ec783411d9d16e51f1116f98918be2ef0e884 by Pablo Galindo in 
branch 'master':
bpo-40147: Move the check for duplicate keywords to the compiler (GH-19289)
https://github.com/python/cpython/commit/254ec783411d9d16e51f1116f98918be2ef0e884


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40147] Move checking for duplicated keywords to the compiler

2020-04-01 Thread Pablo Galindo Salgado


Change by Pablo Galindo Salgado :


--
keywords: +patch
pull_requests: +18648
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/19289

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40147] Move checking for duplicated keywords to the compiler

2020-04-01 Thread Pablo Galindo Salgado


Change by Pablo Galindo Salgado :


--
nosy: +lys.nikolaou

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40147] Move checking for duplicated keywords to the compiler

2020-04-01 Thread Pablo Galindo Salgado


New submission from Pablo Galindo Salgado :

When a keyword is repeated in a call for instance:

'f(1, x=2, *(3, 4), x=5)'

we raise a SyntaxError:

  File "lel.py", line 1
f(1, x=2, *(3, 4), x=5)
   ^
SyntaxError: keyword argument repeated

This error is raised from the AST but there is nothing technically wrong with 
that code from the grammar perspective. Indeed, the grammar must accepts that 
code, but the check must fail later (in the compiler for instance) because the 
code is semantically invalid. When working on the new PEG parser we have 
encountered this situation and changing the parser would remove the check as it 
is right now. For these reasons, the check should be moved from the AST to the 
compiler.

--
messages: 365537
nosy: pablogsal
priority: normal
severity: normal
status: open
title: Move checking for duplicated keywords to the compiler

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com