Section

std::future_errc

The scoped enumeration std::future_errc defines the error codes reported by std::future and related classes in std::future_error exception objects. Only four error codes are required, although the implementation may define additional error codes. Because the appropriate specialization of std::is_error_code_enum is provided, values of type std::future_errc are implicitly convertible to std::error_code.

# Declarations

enum class future_errc {
broken_promise = /* implementation-defined */,
future_already_retrieved = /* implementation-defined */,
promise_already_satisfied = /* implementation-defined */,
no_state = /* implementation-defined */
};

(since C++11)

# Example

This section is incompleteReason: no example

# Defect reports

DRApplied toBehavior as publishedCorrect behavior
LWG 2056C++11broken_promise was specified to be zero which is conventionally used to mean “no error”specified to be non-zero

# See also