[indirect.obs]

# 20 Memory management library [[mem]](./#mem)

## 20.4 Types for composite class design [[mem.composite.types]](mem.composite.types#indirect.obs)

### 20.4.1 Class template indirect [[indirect]](indirect#obs)

#### 20.4.1.6 Observers [indirect.obs]

[ð](#lib:operator*,indirect)

`constexpr const T& operator*() const & noexcept;
constexpr T& operator*() & noexcept;
`

[1](#1)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/memory.tex#L6547)

*Preconditions*: *this is not valueless[.](#1.sentence-1)

[2](#2)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/memory.tex#L6551)

*Returns*: **p*[.](#2.sentence-1)

[ð](#lib:operator*,indirect_)

`constexpr const T&& operator*() const && noexcept;
constexpr T&& operator*() && noexcept;
`

[3](#3)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/memory.tex#L6563)

*Preconditions*: *this is not valueless[.](#3.sentence-1)

[4](#4)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/memory.tex#L6567)

*Returns*: std​::​move(**p*)[.](#4.sentence-1)

[ð](#lib:operator-%3e,indirect)

`constexpr const_pointer operator->() const noexcept;
constexpr pointer operator->() noexcept;
`

[5](#5)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/memory.tex#L6579)

*Preconditions*: *this is not valueless[.](#5.sentence-1)

[6](#6)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/memory.tex#L6583)

*Returns*: *p*[.](#6.sentence-1)

[ð](#lib:valueless_after_move,indirect)

`constexpr bool valueless_after_move() const noexcept;
`

[7](#7)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/memory.tex#L6594)

*Returns*: true if *this is valueless, otherwise false[.](#7.sentence-1)

[ð](#lib:get_allocator,indirect)

`constexpr allocator_type get_allocator() const noexcept;
`

[8](#8)

[#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/memory.tex#L6605)

*Returns*: *alloc*[.](#8.sentence-1)
