Namespaces
Variants

std:: uses_allocator <std::promise>

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
template < class R, class Alloc >
struct uses_allocator < std:: promise < R > , Alloc > : std:: true_type { } ;
(C++11 起)

std::uses_allocator 类型特征提供针对 std::promise 的特化版本。

目录

继承自 std:: integral_constant

成员常量

value
[static]
true
(公开静态成员常量)

成员函数

operator bool
将对象转换为 bool ,返回 value
(公开成员函数)
operator()
(C++14)
返回 value
(公开成员函数)

成员类型

类型 定义
value_type bool
type std:: integral_constant < bool , value >

参见

检查指定类型是否支持使用分配器构造
(类模板)