wierdness in debugger
Basile B. via Digitalmars-d-ide
digitalmars-d-ide at puremagic.com
Fri Mar 31 06:32:48 PDT 2017
On Thursday, 30 March 2017 at 17:28:44 UTC, Enigma wrote:
> When debugging a foreach loop that works on an enum constant,
> the debugger has different behavior if the loop uses brackets
> or not
Which debugger are you talking about GDB, Mago, LLDB ? linux or
windows ? which IDE do you use ?
>
> [...]
>
> a BP on the writeln lines will have the debugger skip to the
> writeln when stepping in the first case and not the second.
Can you be more clear ?
Let's say i want to reproduce the issue, i put BP on the two
writeln, i launch a GDB session, GDB breaks on the first writeln
and then ?
>
> It's as if the debugger thinks that the statement after the
> first max is part of the for each block or something weird like
> that. Was confusing at first and thought it was a bug because I
> was getting the wrong value for y. When, in fact, the BP on the
> writeln simply did not execute the foreach loop completely like
> it would in the second case, even though it should.
More information about the Digitalmars-d-ide
mailing list