
std:: async - cppreference.com
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 eventually hold the result of …
std:: future - cppreference.com
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. The creator of the asynchronous …
Coroutines (C++20) - cppreference.com
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 is required to resume execution is …
std::launch - cppreference.com
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 by the standard library:
Extensions for networking - cppreference.com
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 the C++14 standard as modified …
std::mutex - cppreference.com
The mutex class is a synchronization primitive that can be used to protect shared data from being simultaneously accessed by multiple threads. mutex offers exclusive, non-recursive ownership …
Standard library header <future> (C++11) - cppreference.com
Nov 27, 2023 · async = /* unspecified */, deferred = /* unspecified */, /* implementation-defined */ }; enum class future_status { ready, timeout, deferred }; template<> struct is_error_code_enum …
std::this_thread::sleep_for - cppreference.com
Blocks the execution of the current thread for at least the specified sleep_duration. This function may block for longer than sleep_duration due to scheduling or resource contention delays. The standard …
std::unique_lock - cppreference.com
The class unique_lock is a general-purpose mutex ownership wrapper allowing deferred locking, time-constrained attempts at locking, recursive locking, transfer of lock ownership, and use with condition …
std::signal - cppreference.com
Notes POSIX requires that signal is thread-safe, and specifies a list of async-signal-safe library functions that may be called from any signal handler. Signal handlers are expected to have C linkage and, in …