Namespaces
Variants

cpp/utility/functional/reference wrapper/operator=: Difference between revisions

From cppreference.com
P12bot (talk | contribs)
m Shorten template names. Use {{lc}} where appropriate.
Space Mission (talk | contribs)
m {{mark constexpr since c++20}}
 
(5 intermediate revisions by 4 users not shown)
Line 1: Line 1:
{{cpp/utility/functional/reference_wrapper/title|operator{{=}}}}
{{cpp/utility/functional/reference_wrapper/title|operator{{=}}}}
{{cpp/utility/functional/reference_wrapper/navbar}}
{{cpp/utility/functional/reference_wrapper/navbar}}
{{ddcl | notes={{mark since c++11}} | 1=
{{ddcl|notes={{mark since c++}}|1=
reference_wrapper& operator=( const reference_wrapper<T>& other );
reference_wrapper& operator=( const reference_wrapper& other ) ;
}}
}}


Line 9: Line 9:
===Parameters===
===Parameters===
{{par begin}}
{{par begin}}
{{par | other | reference wrapper to copy}}
{{par|other|reference wrapper to copy}}
{{par end}}
{{par end}}


===Return values===
===Return ===
{{c|*this}}
{{c|*this}}


===Exceptions===
{{deesfritjaptruzh
{{noexcept}}
 
[[de:cpp/utility/functional/reference wrapper/operator=]]
[[es:cpp/utility/functional/reference wrapper/operator=]]
[[fr:cpp/utility/functional/reference wrapper/operator=]]
[[it:cpp/utility/functional/reference wrapper/operator=]]
[[ja:cpp/utility/functional/reference wrapper/operator=]]
[[pt:cpp/utility/functional/reference wrapper/operator=]]
[[ru:cpp/utility/functional/reference wrapper/operator=]]
[[zh:cpp/utility/functional/reference wrapper/operator=]]

Latest revision as of 22:35, 17 April 2024

 
 
Utilities library
General utilities
Relational operators (deprecated in C++20)
 
Function objects
Function invocation
(C++17)(C++23)
Identity function object
(C++20)
Transparent operator wrappers
(C++14)
(C++14)
(C++14)
(C++14)  
(C++14)
(C++14)
(C++14)
(C++14)
(C++14)
(C++14)
(C++14)
(C++14)
(C++14)

Old binders and adaptors
(until C++17*)
(until C++17*)
(until C++17*)
(until C++17*)  
(until C++17*)
(until C++17*)(until C++17*)(until C++17*)(until C++17*)
(until C++20*)
(until C++20*)
(until C++17*)(until C++17*)
(until C++17*)(until C++17*)

(until C++17*)
(until C++17*)(until C++17*)(until C++17*)(until C++17*)
(until C++20*)
(until C++20*)
 
 
reference_wrapper& operator=( const reference_wrapper& other ) noexcept;
(since C++11)
(constexpr since C++20)

Copy assignment operator. Drops the current reference and stores a reference to other.get().

Parameters

other - reference wrapper to copy

Return value

*this