Fix 3.6. call_ex_kw semantic action

Was missing positional args parameter in template. Fix submited by @x0ret

Fixes #227
This commit is contained in:
rocky
2019-05-09 09:27:10 -04:00
parent b57ca392a2
commit e875b79a75
3 changed files with 16 additions and 2 deletions

Binary file not shown.

View File

@@ -0,0 +1,13 @@
# From #227
# Bug was not handling call_ex_kw correctly
# THis appears in
# showparams(c, test="A", **extra_args)
# below
def showparams(c, test, **extra_args):
return {'c': c, **extra_args, 'test': test}
def f(c, **extra_args):
return showparams(c, test="A", **extra_args)
assert f(1, a=2, b=3) == {'c': 1, 'a': 2, 'b': 3, 'test': 'A'}

View File

@@ -69,8 +69,9 @@ def customize_for_version36(self, version):
'%c(%p)',
(0, 'expr'), (1, 100)),
'call_ex_kw' : (
'%c(%p)',
(0, 'expr'), (2, 100)),
'%c(*%c, %p)',
(0, 'expr'), (1, 'expr'),
(2, 'build_map_unpack_with_call', 100)),
})