summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--libcxx/include/string94
1 files changed, 2 insertions, 92 deletions
diff --git a/libcxx/include/string b/libcxx/include/string
index 3f2fe17484e..91d6d30dc93 100644
--- a/libcxx/include/string
+++ b/libcxx/include/string
@@ -3507,24 +3507,6 @@ operator==(const _CharT* __lhs,
return __rhs.compare(__lhs) == 0;
}
-template<class _Allocator>
-_LIBCPP_INLINE_VISIBILITY inline
-bool
-operator==(const char* __lhs,
- const basic_string<char, char_traits<char>, _Allocator>& __rhs) _NOEXCEPT
-{
- return strcmp(__lhs, __rhs.data()) == 0;
-}
-
-template<class _Allocator>
-_LIBCPP_INLINE_VISIBILITY inline
-bool
-operator==(const wchar_t* __lhs,
- const basic_string<wchar_t, char_traits<wchar_t>, _Allocator>& __rhs) _NOEXCEPT
-{
- return wcscmp(__lhs, __rhs.data()) == 0;
-}
-
template<class _CharT, class _Traits, class _Allocator>
_LIBCPP_INLINE_VISIBILITY inline
bool
@@ -3534,24 +3516,6 @@ operator==(const basic_string<_CharT,_Traits,_Allocator>& __lhs,
return __lhs.compare(__rhs) == 0;
}
-template<class _Allocator>
-_LIBCPP_INLINE_VISIBILITY inline
-bool
-operator==(const basic_string<char, char_traits<char>, _Allocator>& __lhs,
- const char* __rhs) _NOEXCEPT
-{
- return strcmp(__lhs.data(), __rhs) == 0;
-}
-
-template<class _Allocator>
-_LIBCPP_INLINE_VISIBILITY inline
-bool
-operator==(const basic_string<wchar_t, char_traits<wchar_t>, _Allocator>& __lhs,
- const wchar_t* __rhs) _NOEXCEPT
-{
- return wcscmp(__lhs.data(), __rhs) == 0;
-}
-
// operator!=
template<class _CharT, class _Traits, class _Allocator>
@@ -3589,25 +3553,7 @@ bool
operator< (const basic_string<_CharT, _Traits, _Allocator>& __lhs,
const basic_string<_CharT, _Traits, _Allocator>& __rhs) _NOEXCEPT
{
- return __lhs.cmpare(__rhs) < 0;
-}
-
-template<class _Allocator>
-_LIBCPP_INLINE_VISIBILITY inline
-bool
-operator< (const basic_string<char, char_traits<char>, _Allocator>& __lhs,
- const basic_string<char, char_traits<char>, _Allocator>& __rhs) _NOEXCEPT
-{
- return strcmp(__lhs.data(), __rhs.data()) < 0;
-}
-
-template<class _Allocator>
-_LIBCPP_INLINE_VISIBILITY inline
-bool
-operator< (const basic_string<wchar_t, char_traits<wchar_t>, _Allocator>& __lhs,
- const basic_string<wchar_t, char_traits<wchar_t>, _Allocator>& __rhs) _NOEXCEPT
-{
- return wcscmp(__lhs.data(), __rhs.data()) < 0;
+ return __lhs.compare(__rhs) < 0;
}
template<class _CharT, class _Traits, class _Allocator>
@@ -3616,25 +3562,7 @@ bool
operator< (const basic_string<_CharT, _Traits, _Allocator>& __lhs,
const _CharT* __rhs) _NOEXCEPT
{
- return __lhs.compare(__rhs);
-}
-
-template<class _Allocator>
-_LIBCPP_INLINE_VISIBILITY inline
-bool
-operator< (const basic_string<char, char_traits<char>, _Allocator>& __lhs,
- const char* __rhs) _NOEXCEPT
-{
- return strcmp(__lhs.data(), __rhs) < 0;
-}
-
-template<class _Allocator>
-_LIBCPP_INLINE_VISIBILITY inline
-bool
-operator< (const basic_string<wchar_t, char_traits<wchar_t>, _Allocator>& __lhs,
- const wchar_t* __rhs) _NOEXCEPT
-{
- return wcscmp(__lhs.data(), __rhs) < 0;
+ return __lhs.compare(__rhs) < 0;
}
template<class _CharT, class _Traits, class _Allocator>
@@ -3646,24 +3574,6 @@ operator< (const _CharT* __lhs,
return __rhs.compare(__lhs) > 0;
}
-template<class _Allocator>
-_LIBCPP_INLINE_VISIBILITY inline
-bool
-operator< (const char* __lhs,
- const basic_string<char, char_traits<char>, _Allocator>& __rhs) _NOEXCEPT
-{
- return strcmp(__lhs, __rhs.data()) < 0;
-}
-
-template<class _Allocator>
-_LIBCPP_INLINE_VISIBILITY inline
-bool
-operator< (const wchar_t* __lhs,
- const basic_string<wchar_t, char_traits<wchar_t>, _Allocator>& __rhs) _NOEXCEPT
-{
- return wcscmp(__lhs, __rhs.data()) < 0;
-}
-
// operator>
template<class _CharT, class _Traits, class _Allocator>
OpenPOWER on IntegriCloud