gh-107427: Update the description of UNPACK_SEQUENCE#107429
Conversation
| right-to-left:: | ||
|
|
||
| STACK.extend(STACK.pop()[:count:-1]) | ||
| STACK.extend(STACK.pop()[:-count-1:-1]) |
There was a problem hiding this comment.
Shouldn't we also document somehow that we require STACK.pop() to have exactly count elements?
There was a problem hiding this comment.
Update the sentence Unpacks ``STACK[-1]`` into *count* individual values into Unpacks ``STACK.pop()`` into *count* individual values will be enough?
There was a problem hiding this comment.
I don’t think so. Leave that sentence alone, but add e.g. “Require there to be exactly count values.”
| right-to-left:: | ||
|
|
||
| STACK.extend(STACK.pop()[:count:-1]) | ||
| STACK.extend(STACK.pop()[:-count-1:-1]) |
There was a problem hiding this comment.
I don’t think so. Leave that sentence alone, but add e.g. “Require there to be exactly count values.”
|
Technically the thing on top of the stack may not have a |
|
Thanks @corona10 for the PR 🌮🎉.. I'm working now to backport this PR to: 3.12. |
|
GH-107459 is a backport of this pull request to the 3.12 branch. |
📚 Documentation preview 📚: https://cpython-previews--107429.org.readthedocs.build/