home | O'Reilly's CD bookshelfs | FreeBSD | Linux | Cisco | Cisco Exam    

Book HomeJava and XSLTSearch this book

6.2. Debugger Commands

The debugger understands the following commands.

<

< [command]

Sets a Perl command to run before every debugger prompt. A multiline command may be entered by backslashing the newlines. With no command, the list of actions is reset.

<<


<< [command]

Adds to the list of Perl commands to run before each debugger prompt.

<CR>

<CR>

Repeats last n or s command.

>

> [command]

Sets a Perl command to run after the prompt when you've just given a command to return to executing the script. A multiline command may be entered by backslashing the newlines.

>>

>> [command]

Adds to the list of Perl commands to run after each debugger prompt.

!

! -number

Reruns numberth-to-last command.

!

! pattern

Reruns last command that started with pattern. See O recallCommand.

b

b subname [condition]

Sets a (possibly conditional) breakpoint at the first line of the named subroutine.

b

b load filename

Sets a breakpoint on requireing the given file.

b

b postpone subname [condition]

Sets a (possibly conditional) breakpoint at the first line of subroutine subname after it has been compiled.

b

b compile subname

Stops after the subroutine has been compiled.

m

m class

Prints methods callable via the given class.

O

O [opt[="val"]] [opt'val'] [opt?]

Sets or queries option values. If omitted, val defaults to 1. opt? displays the value of option opt. opt can be abbreviated to the shortest unique string, and multiple options can be specified. The possible options are:

AutoTrace
Affects printing of messages at every possible breaking point.

frame
Enables printing of messages on entry and exit from subroutines.

inhibit_exit
Enables stepping off the end of the script.

maxTraceLen
Gives the maximum length of evals/args listed in the stack trace.

ornaments
Affects the appearance of the command line on the screen.

pager
Specifies the program to use for output of pager-piped commands (those beginning with a | character). Default value is $ENV{PAGER}.

PrintRet
Enables printing of return value after r command.

recallCommand, ShellBang
Specifies the characters used to recall previous commands or spawn a shell. By default, these are both set to !.

The following options affect what happens with the V, X, and x commands:

arrayDepth, hashDepth
Prints only to depth n ("" for all).

compactDump, veryCompact
Changes style of array and hash dumps.

DumpDBFiles
Dumps arrays holding debugged files.

DumpPackages
Dumps symbol tables of packages.

globPrint
Specifies whether to print contents of globs.

quote, HighBit, undefPrint
Changes style of string dump.

signalLevel, warnLevel, dieLevel
Specifies level of verbosity.

tkRunning
Runs Tk while prompting (with ReadLine).

During startup, debugger options are initialized from $ENV{PERLDB_OPTS}. You can set the additional initialization options TTY, noTTY, ReadLine, and NonStop there. See Section 6.4, "Customizing the Debugger" later in this chapter for more information.

t

t expr

Traces through execution of expr.



Library Navigation Links

Copyright © 2002 O'Reilly & Associates. All rights reserved.







??????????????@Mail.ru