[unique.ptr.single.dtor]

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

## 20.3 Smart pointers [[smartptr]](smartptr#unique.ptr.single.dtor)

### 20.3.1 Unique-ownership pointers [[unique.ptr]](unique.ptr#single.dtor)

#### 20.3.1.3 unique_ptr for single objects [[unique.ptr.single]](unique.ptr.single#dtor)

#### 20.3.1.3.3 Destructor [unique.ptr.single.dtor]

[ð](#lib:unique_ptr,destructor)

`constexpr ~unique_ptr();
`

[1](#1)

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

*Effects*: Equivalent to:if (get()) get_deleter()(get());

[*Note [1](#note-1)*:

The use of default_delete requires T to be a complete type[.](#1.sentence-1)

â *end note*]

[2](#2)

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

*Remarks*: The behavior is undefined
if the evaluation of get_deleter()(get()) throws an exception[.](#2.sentence-1)
