Generates invalid code for functions with named vararg and unnamed kwargs
Bug #475414 reported by
Michal Kwiatkowski
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Pythoscope |
Fix Released
|
Medium
|
Michal Kwiatkowski |
Bug Description
foo(*args, a=1, b=2) isn't legal syntax until Python 2.6, but that's the code Pythoscope can generate in the case vararg has been assigned a name and kwarg hasn't.
Doctest for pythoscope.
Generates valid code when vararg has been named and kwarg wasn't.
>>> args = serialize((1, 2, 3))
>>> call_as_
... Function('wrap', ['*args', '**kwargs']), {args: 'atuple'})
'wrap(a=6, b=7, *atuple)'
Changed in pythoscope: | |
status: | Fix Committed → Fix Released |
To post a comment you must log in.
Fixed in trunk r322.