##### cppreference.com

##### Search

Create account

##### Namespaces

- Page
- Discussion

##### Variants

##### Views

- View
- Edit
- History

##### Actions

# std::scoped_allocator_adaptor::outer_allocator

From cppreference.com
< cpp‎ | memory‎ | scoped allocator adaptor

Defined in header `<scoped_allocator>` |  |
outer_allocator_type& outer_allocator(); | (1) | (since C++11)
const outer_allocator_type& outer_allocator() const; | (2) | (since C++11)

Obtains a reference to the outer allocator used to declare this class.

1) returns static_cast<OuterAlloc&>(*this)

2) returns static_cast<const OuterAlloc&>(*this)

### [edit] Parameters

(none)

### [edit] Return value

A reference to `OuterAlloc`

### [edit] Exceptions

1-2)
`noexcept` specification:
noexcept

### [edit] See also

inner_allocator | obtains an `inner_allocator` reference (public member function) [edit]

Retrieved from "http://en.cppreference.com/mwiki/index.php?title=cpp/memory/scoped_allocator_adaptor/outer_allocator&oldid=91436"
Category:

- unconditionally noexcept

Hidden categories:

- Pages with unreviewed unconditional noexcept template
- Pages with unreviewed noexcept template