命名空间
变体
操作

std::equal_to, not_equal_to, less, greater, less_equal, greater_equal(std::experimental::propagate_const)

来自 cppreference.cn
 
 
实验性
技术规范
文件系统库 (filesystem TS)
库基础 (library fundamentals TS)
库基础 2 (library fundamentals TS v2)
库基础 3 (library fundamentals TS v3)
并行性扩展 (parallelism TS)
并行性扩展 2 (parallelism TS v2)
并发性扩展 (concurrency TS)
并发性扩展 2 (concurrency TS v2)
概念 (concepts TS)
范围 (ranges TS)
反射 (reflection TS)
数学特殊函数 (special functions TR)
实验性非 TS
模式匹配
线性代数
std::execution
契约
2D 图形
 
 
 
template< class T > struct equal_to<std::experimental::propagate_const<T>>;
(library fundamentals TS v2)
template< class T > struct not_equal_to<std::experimental::propagate_const<T>>;
(library fundamentals TS v2)
template< class T > struct less<std::experimental::propagate_const<T>>;
(library fundamentals TS v2)
template< class T > struct greater<std::experimental::propagate_const<T>>;
(library fundamentals TS v2)
template< class T > struct less_equal<std::experimental::propagate_const<T>>;
(library fundamentals TS v2)
template< class T > struct greater_equal<std::experimental::propagate_const<T>>;
(library fundamentals TS v2)

标准比较函数对象为 std::experimental::propagate_const<T> 进行了部分特化。

p.t_ 表示由 std::experimental::propagate_const<T> p 包装的类指针对象,则给定类型为 std::experimental::propagate_const<T> 的对象 pq,以下条件成立

[编辑] 注释

这些特化确保当 T 是指针类型时,这些类模板对于 std::experimental::propagate_const<T> 的特化会产生全序关系,即使对应的内建运算符不产生全序关系。

[编辑] 示例

[编辑] 参见

实现 x == y 的函数对象
(类模板) [编辑]
实现 x != y 的函数对象
(类模板) [编辑]
实现 x < y 的函数对象
(类模板) [编辑]
实现 x > y 的函数对象
(类模板) [编辑]
实现 x <= y 的函数对象
(类模板) [编辑]
实现 x >= y 的函数对象
(类模板) [编辑]