11---
22title : " locale Class"
3- ms.date : " 03/19/2019 "
3+ ms.date : " 07/20/2020 "
44f1_keywords : ["xlocale/std::locale", "xlocale/std::locale::category", "xlocale/std::locale::combine", "xlocale/std::locale::name", "xlocale/std::locale::classic", "xlocale/std::locale::global", "xlocale/std::locale::operator( )", "xlocale/std::locale::facet", "xlocale/std::locale::id"]
55helpviewer_keywords : ["std::locale [C++]", "std::locale [C++], category", "std::locale [C++], combine", "std::locale [C++], name", "std::locale [C++], classic", "std::locale [C++], global", "std::locale [C++], facet", "std::locale [C++], id"]
66ms.assetid : 7dd6d271-472d-4750-8fb5-ea8f55fbef62
@@ -599,7 +599,7 @@ loc3 (English_United States.1252) are not equal.
599599
600600## <a name =" op_call " ></a > locale::operator()
601601
602- Compares two ` basic_string ` objects.
602+ Compares two ` basic_string ` objects according to the lexicographic comparison rules defined by this locale's std::collate< charT > facet .
603603
604604``` cpp
605605template <class CharType , class Traits, class Allocator>
@@ -611,20 +611,14 @@ bool operator()(
611611### Parameters
612612
613613*left*\
614- The left string.
614+ The first string to compare .
615615
616616*right*\
617- The right string.
617+ The second string to compare .
618618
619619### Return Value
620620
621- The member function returns:
622-
623- - -1 if the first sequence compares less than the second sequence.
624-
625- - +1 if the second sequence compares less than the first sequence.
626-
627- - 0 if the sequences are equivalent.
621+ - `true` if *left* is lexicographically less than *right*, otherwise `false`.
628622
629623### Remarks
630624
@@ -650,8 +644,8 @@ It means you can use a locale object as a function object.
650644int main ( )
651645{
652646 using namespace std;
653- wchar_t * sa = L"ztesting";
654- wchar_t * sb = L"\0x00DFtesting";
647+ const wchar_t * sa = L"ztesting";
648+ const wchar_t * sb = L"\0x00DFtesting";
655649 basic_string<wchar_t> a( sa );
656650 basic_string<wchar_t> b( sb );
657651
0 commit comments