
std::async - cppreference.com
Oct 28, 2024 · The function template std::async runs the function f asynchronously (potentially in a separate thread which might be a part of a thread pool) and returns a std::future that will …
std::future - cppreference.com
Mar 12, 2024 · An asynchronous operation (created via std::async, std::packaged_task, or std::promise) can provide a std::future object to the creator of that asynchronous operation. …
Coroutines (C++20) - cppreference.com
Mar 5, 2025 · A coroutine is a function that can suspend execution to be resumed later. Coroutines are stackless: they suspend execution by returning to the caller, and the data that …
std::future<T>:: wait_for - cppreference.com
Aug 27, 2021 · If the future is the result of a call to std::async that used lazy evaluation, this function returns immediately without waiting. This function may block for longer than …
std::launch - cppreference.com
Mar 19, 2025 · std::launch is a BitmaskType. It specifies the launch policy for a task executed by the std::async function. Constants The following constants denoting individual bits are defined …
std::shared_future - cppreference.com
Oct 23, 2023 · The class template std::shared_future provides a mechanism to access the result of asynchronous operations, similar to std::future, except that multiple threads are allowed to …
Standard library header <future> (C++11) - cppreference.com
Nov 27, 2023 · namespace std { enum class future_errc { broken_promise = /* implementation-defined */, future_already_retrieved = /* implementation-defined */, promise_already ...
Concurrency support library (since C++11) - cppreference.com
Apr 29, 2025 · Futures The standard library provides facilities to obtain values that are returned and to catch exceptions that are thrown by asynchronous tasks (i.e. functions launched in …
Extensions for networking - cppreference.com
Sep 11, 2023 · The C++ Extensions for Networking, ISO/IEC TS 19216:2018, defines new components for the C++ standard library listed on this page. The Networking TS is based on …
std::shared_future<T>::wait_for - cppreference.com
Aug 28, 2021 · Waits for the result to become available. Blocks until specified timeout_duration has elapsed or the result becomes available, whichever comes first. The return value identifies …