[fpc-devel] New preprocessor directive

Mark Morgan Lloyd markMLl.fpc-devel at telemetry.co.uk
Sun May 17 12:41:20 CEST 2015


Michael Van Canneyt wrote:
> Hello,
> 
> As you probably know, it is possible to include source filename, line 
> number, date etc. in your source
> with the following directives:
> {$I %FILENAME%}
> {$I %LINE%}
> {$i %DATE%}
> 
> At my request, Florian added
> 
> {$I %CURRENTROUTINE%}
> 
> to the list of possibilities, which means you can do nifty things as:

> Entering $main
>   Entering DoSomething
>     Doing something in DoSomething at line 44
>     Entering DoNested
>       Nested handling in DoNested
>     Exiting DoNested
>   Exiting DoSomething
>   Entering MyMethod
>     Doing some things in MyMethod at line 61
>     Entering DoNested
>       Nested handling in DoNested
>     Exiting DoNested
>   Exiting MyMethod
> Exiting $main

Useful, thanks.

-- 
Mark Morgan Lloyd
markMLl .AT. telemetry.co .DOT. uk

[Opinions above are the author's, not those of his employers or colleagues]



More information about the fpc-devel mailing list