[#beman-optional-optional-06-2constructor-0f8]
= xref:beman.adoc[beman]::xref:beman/optional.adoc[optional]::xref:beman/optional/optional-06.adoc[optional&lt;T&&gt;]::optional
:relfileprefix: ../../../
:mrdocs:

In&hyphen;place constructor&period;

== Synopsis

Declared in `&lt;beman&sol;optional&sol;optional&period;hpp&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;class Arg&gt;
requires (std&colon;&colon;is&lowbar;constructible&lowbar;v&lt;T&amp;, Arg&gt; &amp;&amp; !detail&colon;&colon;reference&lowbar;constructs&lowbar;from&lowbar;temporary&lowbar;v&lt;T&amp;, Arg&gt;)
constexpr
explicit
optional(
    xref:beman/optional/in_place_t.adoc[in&lowbar;place&lowbar;t],
    Arg&& arg);
----


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