From 26a0f87e28eb9c90446b23d73e78324f2d481a99 Mon Sep 17 00:00:00 2001 From: Georg Brandl Date: Fri, 30 Jul 2010 08:45:26 +0000 Subject: Document the "jump" command in pdb.__doc__, and add a version tag for "until X". --- Doc/library/pdb.rst | 3 +++ Lib/pdb.py | 10 ++++++++++ 2 files changed, 13 insertions(+) diff --git a/Doc/library/pdb.rst b/Doc/library/pdb.rst index 7f44c08..4e79bad 100644 --- a/Doc/library/pdb.rst +++ b/Doc/library/pdb.rst @@ -339,6 +339,9 @@ by the local file. equal to that is reached. In both cases, also stop when the current frame returns. + .. versionchanged:: 3.2 + Allow giving an explicit line number. + .. pdbcommand:: r(eturn) Continue execution until the current function returns. diff --git a/Lib/pdb.py b/Lib/pdb.py index 7c6b848..cedd17e 100755 --- a/Lib/pdb.py +++ b/Lib/pdb.py @@ -147,6 +147,16 @@ unt(il) [lineno] or equal to that is reached. In both cases, also stop when the current frame returns. +j(ump) lineno + Set the next line that will be executed. Only available in + the bottom-most frame. This lets you jump back and execute + code again, or jump forward to skip code that you don't want + to run. + + It should be noted that not all jumps are allowed -- for + instance it is not possible to jump into the middle of a + for loop or out of a finally clause. + r(eturn) Continue execution until the current function returns. -- cgit v0.12