std::ranges::not_equal_to
来自cppreference.com
                    
                                        
                    < cpp | utility | functional
                    
                                                            
                    |   定义于头文件  <functional>
  | 
||
|   struct not_equal_to;  | 
(C++20 起) | |
进行比较的函数对象。从实参推导函数调用运算符的形参类型(但非返回类型)。
成员类型
| 成员类型 | 定义 | 
  is_transparent
 | 
/* 未指定 */ | 
成员函数
|    operator()  | 
  检查参数是否不相等  (公开成员函数)  | 
std::ranges::not_equal_to::operator()
|   template< class T, class U >     requires std::equality_comparable_with<T, U> ||  | 
||
比较 t 与 u 。等价于 return !ranges::equal_to{}(std::forward<T>(t), std::forward<U>(u)); 。
注意
不同于 std::not_equal_to , std::ranges::not_equal_to 要求 == 与 != 均合法(经由 equality_comparable_with 制约),并且完全以 std::ranges::equal_to 定义。然而,实现有直接使用 operator!= 的自由,因为那些概念要求 == 与 != 的结果一致。
示例
| 本节未完成 原因:暂无示例  | 
参阅
|   实现 x != y 的函数对象  (类模板)  |