[#boost-urls-grammar-recycled_ptr-operator_assign-09]
= xref:boost/urls/grammar/recycled_ptr/operator_assign-09.adoc[boost::urls::grammar::recycled&lowbar;ptr::operator&equals;]
:relfileprefix: ../../../../
:mrdocs:

Assignment

== Synopsis

Declared in `&lt;https://www.github.com/boostorg/url/blob/develop/include/boost/url/grammar/recycled.hpp#L395[boost&sol;url&sol;grammar&sol;recycled&period;hpp]&gt;`

[source,cpp,subs="verbatim,replacements,macros,-callouts"]
----
xref:boost/urls/grammar/recycled_ptr.adoc[recycled&lowbar;ptr]&
operator&equals;(xref:boost/urls/grammar/recycled_ptr.adoc[recycled&lowbar;ptr] const& other) noexcept;
----

== Description

If `other` references an object, this acquires shared ownership and references the same recycle bin as `other`&period; The previous object if any is released&period;

== Effects
[,cpp]
----
this->release()
----
== Postconditions
[,cpp]
----
&this->bin() == &other->bin() && this->get() == other.get()
----
== Exception Safety
Throws nothing&period;

== Return Value

`&ast;this`

== Parameters

[cols=2]
|===
| Name
| Description
| *other*
| The pointer to copy from
|===


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