[#BloombergLP-bslmf-If]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bslmf.adoc[bslmf]::If
:relfileprefix: ../../
:mrdocs:

This meta&hyphen;function selects `t&lowbar;IF&lowbar;TRUE&lowbar;TYPE` if `t&lowbar;CONDITION` is non&hyphen;zero&period; and `t&lowbar;IF&lowbar;FALSE&lowbar;TYPE` otherwise&period;

== Synopsis

Declared in `&lt;bslmf&lowbar;if&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;
    int t&lowbar;CONDITION,
    class t&lowbar;IF&lowbar;TRUE&lowbar;TYPE = xref:BloombergLP/bslmf/Nil.adoc[Nil],
    class t&lowbar;IF&lowbar;FALSE&lowbar;TYPE = xref:BloombergLP/bslmf/Nil.adoc[Nil]&gt;
struct If;
----

== Type Aliases

[cols="1,4"]
|===
| Name| Description
| xref:BloombergLP/bslmf/If/Type.adoc[`Type`] 
| Selected type based on `t&lowbar;CONDITION`&period;
|===



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