summaryrefslogtreecommitdiffstats
path: root/Python/compile.c
diff options
context:
space:
mode:
authorMark Shannon <mark@hotpy.org>2020-06-01 09:42:42 (GMT)
committerGitHub <noreply@github.com>2020-06-01 09:42:42 (GMT)
commitdb64f12e4deda2abbafb6d2bd5c06762fca991ff (patch)
treecbaf24cd7eea578450bd3ea6396cf1cd4bbddf4a /Python/compile.c
parenta871f692b4a2e6c7d45579693e787edc0af1a02c (diff)
downloadcpython-db64f12e4deda2abbafb6d2bd5c06762fca991ff.zip
cpython-db64f12e4deda2abbafb6d2bd5c06762fca991ff.tar.gz
cpython-db64f12e4deda2abbafb6d2bd5c06762fca991ff.tar.bz2
Make sure that keyword arguments are merged into the arguments dictionary when dict unpacking and keyword arguments are interleaved. (GH-20553)
Diffstat (limited to 'Python/compile.c')
-rw-r--r--Python/compile.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/Python/compile.c b/Python/compile.c
index 4a587c0..fccc688 100644
--- a/Python/compile.c
+++ b/Python/compile.c
@@ -4321,6 +4321,9 @@ ex_call:
if (!compiler_subkwargs(c, keywords, i - nseen, i)) {
return 0;
}
+ if (have_dict) {
+ ADDOP_I(c, DICT_MERGE, 1);
+ }
have_dict = 1;
nseen = 0;
}