brintos

brintos / llvm-project-archived public Read only

0
0
Text · 1.3 KiB · a8caf5b Raw
47 lines · c
1//===----------------------------------------------------------------------===//2//3// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.4// See https://llvm.org/LICENSE.txt for license information.5// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception6//7//===----------------------------------------------------------------------===//8 9#ifndef _LIBCPP___UTILITY_REL_OPS_H10#define _LIBCPP___UTILITY_REL_OPS_H11 12#include <__config>13 14#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)15#  pragma GCC system_header16#endif17 18_LIBCPP_BEGIN_NAMESPACE_STD19 20namespace rel_ops {21 22template <class _Tp>23inline _LIBCPP_DEPRECATED_IN_CXX20 _LIBCPP_HIDE_FROM_ABI bool operator!=(const _Tp& __x, const _Tp& __y) {24  return !(__x == __y);25}26 27template <class _Tp>28inline _LIBCPP_DEPRECATED_IN_CXX20 _LIBCPP_HIDE_FROM_ABI bool operator>(const _Tp& __x, const _Tp& __y) {29  return __y < __x;30}31 32template <class _Tp>33inline _LIBCPP_DEPRECATED_IN_CXX20 _LIBCPP_HIDE_FROM_ABI bool operator<=(const _Tp& __x, const _Tp& __y) {34  return !(__y < __x);35}36 37template <class _Tp>38inline _LIBCPP_DEPRECATED_IN_CXX20 _LIBCPP_HIDE_FROM_ABI bool operator>=(const _Tp& __x, const _Tp& __y) {39  return !(__x < __y);40}41 42} // namespace rel_ops43 44_LIBCPP_END_NAMESPACE_STD45 46#endif // _LIBCPP___UTILITY_REL_OPS_H47