std::experimental::ranges::Destructible
来自 cppreference.cn
< cpp | experimental | ranges
template< class T > concept bool Destructible = std::is_nothrow_destructible<T>::value; |
(范围 TS) | |
Destructible
概念明确指出所有类型,其所有实例可以在生命周期结束时安全地销毁(包括引用类型)。
Destructible<T>
和 std::is_nothrow_destructible<T>::value 之间不需要有任何 subsumption 关系。
[编辑] 注解
与主 C++ 标准中的 Destructible 具名要求不同,Destructible
要求析构函数为 noexcept(true),而不仅仅是在调用时不抛出异常,并且允许引用类型和数组类型。
[编辑] 参见
(C++11)(C++11)(C++11) |
检查类型是否具有非删除的析构函数 (类模板) |