Namespaces
Variants

std::shared_future<T>:: shared_future

From cppreference.net
Concurrency support library
Threads
(C++11)
(C++20)
this_thread namespace
(C++11)
(C++11)
Cooperative cancellation
Mutual exclusion
Generic lock management
Condition variables
(C++11)
Semaphores
Latches and Barriers
(C++20)
(C++20)
Futures
(C++11)
(C++11)
(C++11)
Safe reclamation
Hazard pointers
Atomic types
(C++11)
(C++20)
Initialization of atomic types
(C++11) (deprecated in C++20)
(C++11) (deprecated in C++20)
Memory ordering
(C++11) (deprecated in C++26)
Free functions for atomic operations
Free functions for atomic flags
shared_future ( ) noexcept ;
(1) (desde C++11)
(2)
shared_future ( const shared_future & other ) ;
(desde C++11)
(hasta C++17)
shared_future ( const shared_future & other ) noexcept ;
(desde C++17)
shared_future ( std:: future < T > && other ) noexcept ;
(3) (desde C++11)
shared_future ( shared_future && other ) noexcept ;
(4) (desde C++11)

Construye un nuevo shared_future .

1) Constructor por defecto. Construye un shared future vacío, que no hace referencia a un estado compartido, es decir valid ( ) == false .
2) Construye un futuro compartido que hace referencia al mismo estado compartido, si existe, que other .
3,4) Transfiere el estado compartido mantenido por other a * this . Después de la construcción, other. valid ( ) == false , y this - > valid ( ) retorna el mismo valor que other. valid ( ) habría retornado antes de la construcción.

Parámetros

otro - otro objeto futuro con el que inicializar