Exception stack traces on Phobos2? (Win or Lin)

Jonathan M Davis jmdavisprog at gmail.com
Sat Sep 4 18:01:13 PDT 2010


On Saturday 04 September 2010 17:25:23 Nick Sabalausky wrote:
> Didn't work for me on Linux/2.048.

I'm not sure what to tell you. I'm using dmd 2.048 on linux, and if I compile 
the following program

void func()
{
    assert(1 == 0);
}

void main()
{
    func();
}


with the command

dmd d.d -L--export-dynamic


I get

core.exception.AssertError at d(3): Assertion failure
----------------
./d(_d_assertm+0x16) [0x805ae46]
./d(_D1d8__assertFiZv+0x12) [0x8058912]
./d(_D1d4funcFZv+0xd) [0x80588f1]
./d(_Dmain+0x8) [0x80588fc]
./d(_D2rt6dmain24mainUiPPaZi7runMainMFZv+0x1a) [0x805b036]
./d(_D2rt6dmain24mainUiPPaZi7tryExecMFMDFZvZv+0x24) [0x805af90]
./d(_D2rt6dmain24mainUiPPaZi6runAllMFZv+0x32) [0x805b07a]
./d(_D2rt6dmain24mainUiPPaZi7tryExecMFMDFZvZv+0x24) [0x805af90]
./d(main+0x96) [0x805af36]
/opt/lib32/lib/libc.so.6(__libc_start_main+0xe6) [0xf7557c76]
./d() [0x8058831]


So, it _should_ work on liunx with dmd 2.048.

- Jonathan M Davis


More information about the Digitalmars-d-learn mailing list