[#BloombergLP-bslim-TestUtil-makeFunctionCallNonInline]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bslim.adoc[bslim]::xref:BloombergLP/bslim/TestUtil.adoc[TestUtil]::makeFunctionCallNonInline
:relfileprefix: ../../../
:mrdocs:

Return the specified `functionPtr` (expected to be a static function pointer) without modification&period; The value of `functionPtr` is transformed through `identityPtr` so that if the caller is in a different module, the compiler will have no way of knowing that this is an identity transform and thus no way of inlining the call&period;

== Synopsis

Declared in `&lt;bslim&lowbar;testutil&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;class FUNCTION&lowbar;PTR&gt;
static
FUNCTION&lowbar;PTR
makeFunctionCallNonInline(FUNCTION&lowbar;PTR functionPtr);
----

== Description

Note&colon; the Windows optimizer is still able to inline the call, it may be comparing the result of this function with the argument and branching to inline on equality and call on inequality, so the Windows optimizer has to be turned off with `&num; pragma optimize(&quot;&quot;, off)`&period;

Also note that even with an optimizer that can&apos;t figure out that this is an identity transform, there is still the possibility of chaining the call&period;


[.small]#Created with https://www.mrdocs.com[MrDocs]#
