bug-gawk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [bug-gawk] gawk debugger omits watchpoint


From: Hermann Peifer
Subject: Re: [bug-gawk] gawk debugger omits watchpoint
Date: Thu, 26 Nov 2015 18:14:42 +0100
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.10; rv:38.0) Gecko/20100101 Thunderbird/38.3.0

Thanks for looking into the issue, which is obviously a small one and
not worth starting a major overhaul for fixing it.

My workaround so far was to add an additional (random) statement at the
end, say: END{x=1;y=2;z=3}. This moves the last watchpoint to the
penultimate position and the issue is "solved".

Hermann


On 2015-11-25 21:16, Aharon Robbins wrote:
> Hi.
> 
> I don't think I can fix this one. I did take a look at it.
> 
> The debugger really only understands lines, not syntactic statements.
> I think it'd take a major overhaul to fix that.  It's particularly
> nasty at the last point of the END rule; when it's dealing with printing
> breakpoints and watchpoints, the debugger doesn't really understand that
> there won't be any more statements coming.
> 
> Arnold
> 
>> To: "address@hidden" <address@hidden>
>> From: Hermann Peifer <address@hidden>
>> Date: Wed, 25 Nov 2015 20:37:36 +0100
>> Subject: [bug-gawk] gawk debugger omits watchpoint
>>
>> Hi again,
>>
>> Below some sample code where it looks like the second watchpoint is not
>> reached before exiting. This looks wrong to me.
>>
>> Hermann
>>
>> $ printf "END{x=1;y=2}\n" > tmp.awk
>> $ printf "w x\nw y\nr\nc\n" | gawk -D -f tmp.awk /dev/null
>> Watchpoint 1: x
>> Watchpoint 2: y
>> Starting program:
>> Stopping in END ...
>> Watchpoint 1: x
>>   Old value: untyped variable
>>   New value: 1
>> main() at `tmp.awk':1
>> 1       END{x=1;y=2}
>> Program exited normally with exit value: 0
>> $
>>




reply via email to

[Prev in Thread] Current Thread [Next in Thread]