[#bsl-pair-0b-operator_assign-02]
= xref:bsl.adoc[bsl]::xref:bsl/pair-0b.adoc[pair]::operator&equals;
:relfileprefix: ../../
:mrdocs:

Assign to this `pair` from the specified `rhs` `std&colon;&colon;pair`&period;

== Synopsis

Declared in `&lt;bslstl&lowbar;pair&period;h&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
template&lt;
    class PARAM&lowbar;1,
    class PARAM&lowbar;2&gt;
constexpr
xref:bsl/pair-0b.adoc[pair&lt;T1, T2&gt;]&
operator&equals;(std::pair&lt;PARAM&lowbar;1, PARAM&lowbar;2&gt; const& rhs);
----

== Description

Assign to this `pair` from the specified `rhs` pair, where the type `rhs` is the pair type native to the compiler&apos;s library, holding the parameterized types `PARAM&lowbar;1` and `PARAM&lowbar;2`, and return a reference offering modifiable access to this object&period; Assign `first` the value in `rhs&period;first` and `second` the value in `rhs&period;second`&period; Attempted use of this assignment operator will not compile unless both `T1` and `T2` supply assignment operators, and `T1` is assignable from `PARAM&lowbar;1` and `T2` is assignable from `PARAM&lowbar;2`&period;

== Return Value

reference offering modifiable access to this object

== Parameters

[cols="1,4"]
|===
| Name| Description
| *rhs*
| pair whose members are assigned to this pair&apos;s members
|===


[.small]#Created with https://www.mrdocs.com[MrDocs]#
