std::coroutine_handle<Promise>::operator=
From cppreference.com
< C++ | coroutine | coroutine handle
| coroutine_handle& operator=( std::nullptr_t ) noexcept; |
(1) | (C++20以降) |
| coroutine_handle& operator=( const coroutine_handle& other ) = default; |
(2) | (C++20以降) |
| coroutine_handle& operator=( coroutine_handle&& other ) = default; |
(3) | (C++20以降) |
基になるアドレスを置き換えます。
1) 基になるアドレスをヌルポインタ値で置き換えます。代入後、*this はコルーチンを参照しません。この代入演算子は、特殊化 std::coroutine_handle<std::noop_coroutine_promise> に対しては宣言されていません。
2,3) 基になるアドレスを other のアドレスで置き換えます。コピー代入演算子およびムーブ代入演算子は、暗黙宣言されたものと同等です。
[編集] パラメータ
| その他 | - | 代入元となる別のcoroutine_handle |
[編集] 戻り値
*this