develooper Front page | perl.perl5.porters | Postings from September 2010

[perl #71678] Bug [5.11.3] debugger bug in evaluation of user actions ('a' command)

Thread Previous
From:
Father Chrysostomos via RT
Date:
September 26, 2010 13:59
Subject:
[perl #71678] Bug [5.11.3] debugger bug in evaluation of user actions ('a' command)
Message ID:
rt-3.6.HEAD-5116-1285534760-731.71678-15-0@perl.org
On Mon Feb 22 13:32:09 2010, hexcoder wrote:
> maybe my patch for perl #71678 'debugger bug in evaluation of 
> useractions ('a' command)' got lost, so I resend it here (this time even 
> with a change doc and an incremented version number :-).
> 
> After the program to be debugged has terminated, any user defined 
> actions (command 'a') can be cancelled in order to avoid evaluation of
> the action in the command loop later (with undefined data).
> 
> Or should those actions be preserved for a possible next run?
> Then the program state (terminated) would have to be used to suppress
> the evaluation of the action. And the fix would be more difficult than 
> my current patch, of course.
> 
> Please check and consider for integration.

I don’ think it has to do with the end of the program. This script
displays the message three times. I’ve never used the debugger before,
so I don’t know whether this is correct. But it seems to me that $action
needs to be cleared elsewhere in the debugger.

BEGIN {
	push @DB::typeahead, 'a 11 print "thrext\n"', 'c 8', ('s')x3, 'q';
	$DB::single = 0;
}
use strict; use warnings;

greet('Hello');

sub greet
{
	my $arg = shift;
	print "$arg\n";
	return;
}
__END__



Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About