<p>I want to output the function name each time it is called, I can easily copy and paste the function name, however I wondered if there was a shortcut that would do the job for me?</p>

<p>At the moment I am doing:</p>

<pre><code>SlideInfoHeader* lynxThreeFile::readSlideInfoHeader(QDataStream &amp; in)
{
    qDebug("lynxThreeFile::readSlideInfoHeader");
} 
</code></pre>

<p>but what I want is something generic:</p>

<pre><code>SlideInfoHeader* lynxThreeFile::readSlideInfoHeader(QDataStream &amp; in)
{
    qDebug(this.className() + "::" + this.functionName());
}
</code></pre>

"
```
__FUNCTION__
```
" is supported by both MSVC and GCC and should give you the information you need.