Getting backtrace
Xavier Bigand
flamaros.xavier at gmail.com
Thu Jan 9 11:25:07 PST 2014
Le 08/01/2014 21:29, Benjamin Thaut a écrit :
> Am 08.01.2014 21:25, schrieb Xavier Bigand:
>> Is there a way to get backtrace outside exceptions?
>
> Found a plattform independend way:
>
> import core.runtime;
> import std.stdio;
>
> void main(string[] args)
> {
> auto trace = defaultTraceHandler(null);
> foreach(t; trace)
> {
> writefln("%s", t);
> }
> }
It's exactly what I need, thank you.
More information about the Digitalmars-d-learn
mailing list