Assignment operator.

Synopsis

Declared in <beman/optional/optional.hpp>

constexpr
optional&
operator=(optional const& rhs) noexcept = default;

Description

If rhs has a value, assigns it to the stored value. Otherwise resets the stored value in *this.

Return Value

optional&

Created with MrDocs