trace

Easy way to output file/line for debugging.

Usage:

trace();
someFunc();
trace("Blah blah blah");
int x = *(cast(int*)null); // Dereference null
trace();

Example Output:

C:\path\file.d(1): trace
C:\path\file.d(3): Blah blah blah
{segfault!}
void
trace
(
string file = __FILE__
size_t line = __LINE__
)
(
string msg = "trace"
)

Meta