Commit b04601b9 authored by Vladislav Shchapov's avatar Vladislav Shchapov Committed by Victor Zverovich

Switch from std::strftime/std::wcsftime to internal implementation for locale independent formats

parent d3d30a46
This diff is collapsed.
...@@ -91,13 +91,15 @@ TEST(chrono_test, format_tm_past) { ...@@ -91,13 +91,15 @@ TEST(chrono_test, format_tm_past) {
"The date is -101-04-25 11:22:33."); "The date is -101-04-25 11:22:33.");
EXPECT_EQ(fmt::format("{:%Y}", tm), "-101"); EXPECT_EQ(fmt::format("{:%Y}", tm), "-101");
// macOS %C - "-1" // macOS %C - "-1"
// Linux %C - "-2" // Linux %C - "-2"
// EXPECT_EQ(fmt::format("{:%C}", tm), "-1"); // Simple impl %C - "-1"
EXPECT_EQ(fmt::format("{:%C}", tm), "-1");
// macOS %D - "04/25/01" (%y)
// Linux %D - "04/25/99" (%y) // macOS %D - "04/25/01" (%y)
// EXPECT_EQ(fmt::format("{:%D}", tm), "04/25/01"); // Linux %D - "04/25/99" (%y)
// Simple impl %D - "04/25/01" (%y)
EXPECT_EQ(fmt::format("{:%D}", tm), "04/25/01");
EXPECT_EQ(fmt::format("{:%F}", tm), "-101-04-25"); EXPECT_EQ(fmt::format("{:%F}", tm), "-101-04-25");
EXPECT_EQ(fmt::format("{:%T}", tm), "11:22:33"); EXPECT_EQ(fmt::format("{:%T}", tm), "11:22:33");
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment