[Issue 19086] New: Bad stack trace for exceptions

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sat Jul 14 00:33:23 UTC 2018


https://issues.dlang.org/show_bug.cgi?id=19086

          Issue ID: 19086
           Summary: Bad stack trace for exceptions
           Product: D
           Version: D2
          Hardware: x86_64
                OS: Windows
            Status: NEW
          Severity: normal
          Priority: P1
         Component: dmd
          Assignee: nobody at puremagic.com
          Reporter: goalitium at dissues.mail.kapsi.fi

Created attachment 1710
  --> https://issues.dlang.org/attachment.cgi?id=1710&action=edit
DMD and LDC2 callstacks for the exception

Exceptions in a piece code like:

void main()
{
    throw new Exception("hi");
}

...does not generate a proper stack trace for the exception when debugged with
a Visual Studio debugger. The debugger does not break at the correct line (or
file) when uncaught exception is triggered.

Debugging the same code built with LDC2 causes the debugger to break at the
correct line, but only for x86_64 targets (x86-COFF does not work at all for
both DMD and LDC2).

dmd --version:
> DMD32 D Compiler v2.081.1
DMD build command:
> dmd -debug -g -m64 main.d
LDC2 build command:
> ldmd2 -debug -g -m64 main.d

--


More information about the Digitalmars-d-bugs mailing list