[issue24176] Incorrect parsing of unpacked expressions in call

2015-05-16 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 38b2307372bf by Benjamin Peterson in branch 'default':
allow test node after ** in calls (closes #24176)
https://hg.python.org/cpython/rev/38b2307372bf

--
nosy: +python-dev
resolution:  - fixed
stage:  - resolved
status: open - closed

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



[issue24176] Incorrect parsing of unpacked expressions in call

2015-05-13 Thread Thomas Caswell

New submission from Thomas Caswell:

On the current tip (changeset: 96023:4b5461dcd190) the following results in a 
syntax error

def test(a='a', b='b'):
print(a, b)

opta = dict()
optb = dict(a=1, b=2)
test(**(opta or {}))  # - works on all python
test(**optb or {})# - fails on current hg tip


This is suspected to be a result of 
https://hg.python.org/cpython/rev/a65f685ba8c0 

This was reported as an issue against sphinx 
(https://github.com/sphinx-doc/sphinx/pull/1889) and I was redirected here.

As suggested by Robert Lehmann suggests the issue is 
https://hg.python.org/cpython/rev/a65f685ba8c0#l1.33 which should be `** test`. 
 Making this change prevents the syntax error (patch attached).

--
components: Interpreter Core
files: unpack_grammar.patch
keywords: patch
messages: 243087
nosy: tcaswell
priority: normal
severity: normal
status: open
title: Incorrect parsing of unpacked expressions in call
type: behavior
versions: Python 3.5
Added file: http://bugs.python.org/file39359/unpack_grammar.patch

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



[issue24176] Incorrect parsing of unpacked expressions in call

2015-05-13 Thread Yury Selivanov

Changes by Yury Selivanov yseliva...@gmail.com:


--
nosy: +benjamin.peterson, yselivanov

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