Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork33.3k
bpo-39320: Handle unpacking of **values in compiler#18141
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
bpo-39320: Handle unpacking of **values in compiler#18141
Uh oh!
There was an error while loading.Please reload this page.
Conversation
b6ad237 to95e421cCompare| @@ -0,0 +1,12 @@ | |||
| Replace two complex bytecodes for building dicts with two simpler ones. | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
Different paragraphs render badly when joining the NEWS entries, sadly
bedevere-bot commentedJan 23, 2020
🤖 New build scheduled with the buildbot fleet by@markshannon for commit2d2fe4c 🤖 If you want to schedule another build, you need to add the ":hammer: test-with-buildbots" label again. |
The failures in |
OK, merging. |
* Add DICT_UPDATE and DICT_MERGE bytecodes. Use them for ** unpacking.* Remove BUILD_MAP_UNPACK and BUILD_MAP_UNPACK_WITH_CALL, as they are now unused.* Update magic number for ** unpacking opcodes.* Update dis.rst to incorporate new bytecodes.* Add blurb entry.
Uh oh!
There was an error while loading.Please reload this page.
This is the second part of the implementation ofbpo-39320.
Part 1 was#17984
This PR replaces BUILD_MAP_UNPACK and BUILD_MAP_UNPACK_WITH_CALL
with DICT_MERGE and DICT_UPDATE.
DICT_UPDATE ncallsitem_n.update(tos)whereitem_nis thenth item on the stack andtosis popped from the stack.DICT_MERGE nis the same, but raises an exception if there are duplicate keys.https://bugs.python.org/issue39320