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-exception
6 //
7 //===----------------------------------------------------------------------===//
8
9 // https://llvm.org/PR41018
10 // XFAIL: windows-dll && msvc
11
12 // <locale>
13
14 // template <class charT, class Traits, class Allocator>
15 // bool operator()(const basic_string<charT,Traits,Allocator>& s1,
16 // const basic_string<charT,Traits,Allocator>& s2) const;
17
18 #include <locale>
19 #include <cassert>
20
21 #include "test_macros.h"
22
main(int,char **)23 int main(int, char**)
24 {
25 {
26 std::locale l;
27 {
28 std::string s2("aaaaaaA");
29 std::string s3("BaaaaaA");
30 assert(l(s3, s2));
31 }
32 #ifndef TEST_HAS_NO_WIDE_CHARACTERS
33 {
34 std::wstring s2(L"aaaaaaA");
35 std::wstring s3(L"BaaaaaA");
36 assert(l(s3, s2));
37 }
38 #endif
39 }
40
41 return 0;
42 }
43