This issue tracker has been migrated to GitHub ,
and is currently read-only.
For more information,
see the GitHub FAQs in the Python's Developer Guide.
Created on 2020年04月02日 00:22 by pablogsal, last changed 2022年04月11日 14:59 by admin. This issue is now closed.
| Pull Requests | |||
|---|---|---|---|
| URL | Status | Linked | Edit |
| PR 19289 | merged | pablogsal, 2020年04月02日 00:24 | |
| PR 19389 | merged | ZackerySpytz, 2020年04月06日 05:38 | |
| Messages (3) | |||
|---|---|---|---|
| msg365537 - (view) | Author: Pablo Galindo Salgado (pablogsal) * (Python committer) | Date: 2020年04月02日 00:22 | |
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. |
|||
| msg365719 - (view) | Author: Pablo Galindo Salgado (pablogsal) * (Python committer) | Date: 2020年04月03日 19:37 | |
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 |
|||
| msg365841 - (view) | Author: Pablo Galindo Salgado (pablogsal) * (Python committer) | Date: 2020年04月06日 06:48 | |
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 |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:59:28 | admin | set | github: 84328 |
| 2020年04月06日 06:48:03 | pablogsal | set | messages: + msg365841 |
| 2020年04月06日 05:38:31 | ZackerySpytz | set | nosy:
+ ZackerySpytz pull_requests: + pull_request18752 |
| 2020年04月03日 19:42:15 | pablogsal | set | status: open -> closed resolution: fixed stage: patch review -> resolved |
| 2020年04月03日 19:37:20 | pablogsal | set | messages: + msg365719 |
| 2020年04月02日 00:24:04 | pablogsal | set | keywords:
+ patch stage: patch review pull_requests: + pull_request18648 |
| 2020年04月02日 00:23:07 | pablogsal | set | nosy:
+ lys.nikolaou |
| 2020年04月02日 00:22:24 | pablogsal | create | |