Skip to content

Commit b4310ac

Browse files
committed
Update dis.rst to incorporate new bytecodes.
1 parent f16e778 commit b4310ac

File tree

1 file changed

+9
-28
lines changed

1 file changed

+9
-28
lines changed

Doc/library/dis.rst

Lines changed: 9 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -859,40 +859,25 @@ All of the following opcodes use their arguments.
859859
.. versionadded:: 3.6
860860

861861

862-
.. opcode:: BUILD_TUPLE_UNPACK (count)
862+
.. opcode:: LIST_TO_TUPLE
863863

864-
Pops *count* iterables from the stack, joins them in a single tuple,
865-
and pushes the result. Implements iterable unpacking in tuple
866-
displays ``(*x, *y, *z)``.
864+
Pops a list from the stack and pushes a tuple containing the same values.
867865

868-
.. versionadded:: 3.5
869-
870-
871-
.. opcode:: BUILD_TUPLE_UNPACK_WITH_CALL (count)
872-
873-
This is similar to :opcode:`BUILD_TUPLE_UNPACK`,
874-
but is used for ``f(*x, *y, *z)`` call syntax. The stack item at position
875-
``count + 1`` should be the corresponding callable ``f``.
876-
877-
.. versionadded:: 3.6
866+
.. versionadded:: 3.9
878867

879868

880-
.. opcode:: BUILD_LIST_UNPACK (count)
869+
.. opcode:: LIST_EXTEND (i)
881870

882-
This is similar to :opcode:`BUILD_TUPLE_UNPACK`, but pushes a list
883-
instead of tuple. Implements iterable unpacking in list
884-
displays ``[*x, *y, *z]``.
871+
Calls ``list.extend(TOS1[-i], TOS)``. Used to build lists.
885872

886-
.. versionadded:: 3.5
873+
.. versionadded:: 3.9
887874

888875

889-
.. opcode:: BUILD_SET_UNPACK (count)
876+
.. opcode:: SET_UPDATE
890877

891-
This is similar to :opcode:`BUILD_TUPLE_UNPACK`, but pushes a set
892-
instead of tuple. Implements iterable unpacking in set
893-
displays ``{*x, *y, *z}``.
878+
Calls ``set.update(TOS1[-i], TOS)``. Used to build sets.
894879

895-
.. versionadded:: 3.5
880+
.. versionadded:: 3.9
896881

897882

898883
.. opcode:: BUILD_MAP_UNPACK (count)
@@ -1124,10 +1109,6 @@ All of the following opcodes use their arguments.
11241109
Calls a callable object with variable set of positional and keyword
11251110
arguments. If the lowest bit of *flags* is set, the top of the stack
11261111
contains a mapping object containing additional keyword arguments.
1127-
Below that is an iterable object containing positional arguments and
1128-
a callable object to call. :opcode:`BUILD_MAP_UNPACK_WITH_CALL` and
1129-
:opcode:`BUILD_TUPLE_UNPACK_WITH_CALL` can be used for merging multiple
1130-
mapping objects and iterables containing arguments.
11311112
Before the callable is called, the mapping object and iterable object
11321113
are each "unpacked" and their contents passed in as keyword and
11331114
positional arguments respectively.

0 commit comments

Comments
 (0)