From c16eab6af4607cabeea49af921e6ec6afb0eff88 Mon Sep 17 00:00:00 2001 From: "Stephan T. Lavavej" Date: Sat, 17 Apr 2021 21:26:10 -0700 Subject: [PATCH 1/2] Add/test weekday_last, month_weekday, month_weekday_last. * In _Fill_tm(): + weekday_indexed and weekday_last can share code. + month_weekday and month_weekday_last have different accessors. + Cleanup: Unify the code for year_month_weekday and year_month_weekday_last. * In _Is_valid_type(): + weekday, weekday_indexed, and weekday_last all support the "weekday types". + month_weekday and month_weekday_last support "month types" and "weekday types". (As mentioned above, their accessors are actually weekday_indexed() and weekday_last(), but it seemed pointless to have separate cases to "recurse" into the weekday_indexed and weekday_last types, when the answer is always the same.) + Remove TRANSITION and change the final static_assert to "should be unreachable", which is the pattern that we use elsewhere. * Add the new formatters, all powered by _Fill_tm_formatter. In P0355R7_calendars_and_time_zones_formatting/test.cpp: * Rename charT to CharT for consistency (this is needed by the STR macro, if it were ever used in these functions). * Add empty_braces_helper() to test both format("{}") and operator<<. This should supersede stream_helper() but I'm not making that change here. * Test the new types. * Implement tests for year_month_day_last, year_month_weekday, and year_month_weekday_last now that the necessary formatters are available. * Call the new test functions. --- stl/inc/chrono | 34 +++-- .../test.cpp | 141 ++++++++++++++++-- 2 files changed, 153 insertions(+), 22 deletions(-) diff --git a/stl/inc/chrono b/stl/inc/chrono index 5cd18ec27d0..cc33b40ac0b 100644 --- a/stl/inc/chrono +++ b/stl/inc/chrono @@ -5488,7 +5488,7 @@ namespace chrono { _Year = static_cast(_Val); } else if constexpr (is_same_v<_Ty, weekday>) { _Weekday = static_cast(_Val.c_encoding()); - } else if constexpr (is_same_v<_Ty, weekday_indexed>) { + } else if constexpr (_Is_any_of_v<_Ty, weekday_indexed, weekday_last>) { _Weekday = static_cast(_Val.weekday().c_encoding()); } else if constexpr (is_same_v<_Ty, month_day>) { _Day = static_cast(_Val.day()); @@ -5496,6 +5496,12 @@ namespace chrono { } else if constexpr (is_same_v<_Ty, month_day_last>) { _Month = static_cast(_Val.month()); _Day = static_cast(_Last_day_table[(_Month - 1) & 0xF]); + } else if constexpr (is_same_v<_Ty, month_weekday>) { + _Month = static_cast(_Val.month()); + _Weekday = static_cast(_Val.weekday_indexed().weekday().c_encoding()); + } else if constexpr (is_same_v<_Ty, month_weekday_last>) { + _Month = static_cast(_Val.month()); + _Weekday = static_cast(_Val.weekday_last().weekday().c_encoding()); } else if constexpr (is_same_v<_Ty, year_month>) { _Month = static_cast(_Val.month()); _Year = static_cast(_Val.year()); @@ -5509,12 +5515,7 @@ namespace chrono { _Month = static_cast(_Val.month()); _Year = static_cast(_Val.year()); _Weekday = year_month_day{_Val}._Calculate_weekday(); - } else if constexpr (is_same_v<_Ty, year_month_weekday>) { - _Day = static_cast(year_month_day{_Val}.day()); - _Month = static_cast(_Val.month()); - _Year = static_cast(_Val.year()); - _Weekday = static_cast(_Val.weekday().c_encoding()); - } else if constexpr (is_same_v<_Ty, year_month_weekday_last>) { + } else if constexpr (_Is_any_of_v<_Ty, year_month_weekday, year_month_weekday_last>) { _Day = static_cast(year_month_day{_Val}.day()); _Month = static_cast(_Val.month()); _Year = static_cast(_Val.year()); @@ -5785,10 +5786,12 @@ struct _Chrono_formatter { return _Type == 'b' || _Type == 'B' || _Type == 'h' || _Type == 'm'; } else if constexpr (is_same_v<_Ty, _CHRONO year>) { return _Type == 'Y' || _Type == 'y' || _Type == 'C'; - } else if constexpr (_Is_any_of_v<_Ty, _CHRONO weekday, _CHRONO weekday_indexed>) { + } else if constexpr (_Is_any_of_v<_Ty, _CHRONO weekday, _CHRONO weekday_indexed, _CHRONO weekday_last>) { return _Type == 'a' || _Type == 'A' || _Type == 'u' || _Type == 'w'; } else if constexpr (_Is_any_of_v<_Ty, _CHRONO month_day, _CHRONO month_day_last>) { return _Is_valid_type<_CHRONO month>(_Type) || _Is_valid_type<_CHRONO day>(_Type); + } else if constexpr (_Is_any_of_v<_Ty, _CHRONO month_weekday, _CHRONO month_weekday_last>) { + return _Is_valid_type<_CHRONO month>(_Type) || _Is_valid_type<_CHRONO weekday>(_Type); } else if constexpr (is_same_v<_Ty, _CHRONO year_month>) { return _Is_valid_type<_CHRONO year>(_Type) || _Is_valid_type<_CHRONO month>(_Type); } else if constexpr (_Is_any_of_v<_Ty, _CHRONO year_month_day, _CHRONO year_month_day_last, @@ -5808,8 +5811,7 @@ struct _Chrono_formatter { return _Type == 'c' || _Type == 'x' || _Type == 'X' || _Is_valid_type<_CHRONO year_month_day>(_Type) || _Is_valid_type<_CHRONO hh_mm_ss<_CHRONO seconds>>(_Type); } else { - // TRANSITION, remove when all types are added - static_assert(_Always_false<_Ty>, "unsupported type"); + static_assert(_Always_false<_Ty>, "should be unreachable"); } } @@ -6014,6 +6016,10 @@ template struct formatter<_CHRONO weekday_indexed, _CharT> // : _Fill_tm_formatter<_CHRONO weekday_indexed, _CharT> {}; +template +struct formatter<_CHRONO weekday_last, _CharT> // + : _Fill_tm_formatter<_CHRONO weekday_last, _CharT> {}; + template struct formatter<_CHRONO month_day, _CharT> // : _Fill_tm_formatter<_CHRONO month_day, _CharT> {}; @@ -6022,6 +6028,14 @@ template struct formatter<_CHRONO month_day_last, _CharT> // : _Fill_tm_formatter<_CHRONO month_day_last, _CharT> {}; +template +struct formatter<_CHRONO month_weekday, _CharT> // + : _Fill_tm_formatter<_CHRONO month_weekday, _CharT> {}; + +template +struct formatter<_CHRONO month_weekday_last, _CharT> // + : _Fill_tm_formatter<_CHRONO month_weekday_last, _CharT> {}; + template struct formatter<_CHRONO year_month, _CharT> // : _Fill_tm_formatter<_CHRONO year_month, _CharT> {}; diff --git a/tests/std/tests/P0355R7_calendars_and_time_zones_formatting/test.cpp b/tests/std/tests/P0355R7_calendars_and_time_zones_formatting/test.cpp index c401013896c..30a4cc253ed 100644 --- a/tests/std/tests/P0355R7_calendars_and_time_zones_formatting/test.cpp +++ b/tests/std/tests/P0355R7_calendars_and_time_zones_formatting/test.cpp @@ -191,8 +191,8 @@ bool test_parse_chrono_format_specs() { return true; } -template -void throw_helper(const basic_string_view fmt, const Args&... vals) { +template +void throw_helper(const basic_string_view fmt, const Args&... vals) { try { (void) format(fmt, vals...); assert(false); @@ -200,19 +200,29 @@ void throw_helper(const basic_string_view fmt, const Args&... vals) { } } -template -void throw_helper(const charT* fmt, const Args&... vals) { - throw_helper(basic_string_view{fmt}, vals...); +template +void throw_helper(const CharT* fmt, const Args&... vals) { + throw_helper(basic_string_view{fmt}, vals...); } -template -void stream_helper(const charT* expect, const Args&... vals) { - basic_ostringstream stream; +template +void stream_helper(const CharT* expect, const Args&... vals) { + basic_ostringstream stream; (stream << ... << vals); assert(stream.str() == expect); assert(stream); } +template +void empty_braces_helper(const Arg& val, const CharT* const expected) { + // N4885 [time.format]/6: "If the chrono-specs is omitted, the chrono object is formatted + // as if by streaming it to std::ostringstream os and copying os.str() through the output iterator + // of the context with additional padding and adjustments as specified by the format specifiers." + assert(format(STR("{}"), val) == expected); + + stream_helper(expected, val); +} + // FIXME: TEMPORARY CODE FOR WRITING TESTS, REMOVE BEFORE MERGING template constexpr void print(Str str) { @@ -380,6 +390,59 @@ void test_weekday_indexed_formatter() { assert(format(STR("{:%u %w}"), weekday_indexed{Sunday, 4}) == STR("7 0")); } +template +void test_weekday_last_formatter() { + constexpr weekday_last invalid{weekday{10}}; + + empty_braces_helper(Wednesday[last], STR("Wed[last]")); + empty_braces_helper(invalid, STR("10 is not a valid weekday[last]")); + + assert(format(STR("{:%a %A %u %w}"), Saturday[last]) == STR("Sat Saturday 6 6")); + assert(format(STR("{:%a %A %u %w}"), Sunday[last]) == STR("Sun Sunday 7 0")); +} + +template +void test_month_weekday_formatter() { + constexpr month_weekday mwd1 = August / Tuesday[3]; + constexpr month_weekday mwd2 = December / Sunday[4]; + + constexpr month_weekday invalid1 = March / Friday[9]; + constexpr month_weekday invalid2 = March / weekday{8}[2]; + constexpr month_weekday invalid3 = month{20} / Friday[2]; + constexpr month_weekday invalid4 = month{20} / weekday{8}[9]; + + empty_braces_helper(mwd1, STR("Aug/Tue[3]")); + empty_braces_helper(mwd2, STR("Dec/Sun[4]")); + + empty_braces_helper(invalid1, STR("Mar/Fri[9 is not a valid index]")); + empty_braces_helper(invalid2, STR("Mar/8 is not a valid weekday[2]")); + empty_braces_helper(invalid3, STR("20 is not a valid month/Fri[2]")); + empty_braces_helper(invalid4, STR("20 is not a valid month/8 is not a valid weekday[9 is not a valid index]")); + + assert(format(STR("{:%b %B %h %m %a %A %u %w}"), mwd1) == STR("Aug August Aug 08 Tue Tuesday 2 2")); + assert(format(STR("{:%b %B %h %m %a %A %u %w}"), mwd2) == STR("Dec December Dec 12 Sun Sunday 7 0")); +} + +template +void test_month_weekday_last_formatter() { + constexpr month_weekday_last mwdl1 = August / Tuesday[last]; + constexpr month_weekday_last mwdl2 = December / Sunday[last]; + + constexpr month_weekday_last invalid1 = March / weekday{8}[last]; + constexpr month_weekday_last invalid2 = month{20} / Friday[last]; + constexpr month_weekday_last invalid3 = month{20} / weekday{8}[last]; + + empty_braces_helper(mwdl1, STR("Aug/Tue[last]")); + empty_braces_helper(mwdl2, STR("Dec/Sun[last]")); + + empty_braces_helper(invalid1, STR("Mar/8 is not a valid weekday[last]")); + empty_braces_helper(invalid2, STR("20 is not a valid month/Fri[last]")); + empty_braces_helper(invalid3, STR("20 is not a valid month/8 is not a valid weekday[last]")); + + assert(format(STR("{:%b %B %h %m %a %A %u %w}"), mwdl1) == STR("Aug August Aug 08 Tue Tuesday 2 2")); + assert(format(STR("{:%b %B %h %m %a %A %u %w}"), mwdl2) == STR("Dec December Dec 12 Sun Sunday 7 0")); +} + template void test_year_month_day_formatter() { year_month_day invalid{year{1234}, month{0}, day{31}}; @@ -395,18 +458,63 @@ void test_year_month_day_formatter() { template void test_year_month_day_last_formatter() { - // FIXME, TEST format() AND operator<< WHEN formatter FOR month_day_last IS IMPLEMENTED - // assert(format(STR("{:%F}"), 2021y / April / last) == STR("2021-04-30")); + constexpr year_month_day_last ymdl1 = 2021y / April / last; + constexpr year_month_day_last ymdl2 = 2004y / February / last; + + constexpr year_month_day_last invalid = 1999y / month{20} / last; + + empty_braces_helper(ymdl1, STR("2021/Apr/last")); + empty_braces_helper(ymdl2, STR("2004/Feb/last")); + + empty_braces_helper(invalid, STR("1999/20 is not a valid month/last")); + + constexpr auto fmt = STR("{:%D %F, %Y %C %y, %b %B %h %m, %d %e, %a %A %u %w}"); + assert(format(fmt, ymdl1) == STR("04/30/21 2021-04-30, 2021 20 21, Apr April Apr 04, 30 30, Fri Friday 5 5")); + assert(format(fmt, ymdl2) == STR("02/29/04 2004-02-29, 2004 20 04, Feb February Feb 02, 29 29, Sun Sunday 7 0")); } template void test_year_month_weekday_formatter() { - // FIXME, TEST format() AND operator<< WHEN formatter FOR weekday_indexed IS IMPLEMENTED + constexpr year_month_weekday ymwd1 = 2021y / April / Friday[5]; + constexpr year_month_weekday ymwd2 = 2004y / February / Sunday[5]; + + constexpr year_month_weekday invalid1 = 2015y / March / Friday[9]; + constexpr year_month_weekday invalid2 = 2015y / March / weekday{8}[2]; + constexpr year_month_weekday invalid3 = 2015y / month{20} / Friday[2]; + constexpr year_month_weekday invalid4 = 2015y / month{20} / weekday{8}[9]; + + empty_braces_helper(ymwd1, STR("2021/Apr/Fri[5]")); + empty_braces_helper(ymwd2, STR("2004/Feb/Sun[5]")); + + empty_braces_helper(invalid1, STR("2015/Mar/Fri[9 is not a valid index]")); + empty_braces_helper(invalid2, STR("2015/Mar/8 is not a valid weekday[2]")); + empty_braces_helper(invalid3, STR("2015/20 is not a valid month/Fri[2]")); + empty_braces_helper(invalid4, STR("2015/20 is not a valid month/8 is not a valid weekday[9 is not a valid index]")); + + constexpr auto fmt = STR("{:%D %F, %Y %C %y, %b %B %h %m, %d %e, %a %A %u %w}"); + assert(format(fmt, ymwd1) == STR("04/30/21 2021-04-30, 2021 20 21, Apr April Apr 04, 30 30, Fri Friday 5 5")); + assert(format(fmt, ymwd2) == STR("02/29/04 2004-02-29, 2004 20 04, Feb February Feb 02, 29 29, Sun Sunday 7 0")); } template void test_year_month_weekday_last_formatter() { - // FIXME, TEST format() AND operator<< WHEN formatter FOR weekday_last IS IMPLEMENTED + constexpr year_month_weekday_last ymwdl1 = 2021y / April / Friday[last]; + constexpr year_month_weekday_last ymwdl2 = 2004y / February / Sunday[last]; + + constexpr year_month_weekday_last invalid1 = 2015y / March / weekday{8}[last]; + constexpr year_month_weekday_last invalid2 = 2015y / month{20} / Friday[last]; + constexpr year_month_weekday_last invalid3 = 2015y / month{20} / weekday{8}[last]; + + empty_braces_helper(ymwdl1, STR("2021/Apr/Fri[last]")); + empty_braces_helper(ymwdl2, STR("2004/Feb/Sun[last]")); + + empty_braces_helper(invalid1, STR("2015/Mar/8 is not a valid weekday[last]")); + empty_braces_helper(invalid2, STR("2015/20 is not a valid month/Fri[last]")); + empty_braces_helper(invalid3, STR("2015/20 is not a valid month/8 is not a valid weekday[last]")); + + constexpr auto fmt = STR("{:%D %F, %Y %C %y, %b %B %h %m, %d %e, %a %A %u %w}"); + assert(format(fmt, ymwdl1) == STR("04/30/21 2021-04-30, 2021 20 21, Apr April Apr 04, 30 30, Fri Friday 5 5")); + assert(format(fmt, ymwdl2) == STR("02/29/04 2004-02-29, 2004 20 04, Feb February Feb 02, 29 29, Sun Sunday 7 0")); } template @@ -529,6 +637,15 @@ int main() { test_weekday_indexed_formatter(); test_weekday_indexed_formatter(); + test_weekday_last_formatter(); + test_weekday_last_formatter(); + + test_month_weekday_formatter(); + test_month_weekday_formatter(); + + test_month_weekday_last_formatter(); + test_month_weekday_last_formatter(); + test_year_month_day_formatter(); test_year_month_day_formatter(); From 0722b12100ccc85b3deca40ee31f3d0052d9e505 Mon Sep 17 00:00:00 2001 From: "Stephan T. Lavavej" Date: Sun, 18 Apr 2021 02:06:02 -0700 Subject: [PATCH 2/2] Update libcxx skips for C++20 features. --- tests/libcxx/expected_results.txt | 60 +++++++++++++++++-------------- tests/libcxx/skipped_tests.txt | 58 ++++++++++++++++-------------- 2 files changed, 66 insertions(+), 52 deletions(-) diff --git a/tests/libcxx/expected_results.txt b/tests/libcxx/expected_results.txt index 9bd7270d66d..67bc2348870 100644 --- a/tests/libcxx/expected_results.txt +++ b/tests/libcxx/expected_results.txt @@ -275,32 +275,6 @@ std/utilities/memory/default.allocator/allocator.members/allocate.verify.cpp SKI # *** MISSING STL FEATURES *** -# C++20 P0355R7 " Calendars And Time Zones" -std/utilities/time/time.cal/time.cal.mwdlast/time.cal.mwdlast.nonmembers/streaming.pass.cpp FAIL -std/utilities/time/time.cal/time.cal.wdidx/time.cal.wdidx.nonmembers/streaming.pass.cpp FAIL -std/utilities/time/time.cal/time.cal.ymwd/time.cal.ymwd.nonmembers/streaming.pass.cpp FAIL -std/utilities/time/time.cal/time.cal.ymwdlast/time.cal.ymwdlast.nonmembers/streaming.pass.cpp FAIL - -# C++20 P0466R5 "Layout-Compatibility And Pointer-Interconvertibility Traits" -std/language.support/support.limits/support.limits.general/type_traits.version.pass.cpp:1 FAIL - -# C++20 P0608R3 "Improving variant's Converting Constructor/Assignment" -std/utilities/variant/variant.variant/variant.assign/conv.pass.cpp FAIL -std/utilities/variant/variant.variant/variant.assign/T.pass.cpp FAIL -std/utilities/variant/variant.variant/variant.ctor/conv.pass.cpp FAIL -std/utilities/variant/variant.variant/variant.ctor/T.pass.cpp FAIL - -# C++20 P0784R7 "More constexpr containers" -std/utilities/memory/allocator.traits/allocator.traits.members/construct.pass.cpp FAIL -std/utilities/memory/allocator.traits/allocator.traits.members/destroy.pass.cpp FAIL -std/utilities/memory/specialized.algorithms/specialized.construct/construct_at.pass.cpp FAIL - -# C++20 P0896R4 "" -std/language.support/support.limits/support.limits.general/algorithm.version.pass.cpp FAIL -std/language.support/support.limits/support.limits.general/functional.version.pass.cpp FAIL -std/language.support/support.limits/support.limits.general/iterator.version.pass.cpp FAIL -std/language.support/support.limits/support.limits.general/memory.version.pass.cpp FAIL - # C++23 P1048R1 "is_scoped_enum" std/utilities/meta/meta.unary/meta.unary.prop/is_scoped_enum.pass.cpp FAIL @@ -651,6 +625,25 @@ std/utilities/allocator.adaptor/allocator.adaptor.members/construct_pair_rvalue. std/utilities/allocator.adaptor/allocator.adaptor.members/construct_pair_values.pass.cpp FAIL std/utilities/allocator.adaptor/allocator.adaptor.members/construct_type.pass.cpp FAIL +# Bogus test uses std::cout without including . +std/utilities/time/time.cal/time.cal.wdidx/time.cal.wdidx.nonmembers/streaming.pass.cpp FAIL + +# Bogus test constructs year_month_weekday from weekday, but the constructor actually takes weekday_indexed. +std/utilities/time/time.cal/time.cal.ymwd/time.cal.ymwd.nonmembers/streaming.pass.cpp FAIL + +# We define __cpp_lib_has_unique_object_representations in C++17 mode; test error says it +# "should not be defined when TEST_HAS_BUILTIN_IDENTIFIER(__has_unique_object_representations) || TEST_GCC_VER >= 700 is not defined!" +std/language.support/support.limits/support.limits.general/type_traits.version.pass.cpp:1 FAIL + +# Tests expect __cpp_lib_ranges to have the old value 201811L for P0896R4; we define the C++20 value 201911L for P1716R3. +std/language.support/support.limits/support.limits.general/algorithm.version.pass.cpp FAIL +std/language.support/support.limits/support.limits.general/functional.version.pass.cpp FAIL +std/language.support/support.limits/support.limits.general/iterator.version.pass.cpp FAIL + +# We unconditionally define __cpp_lib_addressof_constexpr; test error says it +# "should not be defined when TEST_HAS_BUILTIN(__builtin_addressof) || TEST_GCC_VER >= 700 is not defined!" +std/language.support/support.limits/support.limits.general/memory.version.pass.cpp FAIL + # *** LIKELY STL BUGS *** # Not yet analyzed, likely STL bugs. Assertions and other runtime failures. @@ -857,6 +850,19 @@ std/re/re.alg/re.alg.search/basic.locale.pass.cpp FAIL std/re/re.alg/re.alg.search/ecma.locale.pass.cpp FAIL std/re/re.alg/re.alg.search/extended.locale.pass.cpp FAIL +# Not yet analyzed. Various static_asserts. +std/utilities/variant/variant.variant/variant.assign/conv.pass.cpp FAIL +std/utilities/variant/variant.variant/variant.assign/T.pass.cpp FAIL +std/utilities/variant/variant.variant/variant.ctor/conv.pass.cpp FAIL +std/utilities/variant/variant.variant/variant.ctor/T.pass.cpp FAIL + +# Not yet analyzed. Involves incomplete types. +std/utilities/memory/allocator.traits/allocator.traits.members/construct.pass.cpp FAIL +std/utilities/memory/allocator.traits/allocator.traits.members/destroy.pass.cpp FAIL + +# Not yet analyzed. Error mentions allocator. +std/utilities/memory/specialized.algorithms/specialized.construct/construct_at.pass.cpp FAIL + # *** XFAILs WHICH PASS *** # Not yet implemented in libcxx and marked as "XFAIL: libc++" @@ -876,9 +882,11 @@ std/utilities/time/time.cal/time.cal.md/time.cal.md.nonmembers/streaming.pass.cp std/utilities/time/time.cal/time.cal.mdlast/streaming.pass.cpp SKIPPED std/utilities/time/time.cal/time.cal.month/time.cal.month.nonmembers/streaming.pass.cpp SKIPPED std/utilities/time/time.cal/time.cal.mwd/time.cal.mwd.nonmembers/streaming.pass.cpp SKIPPED +std/utilities/time/time.cal/time.cal.mwdlast/time.cal.mwdlast.nonmembers/streaming.pass.cpp SKIPPED std/utilities/time/time.cal/time.cal.wdlast/time.cal.wdlast.nonmembers/streaming.pass.cpp SKIPPED std/utilities/time/time.cal/time.cal.weekday/time.cal.weekday.nonmembers/streaming.pass.cpp SKIPPED std/utilities/time/time.cal/time.cal.year/time.cal.year.nonmembers/streaming.pass.cpp SKIPPED std/utilities/time/time.cal/time.cal.ym/time.cal.ym.nonmembers/streaming.pass.cpp SKIPPED std/utilities/time/time.cal/time.cal.ymd/time.cal.ymd.nonmembers/streaming.pass.cpp SKIPPED std/utilities/time/time.cal/time.cal.ymdlast/time.cal.ymdlast.nonmembers/streaming.pass.cpp SKIPPED +std/utilities/time/time.cal/time.cal.ymwdlast/time.cal.ymwdlast.nonmembers/streaming.pass.cpp SKIPPED diff --git a/tests/libcxx/skipped_tests.txt b/tests/libcxx/skipped_tests.txt index ae453bbaed2..fedbf725d24 100644 --- a/tests/libcxx/skipped_tests.txt +++ b/tests/libcxx/skipped_tests.txt @@ -275,32 +275,6 @@ utilities\memory\default.allocator\allocator.members\allocate.verify.cpp # *** MISSING STL FEATURES *** -# C++20 P0355R7 " Calendars And Time Zones" -utilities\time\time.cal\time.cal.mwdlast\time.cal.mwdlast.nonmembers\streaming.pass.cpp -utilities\time\time.cal\time.cal.wdidx\time.cal.wdidx.nonmembers\streaming.pass.cpp -utilities\time\time.cal\time.cal.ymwd\time.cal.ymwd.nonmembers\streaming.pass.cpp -utilities\time\time.cal\time.cal.ymwdlast\time.cal.ymwdlast.nonmembers\streaming.pass.cpp - -# C++20 P0466R5 "Layout-Compatibility And Pointer-Interconvertibility Traits" -language.support\support.limits\support.limits.general\type_traits.version.pass.cpp - -# C++20 P0608R3 "Improving variant's Converting Constructor/Assignment" -utilities\variant\variant.variant\variant.assign\conv.pass.cpp -utilities\variant\variant.variant\variant.assign\T.pass.cpp -utilities\variant\variant.variant\variant.ctor\conv.pass.cpp -utilities\variant\variant.variant\variant.ctor\T.pass.cpp - -# C++20 P0784R7 "More constexpr containers" -utilities\memory\allocator.traits\allocator.traits.members\construct.pass.cpp -utilities\memory\allocator.traits\allocator.traits.members\destroy.pass.cpp -utilities\memory\specialized.algorithms\specialized.construct\construct_at.pass.cpp - -# C++20 P0896R4 "" -language.support\support.limits\support.limits.general\algorithm.version.pass.cpp -language.support\support.limits\support.limits.general\functional.version.pass.cpp -language.support\support.limits\support.limits.general\iterator.version.pass.cpp -language.support\support.limits\support.limits.general\memory.version.pass.cpp - # C++23 P1048R1 "is_scoped_enum" utilities\meta\meta.unary\meta.unary.prop\is_scoped_enum.pass.cpp @@ -651,6 +625,25 @@ utilities\allocator.adaptor\allocator.adaptor.members\construct_pair_rvalue.pass utilities\allocator.adaptor\allocator.adaptor.members\construct_pair_values.pass.cpp utilities\allocator.adaptor\allocator.adaptor.members\construct_type.pass.cpp +# Bogus test uses std::cout without including . +utilities\time\time.cal\time.cal.wdidx\time.cal.wdidx.nonmembers\streaming.pass.cpp + +# Bogus test constructs year_month_weekday from weekday, but the constructor actually takes weekday_indexed. +utilities\time\time.cal\time.cal.ymwd\time.cal.ymwd.nonmembers\streaming.pass.cpp + +# We define __cpp_lib_has_unique_object_representations in C++17 mode; test error says it +# "should not be defined when TEST_HAS_BUILTIN_IDENTIFIER(__has_unique_object_representations) || TEST_GCC_VER >= 700 is not defined!" +language.support\support.limits\support.limits.general\type_traits.version.pass.cpp + +# Tests expect __cpp_lib_ranges to have the old value 201811L for P0896R4; we define the C++20 value 201911L for P1716R3. +language.support\support.limits\support.limits.general\algorithm.version.pass.cpp +language.support\support.limits\support.limits.general\functional.version.pass.cpp +language.support\support.limits\support.limits.general\iterator.version.pass.cpp + +# We unconditionally define __cpp_lib_addressof_constexpr; test error says it +# "should not be defined when TEST_HAS_BUILTIN(__builtin_addressof) || TEST_GCC_VER >= 700 is not defined!" +language.support\support.limits\support.limits.general\memory.version.pass.cpp + # *** LIKELY STL BUGS *** # Not yet analyzed, likely STL bugs. Assertions and other runtime failures. @@ -857,6 +850,19 @@ re\re.alg\re.alg.search\basic.locale.pass.cpp re\re.alg\re.alg.search\ecma.locale.pass.cpp re\re.alg\re.alg.search\extended.locale.pass.cpp +# Not yet analyzed. Various static_asserts. +utilities\variant\variant.variant\variant.assign\conv.pass.cpp +utilities\variant\variant.variant\variant.assign\T.pass.cpp +utilities\variant\variant.variant\variant.ctor\conv.pass.cpp +utilities\variant\variant.variant\variant.ctor\T.pass.cpp + +# Not yet analyzed. Involves incomplete types. +utilities\memory\allocator.traits\allocator.traits.members\construct.pass.cpp +utilities\memory\allocator.traits\allocator.traits.members\destroy.pass.cpp + +# Not yet analyzed. Error mentions allocator. +utilities\memory\specialized.algorithms\specialized.construct\construct_at.pass.cpp + # *** SKIPPED FOR MSVC-INTERNAL CONTEST ONLY *** # Our machinery doesn't understand compile-only `.compile.pass.cpp` tests.