stack trace output on exception

JR via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Tue Jul 8 00:25:20 PDT 2014


On Tuesday, 8 July 2014 at 07:11:26 UTC, Stephan Schiffels wrote:
> Hi,
>
> I am using dmd with version: DMD64 D Compiler 
> v2.065-devel-db2a73d
>
> My program throws a custom exception with a custom error 
> message at some point. The stack trace (below) is very 
> uninformative. Is there a way to output the function names of 
> each position in the stack?
>
> I already compile using -g and I also tried -gc and -gs and all 
> three of them together. I also tried -debug. The stack trace 
> looks always like this:
>
> popGenFunc.IllegalParametersException at popGenFunc.d(556): gamma 
> out of range
> ----------------
> /nfs/users/nfs_s/ss27/Projects/hfit/build/hfit() [0x42752b]
> /nfs/users/nfs_s/ss27/Projects/hfit/build/hfit() [0x423ee7]
> /nfs/users/nfs_s/ss27/Projects/hfit/build/hfit() [0x404bab]
> /nfs/users/nfs_s/ss27/Projects/hfit/build/hfit() [0x402d7e]
> /nfs/users/nfs_s/ss27/Projects/hfit/build/hfit() [0x4028d6]
> /nfs/users/nfs_s/ss27/Projects/hfit/build/hfit() [0x433cc4]
> /nfs/users/nfs_s/ss27/Projects/hfit/build/hfit() [0x433c1e]
> /nfs/users/nfs_s/ss27/Projects/hfit/build/hfit() [0x433c84]
> /nfs/users/nfs_s/ss27/Projects/hfit/build/hfit() [0x433c1e]
> /nfs/users/nfs_s/ss27/Projects/hfit/build/hfit() [0x433b9f]
> /nfs/users/nfs_s/ss27/Projects/hfit/build/hfit() [0x421121]
> /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xed) 
> [0x7ffe8440e76d]
>
> Thanks for your help,
> Stephan

Tried building with -L--export-dynamic?


More information about the Digitalmars-d-learn mailing list