Namespaces
Variants

std::coroutine_handle<Promise>:: coroutine_handle

From cppreference.net
Utilities library
Coroutine support
Coroutine traits
Coroutine handle
No-op coroutines
Trivial awaitables
Range generators
(C++23)
constexpr coroutine_handle ( ) noexcept ;
(1) (C++20부터)
constexpr coroutine_handle ( std:: nullptr_t ) noexcept ;
(2) (C++20부터)
coroutine_handle ( const coroutine_handle & other ) = default ;
(3) (C++20부터)
coroutine_handle ( coroutine_handle && other ) = default ;
(4) (C++20부터)

코루틴을 참조하지 않는 coroutine_handle 을 생성하거나, coroutine_handle 을 복사합니다.

1,2) 기본 주소를 ptr 로 초기화합니다. 생성 후, address() nullptr 를 반환하며, 해당 coroutine_handle 는 코루틴을 참조하지 않습니다. 이러한 생성자들은 특수화 std:: coroutine_handle < std:: noop_coroutine_promise > 에 대해 선언되지 않습니다.
3,4) 기본 주소를 복사합니다. 복사 생성자와 이동 생성자는 암시적으로 선언된 것들과 동등합니다.

매개변수

other - 복사할 다른 coroutine_handle

참고 사항

std:: coroutine_handle < std:: noop_coroutine_promise > 는 기본 생성 가능하지도 않고 std::nullptr_t 로부터 생성 가능하지도 않습니다. std::noop_coroutine 를 사용하여 새로운 std:: coroutine_handle < std:: noop_coroutine_promise > 를 생성할 수 있습니다.

정적 멤버 함수 from_promise from_address coroutine_handle 를 생성할 수 있습니다.

참고 항목

코루틴의 promise 객체로부터 coroutine_handle 를 생성합니다
(public static member function)
포인터로부터 코루틴을 임포트합니다
(public static member function)
재개되거나 파괴될 때 관찰 가능한 효과가 없는 코루틴 핸들을 생성합니다
(function)