[#bsl-allocator_traits-0ae-max_size]
= xref:bsl.adoc[bsl]::xref:bsl/allocator_traits-0ae.adoc[allocator&lowbar;traits&lt;std::allocator&lt;ALLOCATOR&lowbar;TYPE&gt;&gt;]::max&lowbar;size
:relfileprefix: ../../
:mrdocs:

The maximum supported allocation size

== Synopsis

Declared in `&lt;bslma&lowbar;allocatortraits&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
constexpr
static
size&lowbar;type
max&lowbar;size(&lowbar;Alloc const& &lowbar;&lowbar;a) noexcept;
----

== Description

Returns `&lowbar;&lowbar;a&period;max&lowbar;size()` if that expression is well&hyphen;formed, otherwise returns `numeric&lowbar;limits&lt;size&lowbar;type&gt;&colon;&colon;max()`

== Return Value

`&lowbar;&lowbar;a&period;max&lowbar;size()` or `numeric&lowbar;limits&lt;size&lowbar;type&gt;&colon;&colon;max()`

== Parameters

[cols="1,4"]
|===
| Name| Description
| *&lowbar;&lowbar;a*
| An allocator&period;
|===


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