"Martyn J. Pearce" <fluffy@sixears.co.uk> wrote: > On Thu, Oct 02, 2003 at 09:32:53AM +0000, Slaven Rezic wrote: > > Try to set the $DB::sub variable: > > > > my $sub = sub { > > $DB::sub = "namedsub"; > > ... > > }; > > Thanks for the idea, but that seems not to affect either the use of the > debugger or dprofpp :-( > No? $ cat bla.pl my $sub = sub { $DB::sub = "namedsub"; 1; 1; 1; 1; }; $sub->(); __END__ $ perl5.8.1 -d bla.pl Loading DB routines from perl5db.pl version 1.22 Editor support available. Enter h or `h h' for help, or `man perldebug' for more help. main::(bla.pl:7): }; DB<1> t Trace = on DB<1> c main::(bla.pl:9): $sub->(); main::(bla.pl:10): __END__ main::CODE(0x8139504)(bla.pl:2): $DB::sub = "namedsub"; main::namedsub(bla.pl:3): 1; main::namedsub(bla.pl:4): 1; main::namedsub(bla.pl:5): 1; main::namedsub(bla.pl:6): 1; Debugged program terminated. Use q to quit or R to restart, use O inhibit_exit to avoid stopping after program termination, h q, h R or h O to get additional info. DB<1> Regards, Slaven -- Slaven Rezic - slaven <at> rezic <dot> deThread Previous