[#BloombergLP-bslstl-SharedPtrArrayAllocateInplaceRep-alloc_size]
= xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bslstl.adoc[bslstl]::xref:BloombergLP/bslstl/SharedPtrArrayAllocateInplaceRep.adoc[SharedPtrArrayAllocateInplaceRep]::alloc&lowbar;size
:relfileprefix: ../../../
:mrdocs:

Return the allocation size in bytes for a representation of the given size&period;

== Synopsis

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

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
static
size&lowbar;t
alloc&lowbar;size(size&lowbar;t numElements);
----

== Description

Return the size (in bytes) for an allocation to hold an object of type `SharedPtrArrayAllocateInplaceRep&lt;T&lsqb;&rsqb;&gt;` containing the specified `numElements` number of elements&period;

== Return Value

allocation size in bytes for a representation of the given size

== Parameters

[cols="1,4"]
|===
| Name| Description
| *numElements*
| number of array elements to reserve space for
|===


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