[#absl-AnyInvocable-2constructor-02]
= xref:absl.adoc[absl]::xref:absl/AnyInvocable.adoc[AnyInvocable]::AnyInvocable
:relfileprefix: ../../
:mrdocs:

Constructs an `AnyInvocable` that holds an invocable object of type `T`, which is constructed in&hyphen;place from the given arguments&period;

== Synopsis

Declared in `&lt;absl&sol;functional&sol;any&lowbar;invocable&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;
    class T,
    class&period;&period;&period; Args&gt;
requires internal&lowbar;any&lowbar;invocable&colon;&colon;CanEmplace&lt;Sig, T, Args&period;&period;&period;&gt;&colon;&colon;value
explicit
AnyInvocable(
    std::in&lowbar;place&lowbar;type&lowbar;t&lt;T&gt; tag,
    Args&&&period;&period;&period; args);
----

== Description

Example&colon;

AnyInvocable&lt;int(int)&gt; func( std&colon;&colon;in&lowbar;place&lowbar;type&lt;PossiblyImmovableType&gt;, arg1, arg2)&semi;

== Parameters

[cols="1,4"]
|===
| Name| Description
| *args*
| Arguments forwarded to the constructor of `T`&period;
| *tag*
| A tag that selects this overload&period;
|===


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