Memory corruption rant.
Kagamin
spam at here.lot
Thu Jun 2 03:49:33 PDT 2011
Kagamin Wrote:
> Jesse Phillips Wrote:
>
> > writeln("I'm still ok");
> > writeln("2");
> > if(myObject is null)
> > writeln("3");
> > else
> > writeln("4");
> > writeln(0);
> > writeln(false);
>
> > Prints everything up to 2.
>
> You should look at it in debugger at assembly level. There's no need to compile it with debug symbols, they'll be of no use for you. I suspect EBP==0.
writeln("I'm still ok");
asm
{
cmp EBP,0;
ja ok;
hlt;
ok: nop;
}
writeln("Still ok");
if(myObject is null)
writeln("3");
else
writeln("4");
More information about the Digitalmars-d-learn
mailing list