KW.pm The Perl Debugger #19

Customization

  • internal debugger configuration options

    • set debugger options with O - only one useful example of this I know of:

      O pager=|more

  • debugger configuration file: .perldb

    • include perl code to run when debugger starts.

    • such as modifying DB package variables:

        $DB::alias{'stop'} = 's/stop (at|in}/b/';
  • debugger is simply a library that takes advantage of hooks in Perl interpreter

  • replace the debugger completely, if you like.

                cp /usr/lib/perl5/5.6.1/perl5db.pl ~/myperl5db.pl
                BEGIN { require "~/myperl5db.pl" }
  • or use alternative debuggers

    • DProf is included with perl5.6

      perl -d:DProf mycode.pl

  • or use the hooks yourself.

    • (See Carp.pm)

(see example .perldb)

<< Previous | Index | Next >> Copyright © 2002 Daniel Allen