[#bsl-make_shared-02]
= xref:bsl.adoc[bsl]::make&lowbar;shared
:relfileprefix: ../
:mrdocs:

Return a `shared&lowbar;ptr` managing a newly created object&period;

== Synopsis

Declared in `&lt;bslstl&lowbar;sharedptr&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;
    class ELEMENT&lowbar;TYPE,
    class&period;&period;&period; ARGS&gt;
xref:bsl/shared_ptr-0a.adoc[bsl::shared&lowbar;ptr&lt;ELEMENT&lowbar;TYPE&gt;]
make&lowbar;shared(ARGS&&&period;&period;&period; args)
requires !bsl&colon;&colon;is&lowbar;array&lt;ELEMENT&lowbar;TYPE&gt;&colon;&colon;value;
----

== Description

Return a `shared&lowbar;ptr` object referring to and managing a new `ELEMENT&lowbar;TYPE` object&period; The default allocator will be used to supply a single contiguous region of memory holding the returned shared pointer&apos;s internal representation and the new `ELEMENT&lowbar;TYPE` object, which is initialized using the `ELEMENT&lowbar;TYPE` constructor that takes the specified arguments `std&colon;&colon;forward&lt;ARGS&gt;(args)&period;&period;&period;`&period; If `ELEMENT&lowbar;TYPE` uses `bslma` allocators, then the default allocator is passed as an extra argument in the final position&period;

== Return Value

shared pointer managing a newly created object

== Parameters

[cols="1,4"]
|===
| Name| Description
| *args*
| constructor arguments forwarded to the new object
|===


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