10BC0 gh-105481: remove HAS_ARG, HAS_CONST, IS_JUMP_OPCODE, IS_PSEUDO_OPCODE and replace by their new versions by iritkatriel · Pull Request #105865 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
add doc and news
  • Loading branch information
iritkatriel committed Jun 17, 2023
commit 237ba258286f20c3848158b34c734bc0fdd45b2b
6 changes: 6 additions & 0 deletions Doc/library/dis.rst
Original file line number Diff line number Diff line change
Expand Up @@ -318,6 +318,12 @@ operation is being performed, so the intermediate analysis object isn't useful:
.. versionchanged:: 3.8
Added *jump* parameter.

.. versionchanged:: 3.13
If ``oparg`` is omitted (or ``None``), the stack effect is now returned
for ``oparg=0``. Previously this was an error for opcodes that use their
arg. It is also no longer an error to pass an integer ``oparg`` when
the ``opcode`` does not use it; the ``oparg`` in this case is ignored.


.. _bytecodes:

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
:func:`~dis.stack_effect`B no longer raises an exception if an ``oparg`` is
provided for an ``opcode`` that doesn't use its arg, or when it is not
provided for an ``opcode`` that does use it. In the latter case, the stack
effect is returned or ``oparg=0``.
0