Command |
Description |
s |
Step; Perl executes the line listed above the prompt, stepping into
any subroutines; note that a line with multiple commands may take a
few steps to evaluate. |
n |
Next; Perl executes the line listed above the prompt, stepping over
any subroutines (they still run; Perl waits for them to finish before
continuing). |
c |
Continue to the end of the program or the next break point, whichever
comes first. |
c 123 |
Continue up to line 123; line 123 must contain a command (it cannot
be a comment, blank line, the second half of a command, etc.). |
b |
Set a breakpoint at current line; breakpoints halt execution caused
by c. |
b 123 |
Set a breakpoint at line 123; line 123 must contain a command (it
cannot be a comment, blank line, the second half of a command, etc.). |
b my_sub |
Set a breakpoint at the first executable line of the
my_sub sub. |
d |
Delete a breakpoint from the current line; takes same arguments as
b. |
D |
Deletes all breakpoints. |
x $var |
Display the value of $var in list and scalar
contexts; note that it will recurse down complex, nested data
structures. |
r |
Return from the current sub; Perl finishes executing the current
subroutine, displays the result, and continues at the next line after
the sub. |
l |
List the next 10 lines of your script; this command can be used
successively. |
l 123 |
List line 123 of your script. |
l 200-300 |
List lines 200 through 300 of your script. |
l my_sub |
List the first 10 lines of the my_sub sub. |
q |
Quit. |
R |
Restart the script in the debugger. |