[#bsl-optional-072-operator_assign-09] = xref:bsl.adoc[bsl]::xref:bsl/optional-072.adoc[optional]::operator= :relfileprefix: ../../ :mrdocs: Assign a new value to this optional. == Synopsis Declared in `<bslstl_optional.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- constexpr xref:bsl/optional-072.adoc[optional<t_TYPE>]& operator=(xref:bsl/nullopt_t.adoc[bsl::nullopt_t] nullopt) noexcept; ---- == Description Reset this object to be disengaged and return a reference providing modifiable access to this object. This assignment operator can be called in constant expressions only when `t_TYPE` is not allocator‐aware. == Return Value reference providing modifiable access to this object == Parameters [cols="1,4"] |=== | Name| Description | *nullopt* | disengaged‐optional tag; value is unused |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#