8000 bpo-33387: update documentation for exception handling opcode changes… · python/cpython@dea5bf9 · GitHub
[go: up one dir, main page]

Skip to content

Commit dea5bf9

Browse files
authored
bpo-33387: update documentation for exception handling opcode changes (GH-24334)
* bpo-33387: remove obsolete comment * bpo-33387: update SETUP_WITH opcode documentation
1 parent c92cd0f commit dea5bf9

File tree

2 files changed

+1
-3
lines changed

2 files changed

+1
-3
lines changed

Doc/library/dis.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -742,7 +742,7 @@ iterations of the loop.
742742

743743
This opcode performs several operations before a with block starts. First,
744744
it loads :meth:`~object.__exit__` from the context manager and pushes it onto
745-
the stack for later use by :opcode:`WITH_CLEANUP_START`. Then,
745+
the stack for later use by :opcode:`WITH_EXCEPT_START`. Then,
746746
:meth:`~object.__enter__` is called, and a finally block pointing to *delta*
747747
is pushed. Finally, the result of calling the ``__enter__()`` method is pushed onto
748748
the stack. The next opcode will either ignore it (:opcode:`POP_TOP`), or

Python/compile.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -898,8 +898,6 @@ compiler_next_instr(basicblock *b)
898898
* 1 -- when jump
899899
* -1 -- maximal
900900
*/
901-
/* XXX Make the stack effect of WITH_CLEANUP_START and
902-
WITH_CLEANUP_FINISH deterministic. */
903901
static int
904902
stack_effect(int opcode, int oparg, int jump)
905903
{

0 commit comments

Comments
 (0)
0