[string.cmp] # 27 Strings library [[strings]](./#strings) ## 27.4 String classes [[string.classes]](string.classes#string.cmp) ### 27.4.4 Non-member functions [[string.nonmembers]](string.nonmembers#string.cmp) #### 27.4.4.2 Non-member comparison operator functions [string.cmp] [🔗](#itemdecl:1) `template constexpr bool operator==(const basic_string& lhs, const basic_string& rhs) noexcept; template constexpr bool operator==(const basic_string& lhs, const charT* rhs); template constexpr see below operator<=>(const basic_string& lhs, const basic_string& rhs) noexcept; template constexpr see below operator<=>(const basic_string& lhs, const charT* rhs); ` [1](#1) [#](http://github.com/Eelis/draft/tree/9adde4bc1c62ec234483e63ea3b70a59724c745a/source/strings.tex#L4980) *Effects*: Let *op* be the operator[.](#1.sentence-1) Equivalent to:return basic_string_view(lhs) *op* basic_string_view(rhs);