Skip to content

Commit ef85b0e

Browse files
committed
Simplify test even more
1 parent 36eac25 commit ef85b0e

File tree

1 file changed

+2
-12
lines changed

1 file changed

+2
-12
lines changed

libcxx/test/std/re/re.traits/getloc.pass.cpp

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -23,20 +23,10 @@
2323

2424
int main(int, char**) {
2525
std::fprintf(stderr, "Entering main()\n");
26-
{
27-
std::regex_traits<char> t;
28-
std::fprintf(stderr, "Running t.getloc()\n");
29-
assert(t.getloc().name() == "C");
30-
}
3126
{
3227
std::fprintf(stderr, "Creating locale\n");
33-
std::locale loc(LOCALE_en_US_UTF_8);
34-
35-
std::fprintf(stderr, "Setting locale globally\n");
36-
std::locale::global(loc);
37-
std::regex_traits<char> t;
38-
std::fprintf(stderr, "Running t.getloc()\n");
39-
assert(t.getloc().name() == LOCALE_en_US_UTF_8);
28+
std::locale loc("en_US.UTF-8");
29+
(void)loc;
4030
}
4131
return 0;
4232
}

0 commit comments

Comments
 (0)