From 726e509ffb76b25a520c1a75d90f1e8ad81f3d5e Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Mon, 27 Dec 2021 16:05:02 -0800 Subject: [PATCH 01/31] libc++ takes `(void)iter_swap(x, y)` too seriously --- stl/inc/xutility | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stl/inc/xutility b/stl/inc/xutility index b2a91e1ca9..118cc8977a 100644 --- a/stl/inc/xutility +++ b/stl/inc/xutility @@ -1053,7 +1053,7 @@ namespace ranges { constexpr _St _Strat = _Choice<_Ty1, _Ty2>._Strategy; if constexpr (_Strat == _St::_Custom) { - iter_swap(static_cast<_Ty1&&>(_Val1), static_cast<_Ty2&&>(_Val2)); + (void) iter_swap(static_cast<_Ty1&&>(_Val1), static_cast<_Ty2&&>(_Val2)); } else if constexpr (_Strat == _St::_Swap) { _RANGES swap(*static_cast<_Ty1&&>(_Val1), *static_cast<_Ty2&&>(_Val2)); } else if constexpr (_Strat == _St::_Exchange) { From fca8c58f7f07c718d74f8cbf0b24dff0a5aac667 Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Mon, 27 Dec 2021 17:46:32 -0800 Subject: [PATCH 02/31] views::counted can fail with move-only iterator lvalues --- stl/inc/ranges | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/stl/inc/ranges b/stl/inc/ranges index acfaca9ffb..d92e376de7 100644 --- a/stl/inc/ranges +++ b/stl/inc/ranges @@ -4026,20 +4026,24 @@ namespace ranges { class _Counted_fn { private: - enum class _St { _Span, _Subrange, _Subrange_counted }; + enum class _St { _None, _Span, _Subrange, _Subrange_counted }; template _NODISCARD static _CONSTEVAL _Choice_t<_St> _Choose() noexcept { - _STL_INTERNAL_STATIC_ASSERT(input_or_output_iterator<_It>); - if constexpr (contiguous_iterator<_It>) { - return {_St::_Span, noexcept(span(_STD to_address(_STD declval<_It>()), iter_difference_t<_It>{}))}; - } else if constexpr (random_access_iterator<_It>) { + using _Decayed = decay_t<_It>; + _STL_INTERNAL_STATIC_ASSERT(input_or_output_iterator<_Decayed>); + if constexpr (contiguous_iterator<_Decayed>) { + return {_St::_Span, + noexcept(span(_STD to_address(_STD declval<_It>()), iter_difference_t<_Decayed>{}))}; + } else if constexpr (random_access_iterator<_Decayed>) { return {_St::_Subrange, - noexcept(subrange(_STD declval<_It>(), _STD declval<_It>() + iter_difference_t<_It>{}))}; - } else { + noexcept(subrange(_STD declval<_It>(), _STD declval<_It>() + iter_difference_t<_Decayed>{}))}; + } else if constexpr (constructible_from<_Decayed, _It>) { return {_St::_Subrange_counted, noexcept(subrange( - counted_iterator(_STD declval<_It>(), iter_difference_t<_It>{}), default_sentinel))}; + counted_iterator(_STD declval<_It>(), iter_difference_t<_Decayed>{}), default_sentinel))}; + } else { + return {_St::_None}; } } @@ -4049,9 +4053,9 @@ namespace ranges { public: // clang-format off template - requires input_or_output_iterator> + requires (input_or_output_iterator> && _Choice<_It>._Strategy != _St::_None) _NODISCARD constexpr auto operator()(_It&& _First, const iter_difference_t> _Count) const - noexcept(_Choice>._No_throw) { + noexcept(_Choice<_It>._No_throw) { // clang-format on _STL_ASSERT(_Count >= 0, "The size passed to views::counted must be non-negative"); constexpr _St _Strat = _Choice>._Strategy; From 9d50b8f97eec88a146510216a7bfdf8247ccec0e Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Tue, 28 Dec 2021 01:50:33 -0800 Subject: [PATCH 03/31] Give raw_storage_iterator a proper difference type in C++20 ... if it's enabled, it oughta work. As detected by libc++ test `std/utilities/memory/storage.iterator/types.compile.pass.cpp`. --- stl/inc/memory | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/stl/inc/memory b/stl/inc/memory index 00e5fa3f9f..fc31544b5c 100644 --- a/stl/inc/memory +++ b/stl/inc/memory @@ -880,9 +880,13 @@ class _CXX17_DEPRECATE_RAW_STORAGE_ITERATOR raw_storage_iterator { // wrap store public: using iterator_category = output_iterator_tag; using value_type = void; - using difference_type = void; - using pointer = void; - using reference = void; +#ifdef __cpp_lib_concepts + using difference_type = ptrdiff_t; +#else + using difference_type = void; +#endif // __cpp_lib_concepts + using pointer = void; + using reference = void; explicit raw_storage_iterator(_OutIt _First) : _Next(_First) {} From d36407c9d32486b531b147bdae99a36690f7702c Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Wed, 29 Dec 2021 02:01:31 -0800 Subject: [PATCH 04/31] : iota_view::iterator's difference is broken We somehow failed to implement this operation as updated by P1522. --- stl/inc/ranges | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/stl/inc/ranges b/stl/inc/ranges index d92e376de7..7118b1f345 100644 --- a/stl/inc/ranges +++ b/stl/inc/ranges @@ -1159,7 +1159,19 @@ namespace ranges { _NODISCARD friend constexpr difference_type operator-(const _Ioterator& _Left, const _Ioterator& _Right) noexcept( noexcept(_Left._Current - _Right._Current)) /* strengthened */ requires _Advanceable<_Wi> { - return static_cast(_Left._Current - _Right._Current); + if constexpr (_Integer_like<_Wi>) { + if constexpr (_Signed_integer_like<_Wi>) { + return static_cast( + static_cast(_Left._Current) - static_cast(_Right._Current)); + } else if (_Right._Current > _Left._Current) { + return static_cast( + -static_cast(_Right._Current - _Left._Current)); + } else { + return static_cast(_Left._Current - _Right._Current); + } + } else { + return static_cast(_Left._Current - _Right._Current); + } } }; From a6b4f1c4c71d82437204377759940b65b3cb3a6e Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Wed, 29 Dec 2021 04:15:42 -0800 Subject: [PATCH 05/31] : `L` is valid (and ignored) for integral types charT and `char` --- stl/inc/format | 5 +---- .../P0645R10_text_formatting_formatting/test.cpp | 11 +++++++++++ 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/stl/inc/format b/stl/inc/format index 09d71a7a8d..fff23fc1cb 100644 --- a/stl/inc/format +++ b/stl/inc/format @@ -2366,8 +2366,6 @@ _NODISCARD _OutputIt _Fmt_write( _STL_INTERNAL_CHECK(_Specs._Precision == -1); - // Clear the type so that the string_view writer doesn't fail on 'c'. - _Specs._Type = '\0'; return _Fmt_write(_STD move(_Out), basic_string_view<_CharT>{&_Value, 1}, _Specs, _Locale); } @@ -2673,11 +2671,10 @@ _NODISCARD const _CharT* _Measure_string_prefix(const basic_string_view<_CharT> template _NODISCARD _OutputIt _Fmt_write( _OutputIt _Out, const basic_string_view<_CharT> _Value, const _Basic_format_specs<_CharT>& _Specs, _Lazy_locale) { - _STL_INTERNAL_CHECK(_Specs._Type == '\0' || _Specs._Type == 's'); + _STL_INTERNAL_CHECK(_Specs._Type == '\0' || _Specs._Type == 'c' || _Specs._Type == 's'); _STL_INTERNAL_CHECK(_Specs._Sgn == _Fmt_sign::_None); _STL_INTERNAL_CHECK(!_Specs._Alt); _STL_INTERNAL_CHECK(!_Specs._Leading_zero); - _STL_INTERNAL_CHECK(!_Specs._Localized); if (_Specs._Precision < 0 && _Specs._Width <= 0) { return _Fmt_write(_STD move(_Out), _Value); diff --git a/tests/std/tests/P0645R10_text_formatting_formatting/test.cpp b/tests/std/tests/P0645R10_text_formatting_formatting/test.cpp index 9f698c38fb..81e9f83cf7 100644 --- a/tests/std/tests/P0645R10_text_formatting_formatting/test.cpp +++ b/tests/std/tests/P0645R10_text_formatting_formatting/test.cpp @@ -1389,6 +1389,13 @@ void test_sane_c_specifier() { assert(format(STR("{:c}"), 'c') == STR("c")); } +template +void test_localized_char() { + // L should be accepted and ignored for "integral types" charT and char + assert(format(STR("{:L}"), T('c')) == STR("c")); + assert(format(STR("{:Lc}"), T('c')) == STR("c")); +} + void test() { test_simple_formatting(); test_simple_formatting(); @@ -1461,6 +1468,10 @@ void test() { test_sane_c_specifier(); test_sane_c_specifier(); + + test_localized_char(); + test_localized_char(); + test_localized_char(); } int main() { From eeee5aff2f08e4adbc40d71af0363fab45cbe9dd Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Wed, 29 Dec 2021 04:48:29 -0800 Subject: [PATCH 06/31] Per [format.string.std]/7, width must be positive --- stl/inc/format | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/stl/inc/format b/stl/inc/format index fff23fc1cb..8aa71e6780 100644 --- a/stl/inc/format +++ b/stl/inc/format @@ -1096,10 +1096,15 @@ public: template _NODISCARD constexpr unsigned long long operator()(const _Ty _Value) const { if constexpr (is_integral_v<_Ty>) { + bool _Positive; if constexpr (is_signed_v<_Ty>) { - if (_Value < 0) { - _THROW(format_error("Negative width.")); - } + _Positive = _Value > 0; + } else { + _Positive = _Value != 0; + } + + if (!_Positive) { + _THROW(format_error("width is not positive.")); } return static_cast(_Value); } else { From 337512e6a75b8641f4762936e4b97f98c51548c8 Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Wed, 29 Dec 2021 12:13:10 -0800 Subject: [PATCH 07/31] Missed Ranges update to std::inserter --- stl/inc/iterator | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/stl/inc/iterator b/stl/inc/iterator index f75ad3c36f..58bf0169c4 100644 --- a/stl/inc/iterator +++ b/stl/inc/iterator @@ -170,12 +170,17 @@ protected: _Wrapped_iter iter; }; +#ifndef __cpp_lib_concepts template _NODISCARD _CONSTEXPR20 insert_iterator<_Container> inserter(_Container& _Cont, typename _Container::iterator _Where) { return insert_iterator<_Container>(_Cont, _Where); } +#else // ^^^ No Ranges / Ranges vvv +template +_NODISCARD _CONSTEXPR20 insert_iterator<_Container> inserter(_Container& _Cont, _RANGES iterator_t<_Container> _Where) { + return insert_iterator<_Container>(_Cont, _Where); +} -#ifdef __cpp_lib_concepts template class move_sentinel { public: From 227e6383ddb1796e3b2efaeb4b4d92c0369c535a Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Wed, 29 Dec 2021 12:15:48 -0800 Subject: [PATCH 08/31] un-nest requirement not depicted as nested in the Working Draft ... in `input_or_output_iterator` and `common_with`. The implementations seem to think this affects subsumption, despite that my brain compiler believes they should be equivalent. --- stl/inc/concepts | 4 +++- stl/inc/xutility | 6 ++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/stl/inc/concepts b/stl/inc/concepts index 98c6e291a9..110177a48a 100644 --- a/stl/inc/concepts +++ b/stl/inc/concepts @@ -63,7 +63,9 @@ concept common_with = requires { typename common_type_t<_Ty1, _Ty2>; typename common_type_t<_Ty2, _Ty1>; - requires same_as, common_type_t<_Ty2, _Ty1>>; + } + && same_as, common_type_t<_Ty2, _Ty1>> + && requires { static_cast>(_STD declval<_Ty1>()); static_cast>(_STD declval<_Ty2>()); } diff --git a/stl/inc/xutility b/stl/inc/xutility index 118cc8977a..6f2831c237 100644 --- a/stl/inc/xutility +++ b/stl/inc/xutility @@ -776,10 +776,8 @@ concept incrementable = regular<_Ty> && weakly_incrementable<_Ty> && requires(_T }; template -concept input_or_output_iterator = requires(_It __i) { - { *__i } -> _Can_reference; - requires weakly_incrementable<_It>; -}; +concept input_or_output_iterator = requires(_It __i) { { *__i } -> _Can_reference; } + && weakly_incrementable<_It>; template concept sentinel_for = semiregular<_Se> From e46b9522600e87f839b979a43d7ddb59a729d369 Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Wed, 29 Dec 2021 12:19:50 -0800 Subject: [PATCH 09/31] Implement final P/R of LWG-3150 We/I failed to notice that LWG changed my proposed resolution before approving. Also relocates `_Require_constant` next to its only remaining use in the `_Tiny_range` concept in ``. --- stl/inc/algorithm | 4 +--- stl/inc/ranges | 3 +++ stl/inc/xutility | 3 --- 3 files changed, 4 insertions(+), 6 deletions(-) diff --git a/stl/inc/algorithm b/stl/inc/algorithm index c4ab0175c1..686a476b2a 100644 --- a/stl/inc/algorithm +++ b/stl/inc/algorithm @@ -4773,9 +4773,7 @@ concept uniform_random_bit_generator = invocable<_Ty&> && requires { { (_Ty::min)() } -> same_as>; { (_Ty::max)() } -> same_as>; - typename _Require_constant<(_Ty::min)()>; - typename _Require_constant<(_Ty::max)()>; - requires (_Ty::min)() < (_Ty::max)(); + requires bool_constant<(_Ty::min)() < (_Ty::max)()>::value; }; // clang-format on diff --git a/stl/inc/ranges b/stl/inc/ranges index 7118b1f345..bc2cad39e2 100644 --- a/stl/inc/ranges +++ b/stl/inc/ranges @@ -3418,6 +3418,9 @@ namespace ranges { } // namespace views // clang-format off + template // _Require_constant is a valid template-id iff E is a constant expression of structural type + struct _Require_constant; + template concept _Tiny_range = sized_range<_Ty> && requires { typename _Require_constant::size()>; } diff --git a/stl/inc/xutility b/stl/inc/xutility index 6f2831c237..61c15b526a 100644 --- a/stl/inc/xutility +++ b/stl/inc/xutility @@ -5869,9 +5869,6 @@ namespace ranges { inline constexpr _Search_fn search{_Not_quite_object::_Construct_tag{}}; } // namespace ranges - -template // _Require_constant is a valid template-id iff E is a constant expression of structural type -struct _Require_constant; #endif // __cpp_lib_concepts template From d05dad9f7720be318aed19c58be9519bd38299cf Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Sun, 2 Jan 2022 02:12:07 -0800 Subject: [PATCH 10/31] Don't use defaults to implement _Ioterator comparisons Overload resolution falls back on the base class operators when the derived operators disappear. --- stl/inc/ranges | 22 +++++++++------------- 1 file changed, 9 insertions(+), 13 deletions(-) diff --git a/stl/inc/ranges b/stl/inc/ranges index bc2cad39e2..bd9011c18d 100644 --- a/stl/inc/ranges +++ b/stl/inc/ranges @@ -976,15 +976,11 @@ namespace ranges { // clang-format on template - struct _Ioterator_category_base { - _NODISCARD auto operator<=>(const _Ioterator_category_base&) const = default; - }; + struct _Ioterator_category_base {}; template struct _Ioterator_category_base<_Wi> { using iterator_category = input_iterator_tag; - - _NODISCARD auto operator<=>(const _Ioterator_category_base&) const = default; }; // clang-format off @@ -1112,10 +1108,10 @@ namespace ranges { } } - // clang-format off - _NODISCARD friend constexpr bool operator==( - const _Ioterator&, const _Ioterator&) requires equality_comparable<_Wi> = default; - // clang-format on + _NODISCARD friend constexpr bool operator==(const _Ioterator& _Left, const _Ioterator& _Right) noexcept( + noexcept(_Left._Current == _Right._Current)) requires equality_comparable<_Wi> { + return _Left._Current == _Right._Current; + } _NODISCARD friend constexpr bool operator<(const _Ioterator& _Left, const _Ioterator& _Right) noexcept( noexcept(_Left._Current < _Right._Current)) /* strengthened */ requires totally_ordered<_Wi> { @@ -1134,10 +1130,10 @@ namespace ranges { return !(_Left._Current < _Right._Current); } - // clang-format off - _NODISCARD friend constexpr auto operator<=>(const _Ioterator& _Left, const _Ioterator& _Right) - requires totally_ordered<_Wi> && three_way_comparable<_Wi> = default; - // clang-format on + _NODISCARD friend constexpr auto operator<=>(const _Ioterator& _Left, const _Ioterator& _Right) noexcept( + noexcept(_Left._Current <=> _Right._Current)) requires totally_ordered<_Wi> && three_way_comparable<_Wi> { + return _Left._Current <=> _Right._Current; + } _NODISCARD friend constexpr _Ioterator operator+(_Ioterator _It, const difference_type _Off) noexcept( is_nothrow_move_constructible_v<_Ioterator>&& noexcept( From 76c887a0302ceef4e9c0a9780e19b0907b93f266 Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Sun, 2 Jan 2022 10:25:03 -0800 Subject: [PATCH 11/31] Abandon aggregate _Iotinel Since Clang 14 still doesn't support P0960. It was a nice experiment, but it's time to move on. --- stl/inc/ranges | 27 ++++++++++++++++++++++----- 1 file changed, 22 insertions(+), 5 deletions(-) diff --git a/stl/inc/ranges b/stl/inc/ranges index bd9011c18d..2353a1b750 100644 --- a/stl/inc/ranges +++ b/stl/inc/ranges @@ -983,13 +983,21 @@ namespace ranges { using iterator_category = input_iterator_tag; }; - // clang-format off template requires copyable<_Wi> - struct _Ioterator : _Ioterator_category_base<_Wi> { - // clang-format on + class _Ioterator : public _Ioterator_category_base<_Wi> { + private: /* [[no_unique_address]] */ _Wi _Current{}; + template + requires _Weakly_equality_comparable_with<_Wi2, _Bo2> && copyable<_Wi2> + friend class _Iotinel; + + template + requires _Weakly_equality_comparable_with<_Wi2, _Bo2> && copyable<_Wi2> + friend class iota_view; + + public: using iterator_concept = conditional_t<_Advanceable<_Wi>, random_access_iterator_tag, conditional_t<_Decrementable<_Wi>, bidirectional_iterator_tag, conditional_t, forward_iterator_tag, input_iterator_tag>>>; @@ -1174,11 +1182,17 @@ namespace ranges { // clang-format off template requires _Weakly_equality_comparable_with<_Wi, _Bo> && copyable<_Wi> - struct _Iotinel { + class _Iotinel { // clang-format on private: using _It = _Ioterator<_Wi>; + /* [[no_unique_address]] */ _Bo _Last{}; + + template + requires _Weakly_equality_comparable_with<_Wi2, _Bo2> && copyable<_Wi2> + friend class iota_view; + _NODISCARD constexpr bool _Equal(const _It& _That) const noexcept(noexcept(_That._Current == _Last)) { return _That._Current == _Last; } @@ -1190,7 +1204,10 @@ namespace ranges { } public: - /* [[no_unique_address]] */ _Bo _Last{}; + _Iotinel() = default; + + constexpr explicit _Iotinel(_Bo _Last_) noexcept(is_nothrow_move_constructible_v<_Bo>) + : _Last(_STD move(_Last_)) {} _NODISCARD friend constexpr bool operator==(const _It& _Left, const _Iotinel& _Right) noexcept( noexcept(_Right._Equal(_Left))) /* strengthened */ { From 072c836d74505ac08ddeb7778121b48d9a1331ad Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Mon, 3 Jan 2022 13:56:56 -0800 Subject: [PATCH 12/31] Add concept test cases for `convertible_to`, `common_reference_with`, and `swappable_with` to test with lvalue arrays of volatile elements. --- tests/std/tests/P0898R3_concepts/test.cpp | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/tests/std/tests/P0898R3_concepts/test.cpp b/tests/std/tests/P0898R3_concepts/test.cpp index 4b77b650c5..1336525845 100644 --- a/tests/std/tests/P0898R3_concepts/test.cpp +++ b/tests/std/tests/P0898R3_concepts/test.cpp @@ -536,6 +536,15 @@ namespace test_convertible_to { STATIC_ASSERT(convertible_to>); STATIC_ASSERT(convertible_to>); + // volatile array glvalues +#if defined(__clang__) || defined(__EDG__) // TRANSITION, DevCom-1627396 + STATIC_ASSERT(convertible_to); + STATIC_ASSERT(convertible_to); +#endif // TRANSITION, DevCom-1627396 + STATIC_ASSERT(convertible_to); + STATIC_ASSERT(convertible_to); + + // char STATIC_ASSERT(!test()); STATIC_ASSERT(!test()); @@ -709,6 +718,14 @@ namespace test_common_reference_with { STATIC_ASSERT(!test&, Interconvertible<1> const&>()); STATIC_ASSERT(test>()); + + STATIC_ASSERT(test()); +#if defined(__clang__) || defined(__EDG__) // TRANSITION, DevCom-1627396 + STATIC_ASSERT(test()); + STATIC_ASSERT(test()); +#endif // TRANSITION, DevCom-1627396 + STATIC_ASSERT(test()); + STATIC_ASSERT(test()); } // namespace test_common_reference_with namespace test_common_with { @@ -2023,6 +2040,11 @@ namespace test_swappable_with { STATIC_ASSERT(test()); +#if defined(__clang__) || defined(__EDG__) // TRANSITION, DevCom-1627396 + STATIC_ASSERT(test()); + STATIC_ASSERT(test()); +#endif // TRANSITION, DevCom-1627396 + STATIC_ASSERT(test() == is_permissive); STATIC_ASSERT(test()); STATIC_ASSERT(test() == is_permissive); From 62ad0b27663845a26c08f755076a2ce5b21eda67 Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Tue, 4 Jan 2022 13:21:29 -0800 Subject: [PATCH 13/31] Update implementation of LWG-3569 to reflect the current PR ... and fix a bug in `join_view::iterator::_Check_dereference`. --- stl/inc/ranges | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/stl/inc/ranges b/stl/inc/ranges index 2353a1b750..e063b71fe9 100644 --- a/stl/inc/ranges +++ b/stl/inc/ranges @@ -3154,7 +3154,7 @@ namespace ranges { constexpr void _Check_dereference() const noexcept { _STL_VERIFY(_Parent != nullptr, "cannot dereference value-initialized join_view iterator"); _STL_VERIFY(_Outer != _RANGES end(_Parent->_Range), "cannot dereference join_view end iterator"); - sentinel_t<_InnerRng> _Last; + sentinel_t<_InnerRng<_Const>> _Last; if constexpr (_Deref_is_glvalue) { _Last = _RANGES end(*_Outer); } else { @@ -3180,7 +3180,7 @@ namespace ranges { using difference_type = common_type_t, range_difference_t<_InnerRng<_Const>>>; // clang-format off - _Iterator() requires default_initializable<_OuterIter> && default_initializable<_InnerIter> = default; + _Iterator() requires default_initializable<_OuterIter> = default; // per LWG-3569 // clang-format on constexpr _Iterator(_Parent_t& _Parent_, _OuterIter _Outer_) From f3de68557e0ba73436ac6fe3ebc01decbd39fd16 Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Tue, 4 Jan 2022 14:35:12 -0800 Subject: [PATCH 14/31] Workaround LLVM-48173 in `weakly_incrementable` --- stl/inc/xutility | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/stl/inc/xutility b/stl/inc/xutility index 61c15b526a..d545d12d71 100644 --- a/stl/inc/xutility +++ b/stl/inc/xutility @@ -768,7 +768,11 @@ concept weakly_incrementable = movable<_Ty> && requires(_Ty __i) { requires _Signed_integer_like>; { ++__i } -> same_as<_Ty&>; __i++; -}; +} +#ifdef __clang__ // TRANSITION, LLVM-48173 +&& !same_as<_Ty, bool> +#endif // TRANSITION, LLVM-48173 +; template concept incrementable = regular<_Ty> && weakly_incrementable<_Ty> && requires(_Ty __t) { From 93cb0ae16957000259e438ad44a36dfceec6244d Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Tue, 4 Jan 2022 19:32:59 -0800 Subject: [PATCH 15/31] Implement _Defaultabox converting constructor templates ... to support the `join_view` iterator converting constructor. --- stl/inc/ranges | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/stl/inc/ranges b/stl/inc/ranges index e063b71fe9..27ae028792 100644 --- a/stl/inc/ranges +++ b/stl/inc/ranges @@ -513,6 +513,22 @@ namespace ranges { } } + template <_Not_same_as<_Ty> _Uty> + requires convertible_to + constexpr _Defaultabox(const _Defaultabox<_Uty>& _That) : _Engaged{_That} { + if (_That) { + _Construct_in_place(_Val, *_That); + } + } + + template <_Not_same_as<_Ty> _Uty> + requires convertible_to<_Uty, _Ty> + constexpr _Defaultabox(_Defaultabox<_Uty>&& _That) : _Engaged{_That} { + if (_That) { + _Construct_in_place(_Val, _STD move(*_That)); + } + } + // clang-format off _Defaultabox& operator=(const _Defaultabox&) noexcept requires copyable<_Ty> && is_trivially_copy_assignable_v<_Ty> = default; @@ -627,6 +643,24 @@ namespace ranges { class _Defaultabox<_Ty> { // provide the same API more efficiently for default-constructible types // clang-format on public: + _Defaultabox() = default; + + template <_Not_same_as<_Ty> _Uty> + requires convertible_to + constexpr _Defaultabox(const _Defaultabox<_Uty>& _That) { + if (_That) { + _Value = static_cast<_Ty>(*_That); + } + } + + template <_Not_same_as<_Ty> _Uty> + requires convertible_to<_Uty, _Ty> + constexpr _Defaultabox(_Defaultabox<_Uty>&& _That) { + if (_That) { + _Value = static_cast<_Ty>(_STD move(*_That)); + } + } + constexpr _Defaultabox& operator=(const _Ty& _Right) noexcept( is_nothrow_copy_assignable_v<_Ty>) requires copyable<_Ty> { _Value = _Right; From c47a8cf6a91c75aa431367b4aa2c3ae5adf6c8be Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Wed, 5 Jan 2022 19:43:31 -0800 Subject: [PATCH 16/31] Fix iterator_traits --- stl/inc/iterator | 11 ++++++----- tests/std/tests/P0896R4_common_iterator/test.cpp | 11 +++++++++-- 2 files changed, 15 insertions(+), 7 deletions(-) diff --git a/stl/inc/iterator b/stl/inc/iterator index 58bf0169c4..37b691ea79 100644 --- a/stl/inc/iterator +++ b/stl/inc/iterator @@ -1042,14 +1042,15 @@ struct incrementable_traits> { using difference_type = iter_difference_t<_Iter>; }; -template +template struct _Common_iterator_pointer_type { using pointer = void; }; -template <_Has_member_arrow _Iter> -struct _Common_iterator_pointer_type<_Iter> { - using pointer = decltype(_STD declval<_Iter&>().operator->()); +template + requires _Has_member_arrow> +struct _Common_iterator_pointer_type<_Iter, _Se> { + using pointer = decltype(_STD declval&>().operator->()); }; template @@ -1064,7 +1065,7 @@ struct iterator_traits> { using iterator_category = conditional_t<_Has_forward_category<_Iter>, forward_iterator_tag, input_iterator_tag>; using value_type = iter_value_t<_Iter>; using difference_type = iter_difference_t<_Iter>; - using pointer = typename _Common_iterator_pointer_type<_Iter>::pointer; + using pointer = typename _Common_iterator_pointer_type<_Iter, _Se>::pointer; using reference = iter_reference_t<_Iter>; }; diff --git a/tests/std/tests/P0896R4_common_iterator/test.cpp b/tests/std/tests/P0896R4_common_iterator/test.cpp index f715306395..7ae049ffcc 100644 --- a/tests/std/tests/P0896R4_common_iterator/test.cpp +++ b/tests/std/tests/P0896R4_common_iterator/test.cpp @@ -49,8 +49,15 @@ struct instantiator { } using ipointer = typename iterator_traits::pointer; - if constexpr (_Has_member_arrow) { - STATIC_ASSERT(same_as().operator->())>); + if constexpr (std::is_pointer_v || _Has_member_arrow) { + STATIC_ASSERT(same_as); + } else if constexpr (std::is_reference_v>) { + STATIC_ASSERT(same_as>>); + } else if constexpr (std::constructible_from, iter_reference_t>) { + // proxy is a class type + STATIC_ASSERT(std::is_class_v); + // with a member operator->() const + STATIC_ASSERT(&std::add_const_t::operator->); } else { STATIC_ASSERT(same_as); } From efd4f4409d9d63839520399df232b68b83927846 Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Fri, 7 Jan 2022 21:38:12 -0800 Subject: [PATCH 17/31] _Define_ default constructor of basic_format_args --- stl/inc/format | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/stl/inc/format b/stl/inc/format index 8aa71e6780..469ddac821 100644 --- a/stl/inc/format +++ b/stl/inc/format @@ -1578,8 +1578,10 @@ class _Format_arg_store<_Context> {}; template class basic_format_args { public: - basic_format_args() noexcept; + basic_format_args() noexcept = default; + basic_format_args(const _Format_arg_store<_Context>&) noexcept {} + template basic_format_args(const _Format_arg_store<_Context, _Args...>& _Store) noexcept : _Num_args(sizeof...(_Args)), _Index_array(_Store._Index_array) {} From f769d458b482b1561ba0f88ecffe7ee11dd54da0 Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Sat, 8 Jan 2022 08:31:02 -0800 Subject: [PATCH 18/31] Workaround DevCom-1632113 in `to_address` Test coverage in `libcxx/test/std/utilities/memory/pointer.conversion/to_address.pass.cpp`. --- stl/inc/xutility | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/stl/inc/xutility b/stl/inc/xutility index d545d12d71..b46447da2c 100644 --- a/stl/inc/xutility +++ b/stl/inc/xutility @@ -188,12 +188,20 @@ struct pointer_traits<_Ty*> { }; #if _HAS_CXX20 +#ifdef __cpp_lib_concepts +template +concept _Has_to_address = requires(const _Ty& _Val) { + typename pointer_traits<_Ty>; + pointer_traits<_Ty>::to_address(_Val); +}; +#else // ^^^ Use concept / use variable template vvv template -inline constexpr bool _Has_to_address_v = false; // determines whether _Ptr has pointer_traits<_Ptr>::to_address(p) +inline constexpr bool _Has_to_address = false; // determines whether pointer_traits<_Ty> has to_address template inline constexpr bool - _Has_to_address_v<_Ty, void_t::to_address(_STD declval()))>> = true; + _Has_to_address<_Ty, void_t::to_address(_STD declval()))>> = true; +#endif // __cpp_lib_concepts template _NODISCARD constexpr _Ty* to_address(_Ty* const _Val) noexcept { @@ -204,7 +212,7 @@ _NODISCARD constexpr _Ty* to_address(_Ty* const _Val) noexcept { template _NODISCARD constexpr auto to_address(const _Ptr& _Val) noexcept { - if constexpr (_Has_to_address_v<_Ptr>) { + if constexpr (_Has_to_address<_Ptr>) { return pointer_traits<_Ptr>::to_address(_Val); } else { return _STD to_address(_Val.operator->()); // plain pointer overload must come first From 0c932a4776827eebf538d9023d884cecd5614b3a Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Thu, 13 Jan 2022 15:07:43 -0800 Subject: [PATCH 19/31] Oops - bug in ranges::uninitialized_copy_n --- stl/inc/memory | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stl/inc/memory b/stl/inc/memory index fc31544b5c..54bc37c064 100644 --- a/stl/inc/memory +++ b/stl/inc/memory @@ -171,7 +171,7 @@ namespace ranges { } else { _Uninitialized_backout _Backout{_STD move(_OFirst)}; - for (; _Count > 0 && _OFirst != _OLast; --_Count, (void) ++_IFirst) { + for (; _Count > 0 && _Backout._Last != _OLast; --_Count, (void) ++_IFirst) { _Backout._Emplace_back(*_IFirst); } From 413cdd777dd90aa9679e4e3f17b82eb4434d7b35 Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Tue, 18 Jan 2022 22:53:21 -0800 Subject: [PATCH 20/31] Update skips and magic_comments; bump LLVM reference --- llvm-project | 2 +- tests/libcxx/expected_results.txt | 372 ++++++++++++----- tests/libcxx/magic_comments.txt | 3 + tests/libcxx/skipped_tests.txt | 637 +++++++++++++++++++++++++----- 4 files changed, 811 insertions(+), 203 deletions(-) diff --git a/llvm-project b/llvm-project index 6057517904..b8d38e8b4f 160000 --- a/llvm-project +++ b/llvm-project @@ -1 +1 @@ -Subproject commit 605751790418ca4fb1df1e94dfbac34cfcc1b96f +Subproject commit b8d38e8b4fcab071c5c4cb698e154023d06de69e diff --git a/tests/libcxx/expected_results.txt b/tests/libcxx/expected_results.txt index 24b94621ff..03b49b8974 100644 --- a/tests/libcxx/expected_results.txt +++ b/tests/libcxx/expected_results.txt @@ -15,25 +15,17 @@ std/input.output/iostreams.base/ios.base/ios.base.storage/pword.pass.cpp SKIPPED std/utilities/smartptr/unique.ptr/unique.ptr.class/unique.ptr.ctor/null.pass.cpp FAIL # allocator. +std/iterators/iterator.requirements/iterator.cust/iterator.cust.move/iter_rvalue_reference_t.pass.cpp FAIL std/utilities/memory/default.allocator/allocator.ctor.pass.cpp FAIL -# path::value_type is char assumptions -std/input.output/file.streams/fstreams/filebuf.members/open_path.pass.cpp FAIL -std/input.output/file.streams/fstreams/fstream.cons/path.pass.cpp FAIL -std/input.output/file.streams/fstreams/fstream.members/open_path.pass.cpp FAIL -std/input.output/file.streams/fstreams/ofstream.cons/path.pass.cpp FAIL -std/input.output/file.streams/fstreams/ofstream.members/open_path.pass.cpp FAIL - # This test is passing non-BidirectionalIterators to std::prev. # LWG-3197 "std::prev should not require BidirectionalIterator" (New) std/iterators/iterator.primitives/iterator.operations/prev.pass.cpp FAIL # Itanium ABI assumptions that current_exception and rethrow_exception don't copy the exception object -# rethrow_if_nested.pass.cpp can crash. -std/language.support/support.exception/propagation/current_exception.pass.cpp FAIL +std/language.support/support.exception/except.nested/rethrow_if_nested.pass.cpp SKIPPED std/language.support/support.exception/propagation/make_exception_ptr.pass.cpp FAIL std/language.support/support.exception/propagation/rethrow_exception.pass.cpp FAIL -std/language.support/support.exception/except.nested/rethrow_if_nested.pass.cpp SKIPPED # Testing nonstandard behavior std/utilities/template.bitset/bitset.cons/string_ctor.pass.cpp FAIL @@ -42,8 +34,8 @@ std/utilities/template.bitset/bitset.cons/string_ctor.pass.cpp FAIL std/thread/futures/futures.task/futures.task.members/dtor.pass.cpp SKIPPED std/thread/futures/futures.unique_future/wait_until.pass.cpp SKIPPED -# libcxx is incorrect on what the type passed to allocator construct should be -# See https://reviews.llvm.org/D61364 +# libcxx is incorrect on what the type passed to allocator::construct should be (https://reviews.llvm.org/D61364) + std/containers/associative/map/map.modifiers/insert_and_emplace_allocator_requirements.pass.cpp FAIL std/containers/associative/set/insert_and_emplace_allocator_requirements.pass.cpp FAIL std/containers/unord/unord.map/unord.map.modifiers/insert_and_emplace_allocator_requirements.pass.cpp FAIL @@ -61,18 +53,36 @@ std/language.support/support.limits/support.limits.general/string_view.version.p # libc++ doesn't yet implement P2231R1, so it expects an old value for `__cpp_lib_optional` std/language.support/support.limits/support.limits.general/optional.version.pass.cpp FAIL -# test emits warning C4310: cast truncates constant value -std/numerics/bit/bitops.rot/rotl.pass.cpp:0 FAIL - # libc++ doesn't yet implement P1754R1 or P1964R2, so it expects an old value for `__cpp_lib_concepts` std/language.support/support.limits/support.limits.general/concepts.version.pass.cpp FAIL -# Bogus test believes that optional cannot be a literal type -std/utilities/optional/optional.object/optional.object.dtor/dtor.pass.cpp:0 FAIL - # Bogus test believes that copyability of array must be the same as array std/containers/sequences/array/array.cons/implicit_copy.pass.cpp FAIL +# string_view and array iterators are not portably pointers (https://reviews.llvm.org/D117368) +std/iterators/iterator.primitives/iterator.traits/cxx20_iterator_traits.compile.pass.cpp FAIL +std/iterators/iterator.requirements/iterator.cust/iterator.cust.move/iter_move.pass.cpp FAIL +std/strings/string.view/string.view.cons/from_iterator_sentinel.pass.cpp FAIL +std/strings/string.view/string.view.deduct/iterator_sentinel.pass.cpp FAIL +std/utilities/format/format.formatter/format.parse.ctx/advance_to.pass.cpp FAIL +std/utilities/format/format.formatter/format.parse.ctx/begin.pass.cpp FAIL +std/utilities/format/format.formatter/format.parse.ctx/ctor.pass.cpp FAIL +std/utilities/format/format.formatter/format.parse.ctx/end.pass.cpp FAIL + +# libc++ doesn't correctly constrain the iterator_traits specialization for common_iterator (https://reviews.llvm.org/D117449) +std/iterators/predef.iterators/iterators.common/iterator_traits.compile.pass.cpp FAIL + +# libc++ hasn't updated {move,reverse}_iterator for P0896R4 +std/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op=/move_iterator.pass.cpp FAIL +std/iterators/predef.iterators/move.iterators/move.iterator/iterator_concept_conformance.compile.pass.cpp FAIL +std/iterators/predef.iterators/reverse.iterators/iterator_concept_conformance.compile.pass.cpp FAIL +std/iterators/predef.iterators/reverse.iterators/reverse.iter.cmp/three-way.pass.cpp FAIL +std/iterators/predef.iterators/reverse.iterators/reverse.iter.cons/assign.pass.cpp FAIL + +# optional's comparisons aren't portably constrained (https://reviews.llvm.org/D116884) +std/concepts/concepts.compare/concepts.totallyordered/totally_ordered.pass.cpp FAIL +std/concepts/concepts.compare/concept.equalitycomparable/equality_comparable.compile.pass.cpp FAIL + # *** INTERACTIONS WITH CONTEST / C1XX THAT UPSTREAM LIKELY WON'T FIX *** # Tracked by VSO-593630 " Enable libcxx filesystem tests" @@ -105,7 +115,6 @@ std/input.output/filesystems/class.path/path.itr/iterator.pass.cpp SKIPPED std/input.output/filesystems/class.path/path.member/path.append.pass.cpp SKIPPED std/input.output/filesystems/class.path/path.member/path.compare.pass.cpp SKIPPED std/input.output/filesystems/class.path/path.member/path.concat.pass.cpp SKIPPED -std/input.output/filesystems/class.path/path.member/path.assign/braced_init.pass.cpp SKIPPED std/input.output/filesystems/class.path/path.member/path.assign/copy.pass.cpp SKIPPED std/input.output/filesystems/class.path/path.member/path.assign/move.pass.cpp SKIPPED std/input.output/filesystems/class.path/path.member/path.assign/source.pass.cpp SKIPPED @@ -127,7 +136,6 @@ std/input.output/filesystems/class.path/path.member/path.native.obs/c_str.pass.c std/input.output/filesystems/class.path/path.member/path.native.obs/named_overloads.pass.cpp SKIPPED std/input.output/filesystems/class.path/path.member/path.native.obs/native.pass.cpp SKIPPED std/input.output/filesystems/class.path/path.member/path.native.obs/operator_string.pass.cpp SKIPPED -std/input.output/filesystems/class.path/path.member/path.native.obs/string_alloc.pass.cpp SKIPPED std/input.output/filesystems/class.path/path.nonmember/append_op.pass.cpp SKIPPED std/input.output/filesystems/class.path/path.nonmember/path.factory.pass.cpp SKIPPED std/input.output/filesystems/class.path/path.nonmember/path.io.pass.cpp SKIPPED @@ -194,14 +202,23 @@ std/input.output/filesystems/fs.op.funcs/fs.op.temp_dir_path/temp_directory_path std/input.output/filesystems/fs.op.funcs/fs.op.weakly_canonical/weakly_canonical.pass.cpp SKIPPED # generate_feature_test_macro_components.py needs to learn about C1XX -std/language.support/support.limits/support.limits.general/type_traits.version.pass.cpp:0 FAIL std/language.support/support.limits/support.limits.general/version.version.pass.cpp FAIL # Contest does not understand .sh tests, which must be run specially +std/atomics/atomics.general/replace_failure_order_codegen.sh.cpp SKIPPED +std/containers/associative/map/PR28469_undefined_behavior_segfault.sh.cpp SKIPPED +std/input.output/iostream.objects/narrow.stream.objects/cerr.sh.cpp SKIPPED std/input.output/iostream.objects/narrow.stream.objects/cin.sh.cpp SKIPPED +std/input.output/iostream.objects/narrow.stream.objects/clog.sh.cpp SKIPPED +std/input.output/iostream.objects/narrow.stream.objects/cout.sh.cpp SKIPPED +std/input.output/iostream.objects/wide.stream.objects/wcerr.sh.cpp SKIPPED std/input.output/iostream.objects/wide.stream.objects/wcin.sh.cpp SKIPPED +std/input.output/iostream.objects/wide.stream.objects/wclog.sh.cpp SKIPPED +std/input.output/iostream.objects/wide.stream.objects/wcout.sh.cpp SKIPPED std/namespace/addressable_functions.sh.cpp SKIPPED +std/strings/basic.string/string.capacity/shrink_to_fit.explicit_instantiation.sh.cpp SKIPPED std/thread/thread.condition/thread.condition.condvarany/wait_terminates.sh.cpp SKIPPED +std/utilities/format/format.arguments/format.arg.store/make_format_args.sh.cpp SKIPPED # These tests set an allocator with a max_size() too small to default construct an unordered container # (due to our minimum bucket size). @@ -212,6 +229,7 @@ std/containers/unord/unord.set/max_size.pass.cpp FAIL # Extreme compiler memory consumption. std/utilities/tuple/tuple.tuple/tuple.apply/apply_large_arity.pass.cpp SKIPPED +std/utilities/tuple/tuple.tuple/tuple.cnstr/recursion_depth.pass.cpp SKIPPED # .verify.cpp tests use clang-verify to validate warnings std/containers/associative/map/map.access/empty.verify.cpp SKIPPED @@ -279,13 +297,26 @@ std/utilities/function.objects/negators/unary_negate.depr_in_cxx17.verify.cpp SK std/utilities/memory/allocator.traits/allocator.traits.members/allocate.verify.cpp SKIPPED std/utilities/memory/default.allocator/allocator_types.deprecated_in_cxx17.verify.cpp SKIPPED std/utilities/memory/default.allocator/allocator_types.removed_in_cxx20.verify.cpp SKIPPED -std/utilities/memory/default.allocator/allocator_void.deprecated_in_cxx17.verify.cpp SKIPPED std/utilities/memory/default.allocator/allocator.members/allocate.constexpr.size.verify.cpp SKIPPED std/utilities/memory/default.allocator/allocator.members/allocate.verify.cpp SKIPPED +# Deprecation is a mess. We disable all deprecations in msvc_stdlib_force_include.hpp to allow libc++ tests for +# deprecated features to pass, which breaks when libc++ deprecates the feature and adds two tests that (1) pass +# with deprecation suppressed, and (2) fail without deprecation suppression. I think we should instead translate +# libc++ un-deprecation macros to STL un-deprecation macros in the force-include header, and just skip tests when +# we deprecate before they do. +std/utilities/meta/meta.unary/meta.unary.prop/is_literal_type.deprecated.fail.cpp FAIL + # *** MISSING STL FEATURES *** -# Nothing here! :-) +# P2321R2 zip +std/language.support/support.limits/support.limits.general/tuple.version.pass.cpp FAIL +std/language.support/support.limits/support.limits.general/utility.version.pass.cpp FAIL +std/utilities/meta/meta.trans/meta.trans.other/common_reference.compile.pass.cpp FAIL +std/utilities/meta/meta.trans/meta.trans.other/common_type.pass.cpp FAIL + +# P1328R1 constexpr type_info::operator==() +std/language.support/support.limits/support.limits.general/typeinfo.version.pass.cpp FAIL # *** MISSING COMPILER FEATURES *** @@ -305,24 +336,98 @@ std/thread/futures/futures.promise/set_value_at_thread_exit_const.pass.cpp FAIL std/thread/futures/futures.promise/set_value_at_thread_exit_void.pass.cpp FAIL std/thread/futures/futures.task/futures.task.members/make_ready_at_thread_exit.pass.cpp FAIL +# LWG-3633 "Atomics are copy constructible and copy assignable from volatile atomics" (Open) +std/atomics/atomics.types.generic/copy_semantics_traits.pass.cpp FAIL + # *** C1XX COMPILER BUGS *** # DevCom-409222 "Constructing rvalue reference from non-reference-related lvalue reference" std/utilities/meta/meta.unary/meta.unary.prop/is_constructible.pass.cpp:0 FAIL # DevCom-876860 "conditional operator errors" blocks readable. -std/containers/views/span.cons/ptr_len.pass.cpp:0 FAIL -std/containers/views/span.cons/ptr_ptr.pass.cpp:0 FAIL +std/concepts/concepts.lang/concept.common/common_with.compile.pass.cpp:0 FAIL +std/concepts/concepts.lang/concept.commonref/common_reference.compile.pass.cpp:0 FAIL +std/containers/views/span.cons/iterator_sentinel.pass.cpp:0 FAIL +std/iterators/iterator.requirements/iterator.concepts/iterator.concept.bidir/bidirectional_iterator.compile.pass.cpp:0 FAIL +std/iterators/iterator.requirements/iterator.concepts/iterator.concept.random.access/contiguous_iterator.compile.pass.cpp:0 FAIL +std/iterators/iterator.requirements/iterator.concepts/iterator.concept.readable/indirectly_readable.compile.pass.cpp:0 FAIL +std/iterators/iterator.requirements/iterator.concepts/iterator.concept.forward/forward_iterator.compile.pass.cpp:0 FAIL +std/iterators/iterator.requirements/iterator.concepts/iterator.concept.input/input_iterator.compile.pass.cpp:0 FAIL +std/iterators/iterator.requirements/iterator.concepts/iterator.concept.random.access/random_access_iterator.compile.pass.cpp:0 FAIL # VSO-1271673 "static analyzer doesn't know about short-circuiting" std/algorithms/alg.sorting/alg.sort/partial.sort/partial_sort.pass.cpp:0 FAIL std/algorithms/alg.sorting/alg.sort/partial.sort/partial_sort_comp.pass.cpp:0 FAIL +# DevCom-1559808: (structured bindings for `subrange` in a constant expression) +std/ranges/range.utility/range.subrange/structured_bindings.pass.cpp:0 FAIL + +# DevCom-1626139 "compile-time NaN comparison" +std/iterators/predef.iterators/reverse.iterators/reverse.iter.cmp/three-way.pass.cpp:0 FAIL +std/library/description/conventions/expos.only.func/synth_three_way.pass.cpp:0 FAIL +std/utilities/function.objects/comparisons/compare_three_way.pass.cpp:0 FAIL +std/utilities/tuple/tuple.tuple/tuple.rel/three_way.pass.cpp:0 FAIL +std/utilities/utility/pairs/pairs.spec/three_way_comparison.pass.cpp:0 FAIL + +# DevCom-1626727: bogus "failure was caused by a conversion from void* to a pointer-to-object type" for conversion to void +std/algorithms/robust_re_difference_type.compile.pass.cpp:0 FAIL + +# DevCom-1627396: C1XX's __is_convertible_to intrinsic mis-handles volatile array lvalues +std/concepts/concepts.lang/concept.swappable/swappable_with.compile.pass.cpp:0 FAIL + +# DevCom-1628714: C1XX refuses nullptr_t == reference-to-function in a requires expression +std/concepts/concepts.compare/concept.equalitycomparable/equality_comparable_with.compile.pass.cpp:0 FAIL + +# DevCom-1629961: ICE testing if function lvalues are comparable with the spaceship operator +std/language.support/cmp/cmp.concept/three_way_comparable.compile.pass.cpp:0 FAIL + +# DevCom-1638496: C1XX doesn't properly reject int <=> unsigned +std/language.support/cmp/cmp.concept/three_way_comparable_with.compile.pass.cpp:0 FAIL +std/language.support/cmp/cmp.result/compare_three_way_result.compile.pass.cpp:0 FAIL +std/utilities/tuple/tuple.tuple/tuple.rel/three_way.pass.cpp:0 FAIL + +# DevCom-1638563: icky static analysis false positive +std/language.support/support.coroutines/end.to.end/go.pass.cpp:0 FAIL + # *** CLANG COMPILER BUGS *** # LLVM-46207 Clang's tgmath.h interferes with the UCRT's tgmath.h std/depr/depr.c.headers/tgmath_h.pass.cpp:1 FAIL +# Clang doesn't implement the common coroutine ABI until LLVM 14 +std/language.support/support.coroutines/coroutine.handle/coroutine.handle.capacity/operator_bool.pass.cpp:1 FAIL +std/language.support/support.coroutines/coroutine.handle/coroutine.handle.compare/equal_comp.pass.cpp:1 FAIL +std/language.support/support.coroutines/coroutine.handle/coroutine.handle.compare/less_comp.pass.cpp:1 FAIL +std/language.support/support.coroutines/coroutine.handle/coroutine.handle.completion/done.pass.cpp:1 FAIL +std/language.support/support.coroutines/coroutine.handle/coroutine.handle.con/assign.pass.cpp:1 FAIL +std/language.support/support.coroutines/coroutine.handle/coroutine.handle.con/construct.pass.cpp:1 FAIL +std/language.support/support.coroutines/coroutine.handle/coroutine.handle.export/address.pass.cpp:1 FAIL +std/language.support/support.coroutines/coroutine.handle/coroutine.handle.export/from_address.pass.cpp:1 FAIL +std/language.support/support.coroutines/coroutine.handle/coroutine.handle.hash/hash.pass.cpp:1 FAIL +std/language.support/support.coroutines/coroutine.handle/coroutine.handle.noop/noop_coroutine.pass.cpp:1 FAIL +std/language.support/support.coroutines/coroutine.handle/coroutine.handle.prom/promise.pass.cpp:1 FAIL +std/language.support/support.coroutines/coroutine.handle/coroutine.handle.resumption/destroy.pass.cpp:1 FAIL +std/language.support/support.coroutines/coroutine.handle/coroutine.handle.resumption/resume.pass.cpp:1 FAIL +std/language.support/support.coroutines/coroutine.handle/void_handle.pass.cpp:1 FAIL +std/language.support/support.coroutines/coroutine.traits/promise_type.pass.cpp:1 FAIL +std/language.support/support.coroutines/coroutine.trivial.awaitables/suspend_always.pass.cpp:1 FAIL +std/language.support/support.coroutines/coroutine.trivial.awaitables/suspend_never.pass.cpp:1 FAIL +std/language.support/support.coroutines/end.to.end/await_result.pass.cpp:1 FAIL +std/language.support/support.coroutines/end.to.end/bool_await_suspend.pass.cpp:1 FAIL +std/language.support/support.coroutines/end.to.end/expected.pass.cpp:1 FAIL +std/language.support/support.coroutines/end.to.end/fullexpr-dtor.pass.cpp:1 FAIL +std/language.support/support.coroutines/end.to.end/generator.pass.cpp:1 FAIL +std/language.support/support.coroutines/end.to.end/go.pass.cpp:1 FAIL +std/language.support/support.coroutines/end.to.end/multishot_func.pass.cpp:1 FAIL +std/language.support/support.coroutines/end.to.end/oneshot_func.pass.cpp:1 FAIL +std/language.support/support.limits/support.limits.general/coroutine.version.pass.cpp:1 FAIL + +# LLVM-52643 Requires-expression too eagerly completes associated type +std/ranges/range.access/begin.pass.cpp:1 FAIL +std/ranges/range.access/data.pass.cpp:1 FAIL +std/ranges/range.access/end.pass.cpp:1 FAIL +std/ranges/range.req/range.range/range.compile.pass.cpp:1 FAIL + # *** CLANG ISSUES, NOT YET ANALYZED *** # Clang doesn't enable sized deallocation by default. Should we add -fsized-deallocation or do something else? @@ -412,14 +517,20 @@ std/utilities/meta/meta.trans/meta.trans.other/aligned_storage.pass.cpp FAIL std/depr/depr.c.headers/math_h.pass.cpp FAIL std/numerics/c.math/cmath.pass.cpp FAIL -# GH-1596: : unqualified calls to _Adl_verify_range incorrectly cause instantiation -std/algorithms/robust_against_adl.pass.cpp FAIL +# GH-2358: : path's comparison operators are IF-NDR +std/input.output/filesystems/class.path/range_concept_conformance.compile.pass.cpp FAIL + +# GH-1374: Spaceship CPO wording in [cmp.alg] needs an overhaul +# (Technically an STL bug until I fix the wording in the working draft to agree.) +std/language.support/cmp/cmp.alg/partial_order.pass.cpp FAIL +std/language.support/cmp/cmp.alg/strong_order.pass.cpp FAIL +std/language.support/cmp/cmp.alg/weak_order.pass.cpp FAIL # *** CRT BUGS *** # We're permanently missing aligned_alloc(). -std/depr/depr.c.headers/stdlib_h.pass.cpp FAIL -std/language.support/support.runtime/cstdlib.pass.cpp FAIL +std/depr/depr.c.headers/stdlib_h.aligned_alloc.compile.pass.cpp FAIL +std/language.support/support.runtime/cstdlib.aligned_alloc.compile.pass.cpp FAIL # OS-11107628 "_Exit allows cleanup in other DLLs" std/thread/thread.threads/thread.thread.class/thread.thread.assign/move2.pass.cpp SKIPPED @@ -445,6 +556,7 @@ std/utilities/smartptr/unique.ptr/unique.ptr.class/unique.ptr.asgn/move.pass.cpp std/language.support/support.limits/support.limits.general/string.version.pass.cpp FAIL # Not yet analyzed, likely bogus tests. Appears to be timing assumptions. +std/atomics/atomics.types.operations/atomics.types.operations.wait/atomic_notify_all.pass.cpp SKIPPED std/thread/futures/futures.async/async.pass.cpp SKIPPED std/thread/futures/futures.shared_future/get.pass.cpp SKIPPED std/thread/futures/futures.shared_future/wait.pass.cpp SKIPPED @@ -523,24 +635,11 @@ std/input.output/iostream.format/input.streams/istream.unformatted/get_pointer_s # Sensitive to implementation details. Assertion failed: test_alloc_base::count == expected_num_allocs std/containers/container.requirements/container.requirements.general/allocator_move.pass.cpp FAIL -# Tests std::weak_equality/strong_equality which were removed by P1959R0 -std/language.support/cmp/cmp.common/common_comparison_category.pass.cpp FAIL -std/language.support/cmp/cmp.partialord/partialord.pass.cpp FAIL -std/language.support/cmp/cmp.strongeq/cmp.strongeq.pass.cpp FAIL -std/language.support/cmp/cmp.strongord/strongord.pass.cpp FAIL -std/language.support/cmp/cmp.weakeq/cmp.weakeq.pass.cpp FAIL -std/language.support/cmp/cmp.weakord/weakord.pass.cpp FAIL - # Comment: "Test C99 compound literal." # Code: `(int[]){3, 4}` # error C4576: a parenthesized type followed by an initializer list is a non-standard explicit type conversion syntax std/containers/sequences/array/array.creation/to_array.pass.cpp:0 FAIL -# Tests that need to learn that iterators have non-void difference types in C++20 -std/iterators/predef.iterators/insert.iterators/back.insert.iterator/types.pass.cpp FAIL -std/iterators/predef.iterators/insert.iterators/front.insert.iterator/types.pass.cpp FAIL -std/iterators/predef.iterators/insert.iterators/insert.iterator/types.pass.cpp FAIL - # Tests emit warning C4244: 'argument': conversion from 'T' to 'const std::complex::_Ty', possible loss of data std/numerics/complex.number/cmplx.over/conj.pass.cpp:0 FAIL std/numerics/complex.number/cmplx.over/pow.pass.cpp:0 FAIL @@ -563,38 +662,18 @@ std/numerics/rand/rand.dis/rand.dist.samp/rand.dist.samp.plinear/eval.pass.cpp F # Assertion failed: (std::lerp(T(2.3), T(2.3), inf) == T(2.3)) # Asserts `(std::lerp(T(2.3), T(2.3), inf) == T(2.3))` and `std::isnan(std::lerp(T( 0), T( 0), inf))` # They shouldn't behave differently. Both of them should probably return NaN. -std/numerics/c.math/c.math.lerp/c.math.lerp.pass.cpp FAIL +std/numerics/c.math/lerp.pass.cpp FAIL # --month{14} should be 1, not 13 as the test expects std/utilities/time/time.cal/time.cal.month/time.cal.month.members/decrement.pass.cpp FAIL -# test is broken due to month_weekday not being default constructible -std/utilities/time/time.cal/time.cal.mwd/time.cal.mwd.members/month.pass.cpp FAIL - # conversion from '__int64' to 'long', possible loss of data std/utilities/time/time.hms/time.hms.members/seconds.pass.cpp:0 FAIL std/utilities/time/time.hms/time.hms.members/subseconds.pass.cpp:0 FAIL -# Code: `for (int i = 1000; i < 20; ++i)` -# warning C6294: Ill-defined for-loop: initial condition does not satisfy test. Loop body not executed. -std/utilities/time/time.cal/time.cal.month/time.cal.month.nonmembers/comparisons.pass.cpp:0 FAIL -std/utilities/time/time.cal/time.cal.ym/time.cal.ym.nonmembers/comparisons.pass.cpp:0 FAIL -std/utilities/time/time.cal/time.cal.ymd/time.cal.ymd.nonmembers/comparisons.pass.cpp:0 FAIL -std/utilities/time/time.cal/time.cal.ymdlast/time.cal.ymdlast.nonmembers/comparisons.pass.cpp:0 FAIL -std/utilities/time/time.cal/time.cal.ymwd/time.cal.ymwd.nonmembers/comparisons.pass.cpp:0 FAIL -std/utilities/time/time.cal/time.cal.ymwdlast/time.cal.ymwdlast.nonmembers/comparisons.pass.cpp:0 FAIL - -# Tests are manually declaring printf, which appears to be unused. -# warning C28301: No annotations for first declaration of 'printf'. -std/utilities/time/time.cal/time.cal.weekday/time.cal.weekday.nonmembers/minus.pass.cpp:0 FAIL -std/utilities/time/time.cal/time.cal.year/time.cal.year.nonmembers/minus.pass.cpp:0 FAIL - # Bogus test passes a class type as the second argument to std::advance std/iterators/iterator.primitives/iterator.operations/robust_against_adl.pass.cpp FAIL -# Non-Standard test should be moved from libcxx/test/std to libcxx/test/libcxx -std/utilities/memory/util.smartptr/util.smartptr.shared/libcxx.control_block_layout.pass.cpp FAIL - # Non-Standard assumption that std::filesystem::file_time_type::duration::period is std::nano std/input.output/filesystems/fs.filesystem.synopsis/file_time_type_resolution.compile.pass.cpp FAIL @@ -620,12 +699,6 @@ std/strings/string.conversions/stoll.pass.cpp FAIL std/strings/string.conversions/stoul.pass.cpp FAIL std/strings/string.conversions/stoull.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 @@ -638,22 +711,94 @@ std/language.support/support.limits/support.limits.general/iterator.version.pass # Test expects __cpp_lib_chrono to have the old value 201611L for P0505R0; we define the C++20 value 201907L for P1466R3. std/language.support/support.limits/support.limits.general/chrono.version.pass.cpp FAIL -# Test expects __cpp_lib_format to have the old value 201907L for P0645R10; we define the C++20 value 202106L for P2216R3. -std/language.support/support.limits/support.limits.general/format.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 -# Test should be enabled after LLVM update -# updated test https://github.com/llvm/llvm-project/commit/0324b46cd873abc4fabe19f4bd468d10398ffd0d#diff-a9be5c3f8e18be99f40fb35f58960f400413a76252d86b53f80d76cb09cb53ef -# should work +# libc++ doesn't implement P2231R1 Add further constexpr support for optional/variant std/language.support/support.limits/support.limits.general/variant.version.pass.cpp FAIL -# libc++ doesn't implement P2186R2 Removing Garbage Collection Support -std/utilities/memory/util.dynamic.safety/get_pointer_safety.pass.cpp FAIL -std/utilities/memory/util.dynamic.safety/declare_no_pointers.pass.cpp FAIL -std/utilities/memory/util.dynamic.safety/declare_reachable.pass.cpp FAIL +# Tests non-portable behavior +std/utilities/format/format.formatter/format.context/format.context/advance_to.pass.cpp FAIL +std/utilities/format/format.formatter/format.context/format.context/arg.pass.cpp FAIL +std/utilities/format/format.formatter/format.context/format.context/ctor.pass.cpp FAIL +std/utilities/format/format.formatter/format.context/format.context/locale.pass.cpp FAIL +std/utilities/format/format.formatter/format.context/format.context/out.pass.cpp FAIL +std/utilities/format/format.formatter/format.context/format.formatter.spec/formatter.bool.pass.cpp FAIL +std/utilities/format/format.formatter/format.context/format.formatter.spec/formatter.c_string.pass.cpp FAIL +std/utilities/format/format.formatter/format.context/format.formatter.spec/formatter.char.pass.cpp FAIL +std/utilities/format/format.formatter/format.context/format.formatter.spec/formatter.const_char_array.pass.cpp FAIL +std/utilities/format/format.formatter/format.context/format.formatter.spec/formatter.signed_integral.pass.cpp FAIL +std/utilities/format/format.formatter/format.context/format.formatter.spec/formatter.string.pass.cpp FAIL +std/utilities/format/format.formatter/format.context/format.formatter.spec/formatter.unsigned_integral.pass.cpp FAIL + +# libc++ doesn't yet implement P2216R3 (test uses non-constant-expression format strings) +std/utilities/format/format.functions/format.pass.cpp FAIL +std/utilities/format/format.functions/format.locale.pass.cpp FAIL +std/utilities/format/format.functions/format_to.locale.pass.cpp FAIL +std/utilities/format/format.functions/format_to.pass.cpp FAIL +std/utilities/format/format.functions/format_to_n.pass.cpp FAIL +std/utilities/format/format.functions/format_to_n.locale.pass.cpp FAIL +std/utilities/format/format.functions/formatted_size.pass.cpp FAIL +std/utilities/format/format.functions/formatted_size.locale.pass.cpp FAIL +std/utilities/format/format.functions/locale-specific_form.pass.cpp FAIL + +# libc++ chose option A for [time.clock.file.members], and we chose option B. +std/utilities/time/time.clock/time.clock.file/to_from_sys.pass.cpp FAIL + +# libc++ is missing various Ranges DRs +std/language.support/support.limits/support.limits.general/ranges.version.pass.cpp FAIL + +# test compares singular and non-singular string iterators +std/strings/basic.string/string.iterators/iterators.pass.cpp FAIL + +# test compares iterators into distinct `array`s +std/ranges/range.adaptors/range.all/range.owning.view/begin_end.pass.cpp FAIL + +# libc++ allows some forbidden unique_ptr conversions +std/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.assign/unique_ptr_Y.pass.cpp FAIL +std/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.const/unique_ptr.pass.cpp FAIL + +# non-portable test of strengthened noexcept +std/ranges/range.adaptors/range.drop/ctor.default.pass.cpp FAIL +std/ranges/range.adaptors/range.transform/iterator/deref.pass.cpp FAIL +std/ranges/range.adaptors/range.transform/iterator/iter_move.pass.cpp FAIL +std/ranges/range.adaptors/range.transform/iterator/subscript.pass.cpp FAIL +std/ranges/range.utility/view.interface/view.interface.pass.cpp FAIL + +# tests invalid range +std/utilities/memory/specialized.algorithms/uninitialized.copy/ranges_uninitialized_copy.pass.cpp FAIL +std/utilities/memory/specialized.algorithms/uninitialized.move/ranges_uninitialized_move.pass.cpp FAIL + +# Narrowing conversion +std/utilities/memory/specialized.algorithms/uninitialized.copy/ranges_uninitialized_copy_n.pass.cpp:0 FAIL +std/utilities/memory/specialized.algorithms/uninitialized.move/ranges_uninitialized_move_n.pass.cpp:0 FAIL + +# test defines std::_Bit_cast, which we already have +std/utilities/charconv/charconv.msvc/test.pass.cpp FAIL + +# libc++ doesn't yet implement LWG-3533 +std/ranges/range.adaptors/range.transform/end.pass.cpp FAIL +std/ranges/range.adaptors/range.transform/iterator/base.pass.cpp FAIL + +# MaybePOCCAAllocator doesn't meet the allocator requirements +std/containers/sequences/vector/vector.cons/assign_copy.pass.cpp FAIL + +# Mismatching allocator value_type +std/containers/sequences/vector.bool/get_allocator.pass.cpp FAIL + +# Test annotated "XFAIL: msvc" should be "XFAIL: msvc && stdlib=libc++" +std/language.support/support.dynamic/alloc.errors/set.new.handler/get_new_handler.pass.cpp SKIPPED +std/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/copy_move.pass.cpp SKIPPED + +# compares iterators from distinct transform_views +std/ranges/range.adaptors/range.transform/iterator/plus_minus.pass.cpp FAIL + +# MoveOnlyForwardIterator (a misnomer) has mixed-type comparisons and conversions +std/ranges/range.utility/range.subrange/primitives.pass.cpp:0 FAIL + +# libc++ speculatively implements LWG-3645 +std/strings/basic.string/string.capacity/resize_and_overwrite.pass.cpp FAIL # *** LIKELY STL BUGS *** @@ -785,6 +930,21 @@ std/localization/locale.categories/category.ctype/locale.codecvt/locale.codecvt. # Likely STL bug in : "result type of conditional expression is ambiguous" std/utilities/time/time.duration/time.duration.alg/abs.pass.cpp FAIL +# Likely STL bug in : we check argument ids at compiletime in next_arg_id +std/utilities/format/format.formatter/format.parse.ctx/next_arg_id.pass.cpp FAIL + +# Likely STL bug in `bind_front`: we don't respect deletion of the target call operator +std/utilities/function.objects/func.bind_front/bind_front.pass.cpp FAIL + +# Likely STL bug in `join_view::_Iterator`: constexpr weirdness +std/ranges/range.adaptors/range.join.view/end.pass.cpp:1 FAIL +std/ranges/range.adaptors/range.join.view/iterator/decrement.pass.cpp:0 FAIL +std/ranges/range.adaptors/range.join.view/iterator/increment.pass.cpp:0 FAIL +std/ranges/range.adaptors/range.join.view/iterator/iter.swap.pass.cpp:0 FAIL +std/ranges/range.adaptors/range.join.view/iterator/star.pass.cpp:0 FAIL +std/ranges/range.adaptors/range.join.view/sentinel/ctor.parent.pass.cpp:1 FAIL +std/ranges/range.adaptors/range.join.view/sentinel/eq.pass.cpp:1 FAIL + # *** NOT YET ANALYZED *** # Not yet analyzed. Asserting about alloc_count. @@ -800,10 +960,15 @@ std/utilities/tuple/tuple.tuple/tuple.helper/tuple_size_incomplete.pass.cpp FAIL std/utilities/tuple/tuple.tuple/tuple.helper/tuple_size_structured_bindings.pass.cpp FAIL # Not yet analyzed. Possibly testing nonstandard deduction guides. +std/containers/associative/map/map.cons/deduct.pass.cpp FAIL std/containers/associative/map/map.cons/deduct_const.pass.cpp FAIL +std/containers/associative/multimap/multimap.cons/deduct.pass.cpp FAIL std/containers/associative/multimap/multimap.cons/deduct_const.pass.cpp FAIL +std/containers/container.adaptors/priority.queue/priqueue.cons/deduct.pass.cpp FAIL +std/containers/sequences/list/list.cons/deduct.pass.cpp FAIL +std/containers/unord/unord.map/unord.map.cnstr/deduct.pass.cpp FAIL std/containers/unord/unord.map/unord.map.cnstr/deduct_const.pass.cpp FAIL -std/containers/unord/unord.multimap/unord.multimap.cnstr/deduct.pass.cpp:0 FAIL +std/containers/unord/unord.multimap/unord.multimap.cnstr/deduct.pass.cpp FAIL std/containers/unord/unord.multimap/unord.multimap.cnstr/deduct_const.pass.cpp FAIL std/utilities/tuple/tuple.tuple/tuple.cnstr/deduct.pass.cpp:0 FAIL @@ -817,16 +982,16 @@ std/re/re.const/re.matchflag/match_prev_avail.pass.cpp FAIL std/input.output/filesystems/class.path/path.member/path.charconv.pass.cpp FAIL # Not yet analyzed. Probably ADL shenanigans. +std/algorithms/robust_against_adl.compile.pass.cpp FAIL +std/strings/basic.string/string.modifiers/robust_against_adl.pass.cpp FAIL std/thread/thread.threads/thread.thread.class/thread.thread.constr/robust_against_adl.pass.cpp FAIL std/utilities/function.objects/func.wrap/func.wrap.func/robust_against_adl.pass.cpp FAIL std/utilities/function.objects/refwrap/refwrap.invoke/robust_against_adl.pass.cpp FAIL std/utilities/variant/variant.visit/robust_against_adl.pass.cpp FAIL -# Not yet analyzed. Probably MSVC bug. +# Not yet analyzed. Possibly C1XX constexpr bug. std/utilities/function.objects/func.invoke/invoke_constexpr.pass.cpp:0 FAIL - -# Not yet analyzed. Probably name mangling bug. -std/utilities/function.objects/func.wrap/func.wrap.func/noncopyable_return_type.pass.cpp FAIL +std/ranges/range.adaptors/range.join.view/iterator/increment.pass.cpp:0 FAIL # Not yet analyzed. Failing for "[a[.ch.]z]". std/re/re.alg/re.alg.match/awk.locale.pass.cpp FAIL @@ -851,30 +1016,19 @@ std/utilities/memory/allocator.traits/allocator.traits.members/destroy.pass.cpp # Not yet analyzed. Error mentions allocator. std/utilities/memory/specialized.algorithms/specialized.construct/construct_at.pass.cpp FAIL +# Not yet analyzed. Looks like deduction guide SFINAE failure. +std/containers/sequences/deque/deque.cons/deduct.pass.cpp FAIL +std/containers/sequences/forwardlist/forwardlist.cons/deduct.pass.cpp FAIL +std/containers/sequences/vector/vector.cons/deduct.pass.cpp FAIL + +# Not yet analyzed. Seems to force a sign conversion error? +std/iterators/iterator.primitives/iterator.operations/advance.pass.cpp FAIL + +# Not yet analyzed. Maybe Clang over-eagerly instantiating noexcept-specifier? +std/ranges/range.access/empty.pass.cpp:1 FAIL +std/ranges/range.access/size.pass.cpp:1 FAIL +std/ranges/range.access/ssize.pass.cpp:1 FAIL +std/utilities/memory/unique.ptr/iterator_concept_conformance.compile.pass.cpp:1 FAIL # *** XFAILs WHICH PASS *** -# Not yet implemented in libcxx and marked as "XFAIL: libc++" -std/strings/c.strings/cuchar.pass.cpp PASS -std/utilities/function.objects/func.search/func.search.bm/default.pass.cpp PASS -std/utilities/function.objects/func.search/func.search.bm/hash.pass.cpp PASS -std/utilities/function.objects/func.search/func.search.bm/hash.pred.pass.cpp PASS -std/utilities/function.objects/func.search/func.search.bm/pred.pass.cpp PASS -std/utilities/function.objects/func.search/func.search.bmh/default.pass.cpp PASS -std/utilities/function.objects/func.search/func.search.bmh/hash.pass.cpp PASS -std/utilities/function.objects/func.search/func.search.bmh/hash.pred.pass.cpp PASS -std/utilities/function.objects/func.search/func.search.bmh/pred.pass.cpp PASS - -# Not yet implemented in libcxx and marked as "XFAIL: *" -std/utilities/time/time.cal/time.cal.day/time.cal.day.nonmembers/streaming.pass.cpp SKIPPED -std/utilities/time/time.cal/time.cal.md/time.cal.md.nonmembers/streaming.pass.cpp SKIPPED -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 +# Nothing here! :-) diff --git a/tests/libcxx/magic_comments.txt b/tests/libcxx/magic_comments.txt index b68a41e838..6b488fdfa3 100644 --- a/tests/libcxx/magic_comments.txt +++ b/tests/libcxx/magic_comments.txt @@ -1,6 +1,9 @@ // REQUIRES: c++03 +// REQUIRES: c++03 || c++11 // REQUIRES: c++03 || c++11 || c++14 // REQUIRES: c++03 || c++11 || c++14 || c++17 // REQUIRES: c++11 // REQUIRES: c++11 || c++14 +// REQUIRES: c++11 || c++14 || c++17 || c++20 +// REQUIRES: stdlib=libc++ // UNSUPPORTED: c++14, c++17, c++2a diff --git a/tests/libcxx/skipped_tests.txt b/tests/libcxx/skipped_tests.txt index 352079a4e4..38b25c0707 100644 --- a/tests/libcxx/skipped_tests.txt +++ b/tests/libcxx/skipped_tests.txt @@ -15,25 +15,17 @@ input.output\iostreams.base\ios.base\ios.base.storage\pword.pass.cpp utilities\smartptr\unique.ptr\unique.ptr.class\unique.ptr.ctor\null.pass.cpp # allocator. +iterators\iterator.requirements\iterator.cust\iterator.cust.move\iter_rvalue_reference_t.pass.cpp utilities\memory\default.allocator\allocator.ctor.pass.cpp -# path::value_type is char assumptions -input.output\file.streams\fstreams\filebuf.members\open_path.pass.cpp -input.output\file.streams\fstreams\fstream.cons\path.pass.cpp -input.output\file.streams\fstreams\fstream.members\open_path.pass.cpp -input.output\file.streams\fstreams\ofstream.cons\path.pass.cpp -input.output\file.streams\fstreams\ofstream.members\open_path.pass.cpp - # This test is passing non-BidirectionalIterators to std::prev. # LWG-3197 "std::prev should not require BidirectionalIterator" (New) iterators\iterator.primitives\iterator.operations\prev.pass.cpp # Itanium ABI assumptions that current_exception and rethrow_exception don't copy the exception object -# rethrow_if_nested.pass.cpp can crash. -language.support\support.exception\propagation\current_exception.pass.cpp +language.support\support.exception\except.nested\rethrow_if_nested.pass.cpp language.support\support.exception\propagation\make_exception_ptr.pass.cpp language.support\support.exception\propagation\rethrow_exception.pass.cpp -language.support\support.exception\except.nested\rethrow_if_nested.pass.cpp # Testing nonstandard behavior utilities\template.bitset\bitset.cons\string_ctor.pass.cpp @@ -42,8 +34,7 @@ utilities\template.bitset\bitset.cons\string_ctor.pass.cpp thread\futures\futures.task\futures.task.members\dtor.pass.cpp thread\futures\futures.unique_future\wait_until.pass.cpp -# libcxx is incorrect on what the type passed to allocator construct should be -# See https://reviews.llvm.org/D61364 +# libcxx is incorrect on what the type passed to allocator::construct should be (https://reviews.llvm.org/D61364) containers\associative\map\map.modifiers\insert_and_emplace_allocator_requirements.pass.cpp containers\associative\set\insert_and_emplace_allocator_requirements.pass.cpp containers\unord\unord.map\unord.map.modifiers\insert_and_emplace_allocator_requirements.pass.cpp @@ -61,18 +52,36 @@ language.support\support.limits\support.limits.general\string_view.version.pass. # libc++ doesn't yet implement P2231R1, so it expects an old value for `__cpp_lib_optional` language.support\support.limits\support.limits.general\optional.version.pass.cpp -# test emits warning C4310: cast truncates constant value -numerics\bit\bitops.rot\rotl.pass.cpp - # libc++ doesn't yet implement P1754R1 or P1964R2, so it expects an old value for `__cpp_lib_concepts` language.support\support.limits\support.limits.general\concepts.version.pass.cpp -# Bogus test believes that optional cannot be a literal type -utilities\optional\optional.object\optional.object.dtor\dtor.pass.cpp - # Bogus test believes that copyability of array must be the same as array containers\sequences\array\array.cons\implicit_copy.pass.cpp +# string_view and array iterators are not portably pointers (https://reviews.llvm.org/D117368) +iterators\iterator.primitives\iterator.traits\cxx20_iterator_traits.compile.pass.cpp +iterators\iterator.requirements\iterator.cust\iterator.cust.move\iter_move.pass.cpp +strings\string.view\string.view.cons\from_iterator_sentinel.pass.cpp +strings\string.view\string.view.deduct\iterator_sentinel.pass.cpp +utilities\format\format.formatter\format.parse.ctx\advance_to.pass.cpp +utilities\format\format.formatter\format.parse.ctx\begin.pass.cpp +utilities\format\format.formatter\format.parse.ctx\ctor.pass.cpp +utilities\format\format.formatter\format.parse.ctx\end.pass.cpp + +# libc++ doesn't correctly constrain the iterator_traits specialization for common_iterator (https://reviews.llvm.org/D117449) +iterators\predef.iterators\iterators.common\iterator_traits.compile.pass.cpp + +# libc++ hasn't updated move_iterator for P0896R4 +iterators\predef.iterators\move.iterators\move.iter.ops\move.iter.op=\move_iterator.pass.cpp +iterators\predef.iterators\move.iterators\move.iterator\iterator_concept_conformance.compile.pass.cpp +iterators\predef.iterators\reverse.iterators\iterator_concept_conformance.compile.pass.cpp +iterators\predef.iterators\reverse.iterators\reverse.iter.cmp\three-way.pass.cpp +iterators\predef.iterators\reverse.iterators\reverse.iter.cons\assign.pass.cpp + +# optional's comparisons aren't portably constrained (https://reviews.llvm.org/D116884) +concepts\concepts.compare\concepts.totallyordered\totally_ordered.pass.cpp +concepts\concepts.compare\concept.equalitycomparable\equality_comparable.compile.pass.cpp + # *** INTERACTIONS WITH CONTEST / C1XX THAT UPSTREAM LIKELY WON'T FIX *** # Tracked by VSO-593630 " Enable libcxx filesystem tests" @@ -105,7 +114,6 @@ input.output\filesystems\class.path\path.itr\iterator.pass.cpp input.output\filesystems\class.path\path.member\path.append.pass.cpp input.output\filesystems\class.path\path.member\path.compare.pass.cpp input.output\filesystems\class.path\path.member\path.concat.pass.cpp -input.output\filesystems\class.path\path.member\path.assign\braced_init.pass.cpp input.output\filesystems\class.path\path.member\path.assign\copy.pass.cpp input.output\filesystems\class.path\path.member\path.assign\move.pass.cpp input.output\filesystems\class.path\path.member\path.assign\source.pass.cpp @@ -127,7 +135,6 @@ input.output\filesystems\class.path\path.member\path.native.obs\c_str.pass.cpp input.output\filesystems\class.path\path.member\path.native.obs\named_overloads.pass.cpp input.output\filesystems\class.path\path.member\path.native.obs\native.pass.cpp input.output\filesystems\class.path\path.member\path.native.obs\operator_string.pass.cpp -input.output\filesystems\class.path\path.member\path.native.obs\string_alloc.pass.cpp input.output\filesystems\class.path\path.nonmember\append_op.pass.cpp input.output\filesystems\class.path\path.nonmember\path.factory.pass.cpp input.output\filesystems\class.path\path.nonmember\path.io.pass.cpp @@ -194,14 +201,23 @@ input.output\filesystems\fs.op.funcs\fs.op.temp_dir_path\temp_directory_path.pas input.output\filesystems\fs.op.funcs\fs.op.weakly_canonical\weakly_canonical.pass.cpp # generate_feature_test_macro_components.py needs to learn about C1XX -language.support\support.limits\support.limits.general\type_traits.version.pass.cpp language.support\support.limits\support.limits.general\version.version.pass.cpp # Contest does not understand .sh tests, which must be run specially +atomics\atomics.general\replace_failure_order_codegen.sh.cpp +containers\associative\map\PR28469_undefined_behavior_segfault.sh.cpp +input.output\iostream.objects\narrow.stream.objects\cerr.sh.cpp input.output\iostream.objects\narrow.stream.objects\cin.sh.cpp +input.output\iostream.objects\narrow.stream.objects\clog.sh.cpp +input.output\iostream.objects\narrow.stream.objects\cout.sh.cpp +input.output\iostream.objects\wide.stream.objects\wcerr.sh.cpp input.output\iostream.objects\wide.stream.objects\wcin.sh.cpp +input.output\iostream.objects\wide.stream.objects\wclog.sh.cpp +input.output\iostream.objects\wide.stream.objects\wcout.sh.cpp namespace\addressable_functions.sh.cpp +strings\basic.string\string.capacity\shrink_to_fit.explicit_instantiation.sh.cpp thread\thread.condition\thread.condition.condvarany\wait_terminates.sh.cpp +utilities\format\format.arguments\format.arg.store\make_format_args.sh.cpp # These tests set an allocator with a max_size() too small to default construct an unordered container # (due to our minimum bucket size). @@ -212,8 +228,13 @@ containers\unord\unord.set\max_size.pass.cpp # Extreme compiler memory consumption. utilities\tuple\tuple.tuple\tuple.apply\apply_large_arity.pass.cpp +utilities\tuple\tuple.tuple\tuple.cnstr\recursion_depth.pass.cpp # .verify.cpp tests use clang-verify to validate warnings +atomics\atomics.types.generic\trivially_copyable.verify.cpp +atomics\atomics.types.operations\atomics.types.operations.req\copy.assign.ptr.volatile.verify.cpp +atomics\atomics.types.operations\atomics.types.operations.req\copy.assign.volatile.verify.cpp +concepts\concepts.lang\concept.default.init\default_initializable.verify.cpp containers\associative\map\map.access\empty.verify.cpp containers\associative\multimap\empty.verify.cpp containers\associative\multiset\empty.verify.cpp @@ -221,17 +242,22 @@ containers\associative\set\empty.verify.cpp containers\container.adaptors\priority.queue\priqueue.members\empty.verify.cpp containers\container.adaptors\queue\queue.defn\empty.verify.cpp containers\container.adaptors\stack\stack.defn\empty.verify.cpp +containers\container.node\node_handle.nodiscard.verify.cpp containers\sequences\array\empty.verify.cpp containers\sequences\deque\deque.capacity\empty.verify.cpp containers\sequences\forwardlist\empty.verify.cpp containers\sequences\list\list.capacity\empty.verify.cpp -containers\sequences\vector.bool\empty.verify.cpp containers\sequences\vector\vector.capacity\empty.verify.cpp containers\sequences\vector\vector.cons\copy.move_only.verify.cpp +containers\sequences\vector.bool\empty.verify.cpp containers\unord\unord.map\empty.verify.cpp containers\unord\unord.multimap\empty.verify.cpp containers\unord\unord.multiset\empty.verify.cpp containers\unord\unord.set\empty.verify.cpp +containers\views\span.cons\iterator_len.verify.cpp +containers\views\span.cons\iterator_sentinel.verify.cpp +containers\views\span.obs\empty.nodiscard.verify.cpp +depr\depr.atomics\depr.atomics.nonmembers\atomic_init.depr_in_cxx20.verify.cpp depr\depr.lib.binders\depr.lib.bind.1st\bind1st.depr_in_cxx11.verify.cpp depr\depr.lib.binders\depr.lib.bind.2nd\bind2nd.depr_in_cxx11.verify.cpp depr\depr.lib.binders\depr.lib.binder.1st\binder1st.depr_in_cxx11.verify.cpp @@ -244,48 +270,93 @@ input.output\iostream.format\quoted.manip\quoted_traits.verify.cpp iterators\iterator.container\empty.array.verify.cpp iterators\iterator.container\empty.container.verify.cpp iterators\iterator.container\empty.initializer_list.verify.cpp +iterators\iterator.primitives\iterator.basic\deprecated.verify.cpp +iterators\iterator.primitives\range.iter.ops\range.iter.ops.advance\constraints.verify.cpp +iterators\iterator.requirements\iterator.cust\iterator.cust.move\iter_move.nodiscard.verify.cpp +iterators\predef.iterators\move.iterators\move.iter.ops\move.iter.op.const\ctor.convert.LWG3435.verify.cpp +iterators\predef.iterators\move.iterators\move.iter.ops\move.iter.op.const\ctor.iter.explicit.verify.cpp +iterators\predef.iterators\move.iterators\move.iter.ops\move.iter.op=\assign.LWG3435.verify.cpp +iterators\predef.iterators\reverse.iterators\reverse.iter.cons\assign.LWG3435.verify.cpp +iterators\predef.iterators\reverse.iterators\reverse.iter.cons\ctor.iter.explicit.verify.cpp +iterators\predef.iterators\reverse.iterators\reverse.iter.cons\ctor.reverse_iterator.LWG3435.verify.cpp +language.support\cmp\cmp.alg\strong_order_long_double.verify.cpp language.support\cmp\cmp.categories.pre\zero_type.verify.cpp -language.support\support.dynamic\new.delete\new.delete.array\new_size_align_nothrow.verify.cpp +language.support\support.dynamic\new.delete\new.delete.array\new_size.verify.cpp language.support\support.dynamic\new.delete\new.delete.array\new_size_align.verify.cpp +language.support\support.dynamic\new.delete\new.delete.array\new_size_align_nothrow.verify.cpp language.support\support.dynamic\new.delete\new.delete.array\new_size_nothrow.verify.cpp -language.support\support.dynamic\new.delete\new.delete.array\new_size.verify.cpp language.support\support.dynamic\new.delete\new.delete.placement\new_array_ptr.verify.cpp language.support\support.dynamic\new.delete\new.delete.placement\new_ptr.verify.cpp -language.support\support.dynamic\new.delete\new.delete.single\new_size_align_nothrow.verify.cpp +language.support\support.dynamic\new.delete\new.delete.single\new_size.verify.cpp language.support\support.dynamic\new.delete\new.delete.single\new_size_align.verify.cpp +language.support\support.dynamic\new.delete\new.delete.single\new_size_align_nothrow.verify.cpp language.support\support.dynamic\new.delete\new.delete.single\new_size_nothrow.verify.cpp -language.support\support.dynamic\new.delete\new.delete.single\new_size.verify.cpp language.support\support.dynamic\ptr.launder\launder.nodiscard.verify.cpp +localization\locale.categories\category.ctype\locale.codecvt\codecvt_char16_t_char.depr_in_cxx20.verify.cpp +localization\locale.categories\category.ctype\locale.codecvt\codecvt_char32_t_char.depr_in_cxx20.verify.cpp +localization\locale.categories\category.ctype\locale.codecvt.byname\codecvt_byname_char16_t_char.depr_in_cxx20.verify.cpp +localization\locale.categories\category.ctype\locale.codecvt.byname\codecvt_byname_char32_t_char.depr_in_cxx20.verify.cpp +numerics\c.math\abs.verify.cpp numerics\numbers\illformed.verify.cpp +ranges\range.adaptors\range.join.view\ctad.verify.cpp re\re.results\re.results.size\empty.verify.cpp strings\basic.string\string.capacity\empty.verify.cpp +strings\basic.string\string.capacity\reserve.deprecated_in_cxx20.verify.cpp +strings\basic.string.literals\literal.verify.cpp strings\string.view\string.view.capacity\empty.verify.cpp +strings\string.view\string_view.literals\literal.verify.cpp thread\futures\futures.async\async.verify.cpp thread\futures\futures.promise\copy_assign.verify.cpp thread\futures\futures.promise\copy_ctor.verify.cpp thread\futures\futures.unique_future\copy_assign.verify.cpp thread\futures\futures.unique_future\copy_ctor.verify.cpp -utilities\allocator.adaptor\allocator.adaptor.members\allocate_size_hint.verify.cpp utilities\allocator.adaptor\allocator.adaptor.members\allocate_size.verify.cpp +utilities\allocator.adaptor\allocator.adaptor.members\allocate_size_hint.verify.cpp +utilities\any\any.nonmembers\any.cast\const_correctness.verify.cpp +utilities\any\any.nonmembers\any.cast\not_copy_constructible.verify.cpp +utilities\format\format.formatter\format.parse.ctx\check_arg_id.verify.cpp +utilities\function.objects\func.bind_front\bind_front.verify.cpp +utilities\function.objects\func.wrap\func.wrap.func\func.wrap.func.con\alloc.verify.cpp utilities\function.objects\func.wrap\func.wrap.func\func.wrap.func.con\alloc_F.verify.cpp utilities\function.objects\func.wrap\func.wrap.func\func.wrap.func.con\alloc_function.verify.cpp utilities\function.objects\func.wrap\func.wrap.func\func.wrap.func.con\alloc_nullptr.verify.cpp utilities\function.objects\func.wrap\func.wrap.func\func.wrap.func.con\alloc_rfunction.verify.cpp -utilities\function.objects\func.wrap\func.wrap.func\func.wrap.func.con\alloc.verify.cpp utilities\function.objects\negators\binary_negate.depr_in_cxx17.verify.cpp utilities\function.objects\negators\not1.depr_in_cxx17.verify.cpp utilities\function.objects\negators\not2.depr_in_cxx17.verify.cpp utilities\function.objects\negators\unary_negate.depr_in_cxx17.verify.cpp utilities\memory\allocator.traits\allocator.traits.members\allocate.verify.cpp -utilities\memory\default.allocator\allocator_types.deprecated_in_cxx17.verify.cpp -utilities\memory\default.allocator\allocator_types.removed_in_cxx20.verify.cpp -utilities\memory\default.allocator\allocator_void.deprecated_in_cxx17.verify.cpp utilities\memory\default.allocator\allocator.members\allocate.constexpr.size.verify.cpp utilities\memory\default.allocator\allocator.members\allocate.verify.cpp +utilities\memory\default.allocator\allocator_types.deprecated_in_cxx17.verify.cpp +utilities\memory\default.allocator\allocator_types.removed_in_cxx20.verify.cpp +utilities\memory\pointer.conversion\to_address_on_funcptr.verify.cpp +utilities\memory\pointer.conversion\to_address_on_function.verify.cpp +utilities\memory\storage.iterator\deprecated.verify.cpp +utilities\meta\meta.trans\meta.trans.other\result_of.deprecated.verify.cpp +utilities\smartptr\unique.ptr\unique.ptr.class\unique.ptr.observers\dereference.verify.cpp +utilities\smartptr\unique.ptr\unique.ptr.class\unique.ptr.observers\op_arrow.verify.cpp +utilities\tuple\tuple.tuple\tuple.cnstr\default.lazy.verify.cpp +utilities\tuple\tuple.tuple\tuple.rel\size_incompatible_comparison.verify.cpp +utilities\utility\utility.underlying\to_underlying.verify.cpp + +# Deprecation is a mess. We disable all deprecations in msvc_stdlib_force_include.hpp to allow libc++ tests for +# deprecated features to pass, which breaks when libc++ deprecates the feature and adds two tests that (1) pass +# with deprecation suppressed, and (2) fail without deprecation suppression. I think we should instead translate +# libc++ un-deprecation macros to STL un-deprecation macros in the force-include header, and just skip tests when +# we deprecate before they do. +utilities\meta\meta.unary\meta.unary.prop\is_literal_type.deprecated.fail.cpp # *** MISSING STL FEATURES *** -# Nothing here! :-) +# P2321R2 zip +language.support\support.limits\support.limits.general\tuple.version.pass.cpp +language.support\support.limits\support.limits.general\utility.version.pass.cpp +utilities\meta\meta.trans\meta.trans.other\common_reference.compile.pass.cpp +utilities\meta\meta.trans\meta.trans.other\common_type.pass.cpp + +# P1328R1 constexpr type_info::operator==() +language.support\support.limits\support.limits.general\typeinfo.version.pass.cpp # *** MISSING COMPILER FEATURES *** @@ -305,24 +376,98 @@ thread\futures\futures.promise\set_value_at_thread_exit_const.pass.cpp thread\futures\futures.promise\set_value_at_thread_exit_void.pass.cpp thread\futures\futures.task\futures.task.members\make_ready_at_thread_exit.pass.cpp +# LWG-3633 "Atomics are copy constructible and copy assignable from volatile atomics" (Open) +atomics\atomics.types.generic\copy_semantics_traits.pass.cpp + # *** C1XX COMPILER BUGS *** # DevCom-409222 "Constructing rvalue reference from non-reference-related lvalue reference" utilities\meta\meta.unary\meta.unary.prop\is_constructible.pass.cpp # DevCom-876860 "conditional operator errors" blocks readable. -containers\views\span.cons\ptr_len.pass.cpp -containers\views\span.cons\ptr_ptr.pass.cpp +concepts\concepts.lang\concept.common\common_with.compile.pass.cpp +concepts\concepts.lang\concept.commonref\common_reference.compile.pass.cpp +containers\views\span.cons\iterator_sentinel.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.bidir\bidirectional_iterator.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.random.access\contiguous_iterator.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.readable\indirectly_readable.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.forward\forward_iterator.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.input\input_iterator.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.random.access\random_access_iterator.compile.pass.cpp # VSO-1271673 "static analyzer doesn't know about short-circuiting" algorithms\alg.sorting\alg.sort\partial.sort\partial_sort.pass.cpp algorithms\alg.sorting\alg.sort\partial.sort\partial_sort_comp.pass.cpp +# DevCom-1559808: (structured bindings for `subrange` in a constant expression) +ranges\range.utility\range.subrange\structured_bindings.pass.cpp + +# DevCom-1626139 "compile-time NaN comparison" +iterators\predef.iterators\reverse.iterators\reverse.iter.cmp\three-way.pass.cpp +library\description\conventions\expos.only.func\synth_three_way.pass.cpp +utilities\function.objects\comparisons\compare_three_way.pass.cpp +utilities\tuple\tuple.tuple\tuple.rel\three_way.pass.cpp +utilities\utility\pairs\pairs.spec\three_way_comparison.pass.cpp + +# DevCom-1626727: bogus "failure was caused by a conversion from void* to a pointer-to-object type" for conversion to void +algorithms\robust_re_difference_type.compile.pass.cpp + +# DevCom-1627396: C1XX's __is_convertible_to intrinsic mis-handles volatile array lvalues +concepts\concepts.lang\concept.swappable\swappable_with.compile.pass.cpp + +# DevCom-1628714: C1XX refuses nullptr_t == reference-to-function in a requires expression +concepts\concepts.compare\concept.equalitycomparable\equality_comparable_with.compile.pass.cpp + +# DevCom-1629961: ICE testing if function lvalues are comparable with the spaceship operator +language.support\cmp\cmp.concept\three_way_comparable.compile.pass.cpp + +# DevCom-1638496: C1XX doesn't properly reject int <=> unsigned +language.support\cmp\cmp.concept\three_way_comparable_with.compile.pass.cpp +language.support\cmp\cmp.result\compare_three_way_result.compile.pass.cpp +utilities\tuple\tuple.tuple\tuple.rel\three_way.pass.cpp + +# DevCom-1638563: icky static analysis false positive +language.support\support.coroutines\end.to.end\go.pass.cpp + # *** CLANG COMPILER BUGS *** # LLVM-46207 Clang's tgmath.h interferes with the UCRT's tgmath.h depr\depr.c.headers\tgmath_h.pass.cpp +# Clang doesn't implement the common coroutine ABI until LLVM 14 +language.support\support.coroutines\coroutine.handle\coroutine.handle.capacity\operator_bool.pass.cpp +language.support\support.coroutines\coroutine.handle\coroutine.handle.compare\equal_comp.pass.cpp +language.support\support.coroutines\coroutine.handle\coroutine.handle.compare\less_comp.pass.cpp +language.support\support.coroutines\coroutine.handle\coroutine.handle.completion\done.pass.cpp +language.support\support.coroutines\coroutine.handle\coroutine.handle.con\assign.pass.cpp +language.support\support.coroutines\coroutine.handle\coroutine.handle.con\construct.pass.cpp +language.support\support.coroutines\coroutine.handle\coroutine.handle.export\address.pass.cpp +language.support\support.coroutines\coroutine.handle\coroutine.handle.export\from_address.pass.cpp +language.support\support.coroutines\coroutine.handle\coroutine.handle.hash\hash.pass.cpp +language.support\support.coroutines\coroutine.handle\coroutine.handle.noop\noop_coroutine.pass.cpp +language.support\support.coroutines\coroutine.handle\coroutine.handle.prom\promise.pass.cpp +language.support\support.coroutines\coroutine.handle\coroutine.handle.resumption\destroy.pass.cpp +language.support\support.coroutines\coroutine.handle\coroutine.handle.resumption\resume.pass.cpp +language.support\support.coroutines\coroutine.handle\void_handle.pass.cpp +language.support\support.coroutines\coroutine.traits\promise_type.pass.cpp +language.support\support.coroutines\coroutine.trivial.awaitables\suspend_always.pass.cpp +language.support\support.coroutines\coroutine.trivial.awaitables\suspend_never.pass.cpp +language.support\support.coroutines\end.to.end\await_result.pass.cpp +language.support\support.coroutines\end.to.end\bool_await_suspend.pass.cpp +language.support\support.coroutines\end.to.end\expected.pass.cpp +language.support\support.coroutines\end.to.end\fullexpr-dtor.pass.cpp +language.support\support.coroutines\end.to.end\generator.pass.cpp +language.support\support.coroutines\end.to.end\go.pass.cpp +language.support\support.coroutines\end.to.end\multishot_func.pass.cpp +language.support\support.coroutines\end.to.end\oneshot_func.pass.cpp +language.support\support.limits\support.limits.general\coroutine.version.pass.cpp + +# LLVM-52643 Requires-expression too eagerly completes associated type +ranges\range.access\begin.pass.cpp +ranges\range.access\data.pass.cpp +ranges\range.access\end.pass.cpp +ranges\range.req\range.range\range.compile.pass.cpp + # *** CLANG ISSUES, NOT YET ANALYZED *** # Clang doesn't enable sized deallocation by default. Should we add -fsized-deallocation or do something else? @@ -412,14 +557,20 @@ utilities\meta\meta.trans\meta.trans.other\aligned_storage.pass.cpp depr\depr.c.headers\math_h.pass.cpp numerics\c.math\cmath.pass.cpp -# GH-1596: : unqualified calls to _Adl_verify_range incorrectly cause instantiation -algorithms\robust_against_adl.pass.cpp +# GH-2358: : path's comparison operators are IF-NDR +input.output\filesystems\class.path\range_concept_conformance.compile.pass.cpp + +# GH-1374: Spaceship CPO wording in [cmp.alg] needs an overhaul +# (Technically an STL bug until I fix the wording in the working draft to agree.) +language.support\cmp\cmp.alg\partial_order.pass.cpp +language.support\cmp\cmp.alg\strong_order.pass.cpp +language.support\cmp\cmp.alg\weak_order.pass.cpp # *** CRT BUGS *** # We're permanently missing aligned_alloc(). -depr\depr.c.headers\stdlib_h.pass.cpp -language.support\support.runtime\cstdlib.pass.cpp +depr\depr.c.headers\stdlib_h.aligned_alloc.compile.pass.cpp +language.support\support.runtime\cstdlib.aligned_alloc.compile.pass.cpp # OS-11107628 "_Exit allows cleanup in other DLLs" thread\thread.threads\thread.thread.class\thread.thread.assign\move2.pass.cpp @@ -445,6 +596,7 @@ utilities\smartptr\unique.ptr\unique.ptr.class\unique.ptr.asgn\move.pass.cpp language.support\support.limits\support.limits.general\string.version.pass.cpp # Not yet analyzed, likely bogus tests. Appears to be timing assumptions. +atomics\atomics.types.operations\atomics.types.operations.wait\atomic_notify_all.pass.cpp thread\futures\futures.async\async.pass.cpp thread\futures\futures.shared_future\get.pass.cpp thread\futures\futures.shared_future\wait.pass.cpp @@ -523,24 +675,11 @@ input.output\iostream.format\input.streams\istream.unformatted\get_pointer_size. # Sensitive to implementation details. Assertion failed: test_alloc_base::count == expected_num_allocs containers\container.requirements\container.requirements.general\allocator_move.pass.cpp -# Tests std::weak_equality/strong_equality which were removed by P1959R0 -language.support\cmp\cmp.common\common_comparison_category.pass.cpp -language.support\cmp\cmp.partialord\partialord.pass.cpp -language.support\cmp\cmp.strongeq\cmp.strongeq.pass.cpp -language.support\cmp\cmp.strongord\strongord.pass.cpp -language.support\cmp\cmp.weakeq\cmp.weakeq.pass.cpp -language.support\cmp\cmp.weakord\weakord.pass.cpp - # Comment: "Test C99 compound literal." # Code: `(int[]){3, 4}` # error C4576: a parenthesized type followed by an initializer list is a non-standard explicit type conversion syntax containers\sequences\array\array.creation\to_array.pass.cpp -# Tests that need to learn that iterators have non-void difference types in C++20 -iterators\predef.iterators\insert.iterators\back.insert.iterator\types.pass.cpp -iterators\predef.iterators\insert.iterators\front.insert.iterator\types.pass.cpp -iterators\predef.iterators\insert.iterators\insert.iterator\types.pass.cpp - # Tests emit warning C4244: 'argument': conversion from 'T' to 'const std::complex::_Ty', possible loss of data numerics\complex.number\cmplx.over\conj.pass.cpp numerics\complex.number\cmplx.over\pow.pass.cpp @@ -563,38 +702,18 @@ numerics\rand\rand.dis\rand.dist.samp\rand.dist.samp.plinear\eval.pass.cpp # Assertion failed: (std::lerp(T(2.3), T(2.3), inf) == T(2.3)) # Asserts `(std::lerp(T(2.3), T(2.3), inf) == T(2.3))` and `std::isnan(std::lerp(T( 0), T( 0), inf))` # They shouldn't behave differently. Both of them should probably return NaN. -numerics\c.math\c.math.lerp\c.math.lerp.pass.cpp +numerics\c.math\lerp.pass.cpp # --month{14} should be 1, not 13 as the test expects utilities\time\time.cal\time.cal.month\time.cal.month.members\decrement.pass.cpp -# test is broken due to month_weekday not being default constructible -utilities\time\time.cal\time.cal.mwd\time.cal.mwd.members\month.pass.cpp - # conversion from '__int64' to 'long', possible loss of data utilities\time\time.hms\time.hms.members\seconds.pass.cpp utilities\time\time.hms\time.hms.members\subseconds.pass.cpp -# Code: `for (int i = 1000; i < 20; ++i)` -# warning C6294: Ill-defined for-loop: initial condition does not satisfy test. Loop body not executed. -utilities\time\time.cal\time.cal.month\time.cal.month.nonmembers\comparisons.pass.cpp -utilities\time\time.cal\time.cal.ym\time.cal.ym.nonmembers\comparisons.pass.cpp -utilities\time\time.cal\time.cal.ymd\time.cal.ymd.nonmembers\comparisons.pass.cpp -utilities\time\time.cal\time.cal.ymdlast\time.cal.ymdlast.nonmembers\comparisons.pass.cpp -utilities\time\time.cal\time.cal.ymwd\time.cal.ymwd.nonmembers\comparisons.pass.cpp -utilities\time\time.cal\time.cal.ymwdlast\time.cal.ymwdlast.nonmembers\comparisons.pass.cpp - -# Tests are manually declaring printf, which appears to be unused. -# warning C28301: No annotations for first declaration of 'printf'. -utilities\time\time.cal\time.cal.weekday\time.cal.weekday.nonmembers\minus.pass.cpp -utilities\time\time.cal\time.cal.year\time.cal.year.nonmembers\minus.pass.cpp - # Bogus test passes a class type as the second argument to std::advance iterators\iterator.primitives\iterator.operations\robust_against_adl.pass.cpp -# Non-Standard test should be moved from libcxx/test/std to libcxx/test/libcxx -utilities\memory\util.smartptr\util.smartptr.shared\libcxx.control_block_layout.pass.cpp - # Non-Standard assumption that std::filesystem::file_time_type::duration::period is std::nano input.output\filesystems\fs.filesystem.synopsis\file_time_type_resolution.compile.pass.cpp @@ -620,12 +739,6 @@ strings\string.conversions\stoll.pass.cpp strings\string.conversions\stoul.pass.cpp strings\string.conversions\stoull.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 @@ -638,22 +751,90 @@ language.support\support.limits\support.limits.general\iterator.version.pass.cpp # Test expects __cpp_lib_chrono to have the old value 201611L for P0505R0; we define the C++20 value 201907L for P1466R3. language.support\support.limits\support.limits.general\chrono.version.pass.cpp -# Test expects __cpp_lib_format to have the old value 201907L for P0645R10; we define the C++20 value 202106L for P2216R3. -language.support\support.limits\support.limits.general\format.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 -# Test should be enabled after LLVM update -# updated test https://github.com/llvm/llvm-project/commit/0324b46cd873abc4fabe19f4bd468d10398ffd0d#diff-a9be5c3f8e18be99f40fb35f58960f400413a76252d86b53f80d76cb09cb53ef -# should work +# libc++ doesn't implement P2231R1 Add further constexpr support for optional/variant language.support\support.limits\support.limits.general\variant.version.pass.cpp -# libc++ doesn't implement P2186R2 Removing Garbage Collection Support -utilities\memory\util.dynamic.safety\get_pointer_safety.pass.cpp -utilities\memory\util.dynamic.safety\declare_no_pointers.pass.cpp -utilities\memory\util.dynamic.safety\declare_reachable.pass.cpp +# Tests non-portable behavior +utilities\format\format.formatter\format.context\format.context\advance_to.pass.cpp +utilities\format\format.formatter\format.context\format.context\arg.pass.cpp +utilities\format\format.formatter\format.context\format.context\ctor.pass.cpp +utilities\format\format.formatter\format.context\format.context\locale.pass.cpp +utilities\format\format.formatter\format.context\format.context\out.pass.cpp +utilities\format\format.formatter\format.context\format.formatter.spec\formatter.bool.pass.cpp +utilities\format\format.formatter\format.context\format.formatter.spec\formatter.c_string.pass.cpp +utilities\format\format.formatter\format.context\format.formatter.spec\formatter.char.pass.cpp +utilities\format\format.formatter\format.context\format.formatter.spec\formatter.const_char_array.pass.cpp +utilities\format\format.formatter\format.context\format.formatter.spec\formatter.signed_integral.pass.cpp +utilities\format\format.formatter\format.context\format.formatter.spec\formatter.string.pass.cpp +utilities\format\format.formatter\format.context\format.formatter.spec\formatter.unsigned_integral.pass.cpp + +# libc++ doesn't yet implement P2216R3 (test uses non-constant-expression format strings) +utilities\format\format.functions\format.pass.cpp +utilities\format\format.functions\format.locale.pass.cpp +utilities\format\format.functions\format_to.locale.pass.cpp +utilities\format\format.functions\format_to.pass.cpp +utilities\format\format.functions\format_to_n.pass.cpp +utilities\format\format.functions\format_to_n.locale.pass.cpp +utilities\format\format.functions\formatted_size.pass.cpp +utilities\format\format.functions\formatted_size.locale.pass.cpp +utilities\format\format.functions\locale-specific_form.pass.cpp + +# libc++ chose option A for [time.clock.file.members], and we chose option B. +utilities\time\time.clock\time.clock.file\to_from_sys.pass.cpp + +# libc++ is missing various Ranges DRs +language.support\support.limits\support.limits.general\ranges.version.pass.cpp + +# test compares singular and non-singular string iterators +strings\basic.string\string.iterators\iterators.pass.cpp + +# test compares iterators into distinct `array`s +ranges\range.adaptors\range.all\range.owning.view\begin_end.pass.cpp + +# libc++ allows some forbidden unique_ptr conversions +utilities\memory\util.smartptr\util.smartptr.shared\util.smartptr.shared.assign\unique_ptr_Y.pass.cpp +utilities\memory\util.smartptr\util.smartptr.shared\util.smartptr.shared.const\unique_ptr.pass.cpp + +# non-portable test of strengthened noexcept +ranges\range.adaptors\range.drop\ctor.default.pass.cpp +ranges\range.adaptors\range.transform\iterator\deref.pass.cpp +ranges\range.adaptors\range.transform\iterator\iter_move.pass.cpp +ranges\range.adaptors\range.transform\iterator\subscript.pass.cpp +ranges\range.utility\view.interface\view.interface.pass.cpp + +# tests invalid range +utilities\memory\specialized.algorithms\uninitialized.copy\ranges_uninitialized_copy.pass.cpp +utilities\memory\specialized.algorithms\uninitialized.move\ranges_uninitialized_move.pass.cpp + +# Narrowing conversion +utilities\memory\specialized.algorithms\uninitialized.copy\ranges_uninitialized_copy_n.pass.cpp +utilities\memory\specialized.algorithms\uninitialized.move\ranges_uninitialized_move_n.pass.cpp + +# test defines std::_Bit_cast, which we already have +utilities\charconv\charconv.msvc\test.pass.cpp + +# libc++ doesn't yet implement LWG-3533 +ranges\range.adaptors\range.transform\end.pass.cpp +ranges\range.adaptors\range.transform\iterator\base.pass.cpp + +# MaybePOCCAAllocator doesn't meet the allocator requirements +containers\sequences\vector\vector.cons\assign_copy.pass.cpp + +# Mismatching allocator value_type +containers\sequences\vector.bool\get_allocator.pass.cpp + +# compares iterators from distinct transform_views +ranges\range.adaptors\range.transform\iterator\plus_minus.pass.cpp + +# MoveOnlyForwardIterator (a misnomer) has mixed-type comparisons and conversions +ranges\range.utility\range.subrange\primitives.pass.cpp + +# libc++ speculatively implements LWG-3645 +strings\basic.string\string.capacity\resize_and_overwrite.pass.cpp # *** LIKELY STL BUGS *** @@ -785,6 +966,21 @@ localization\locale.categories\category.ctype\locale.codecvt\locale.codecvt.memb # Likely STL bug in : "result type of conditional expression is ambiguous" utilities\time\time.duration\time.duration.alg\abs.pass.cpp +# Likely STL bug in : we check argument ids at compiletime in next_arg_id +utilities\format\format.formatter\format.parse.ctx\next_arg_id.pass.cpp + +# Likely STL bug in `bind_front`: we don't respect deletion of the target call operator +utilities\function.objects\func.bind_front\bind_front.pass.cpp + +# Likely STL bug in `join_view::_Iterator`: Clang-only constexpr weirdness +ranges\range.adaptors\range.join.view\end.pass.cpp +ranges\range.adaptors\range.join.view\iterator\decrement.pass.cpp +ranges\range.adaptors\range.join.view\iterator\increment.pass.cpp +ranges\range.adaptors\range.join.view\iterator\iter.swap.pass.cpp +ranges\range.adaptors\range.join.view\iterator\star.pass.cpp +ranges\range.adaptors\range.join.view\sentinel\ctor.parent.pass.cpp +ranges\range.adaptors\range.join.view\sentinel\eq.pass.cpp + # *** NOT YET ANALYZED *** # Not yet analyzed. Asserting about alloc_count. @@ -800,8 +996,13 @@ utilities\tuple\tuple.tuple\tuple.helper\tuple_size_incomplete.pass.cpp utilities\tuple\tuple.tuple\tuple.helper\tuple_size_structured_bindings.pass.cpp # Not yet analyzed. Possibly testing nonstandard deduction guides. +containers\associative\map\map.cons\deduct.pass.cpp containers\associative\map\map.cons\deduct_const.pass.cpp +containers\associative\multimap\multimap.cons\deduct.pass.cpp containers\associative\multimap\multimap.cons\deduct_const.pass.cpp +containers\container.adaptors\priority.queue\priqueue.cons\deduct.pass.cpp +containers\sequences\list\list.cons\deduct.pass.cpp +containers\unord\unord.map\unord.map.cnstr\deduct.pass.cpp containers\unord\unord.map\unord.map.cnstr\deduct_const.pass.cpp containers\unord\unord.multimap\unord.multimap.cnstr\deduct.pass.cpp containers\unord\unord.multimap\unord.multimap.cnstr\deduct_const.pass.cpp @@ -817,17 +1018,16 @@ re\re.const\re.matchflag\match_prev_avail.pass.cpp input.output\filesystems\class.path\path.member\path.charconv.pass.cpp # Not yet analyzed. Probably ADL shenanigans. +algorithms\robust_against_adl.compile.pass.cpp +strings\basic.string\string.modifiers\robust_against_adl.pass.cpp thread\thread.threads\thread.thread.class\thread.thread.constr\robust_against_adl.pass.cpp utilities\function.objects\func.wrap\func.wrap.func\robust_against_adl.pass.cpp utilities\function.objects\refwrap\refwrap.invoke\robust_against_adl.pass.cpp utilities\variant\variant.visit\robust_against_adl.pass.cpp -# Not yet analyzed. Probably MSVC bug. +# Not yet analyzed. Possibly C1XX constexpr bugs. utilities\function.objects\func.invoke\invoke_constexpr.pass.cpp -# Not yet analyzed. Probably name mangling bug. -utilities\function.objects\func.wrap\func.wrap.func\noncopyable_return_type.pass.cpp - # Not yet analyzed. Failing for "[a[.ch.]z]". re\re.alg\re.alg.match\awk.locale.pass.cpp re\re.alg\re.alg.match\basic.locale.pass.cpp @@ -851,9 +1051,260 @@ 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 +# Not yet analyzed. Looks like deduction guide SFINAE failure. +containers\sequences\deque\deque.cons\deduct.pass.cpp +containers\sequences\forwardlist\forwardlist.cons\deduct.pass.cpp +containers\sequences\vector\vector.cons\deduct.pass.cpp + +# Not yet analyzed. Seems to force a sign conversion error? +iterators\iterator.primitives\iterator.operations\advance.pass.cpp + +# Not yet analyzed. Maybe Clang over-eagerly instantiating noexcept-specifier? +ranges\range.access\empty.pass.cpp +ranges\range.access\size.pass.cpp +ranges\range.access\ssize.pass.cpp +utilities\memory\unique.ptr\iterator_concept_conformance.compile.pass.cpp + # *** SKIPPED FOR MSVC-INTERNAL CONTEST ONLY *** +# XFAIL: msvc +algorithms\algorithms.results\in_out_result.compile.pass.cpp +algorithms\algorithms.results\no_unique_address.compile.pass.cpp +language.support\support.exception\propagation\current_exception.pass.cpp +utilities\function.objects\func.wrap\func.wrap.func\noncopyable_return_type.pass.cpp + # Our machinery doesn't understand compile-only `.compile.pass.cpp` tests. # (Implemented for GitHub, see GH-1382.) -concepts\concept.constructible\constructible_from.compile.pass.cpp +algorithms\robust_against_adl.compile.pass.cpp +algorithms\robust_re_difference_type.compile.pass.cpp +atomics\atomics.types.generic\constexpr_noexcept.compile.pass.cpp +concepts\concepts.callable\concept.equiv\equivalence_relation.compile.pass.cpp +concepts\concepts.callable\concept.equiv\equivalence_relation.subsumption.compile.pass.cpp +concepts\concepts.callable\concept.invocable\invocable.compile.pass.cpp +concepts\concepts.callable\concept.predicate\predicate.compile.pass.cpp +concepts\concepts.callable\concept.predicate\predicate.subsumption.compile.pass.cpp +concepts\concepts.callable\concept.regularinvocable\regular_invocable.compile.pass.cpp +concepts\concepts.callable\concept.relation\relation.compile.pass.cpp +concepts\concepts.callable\concept.relation\relation.subsumption.compile.pass.cpp +concepts\concepts.callable\concept.strictweakorder\strict_weak_order.compile.pass.cpp +concepts\concepts.callable\concept.strictweakorder\strict_weak_order.subsumption.compile.pass.cpp +concepts\concepts.lang\concept.assignable\assignable_from.compile.pass.cpp +concepts\concepts.lang\concept.swappable\swappable_with.compile.pass.cpp +containers\associative\map\iterator_concept_conformance.compile.pass.cpp +containers\associative\map\map.cons\copy_assign.addressof.compile.pass.cpp +containers\associative\map\range_concept_conformance.compile.pass.cpp +containers\associative\multimap\iterator_concept_conformance.compile.pass.cpp +containers\associative\multimap\multimap.cons\copy_assign.addressof.compile.pass.cpp +containers\associative\multimap\range_concept_conformance.compile.pass.cpp +containers\associative\multiset\iterator_concept_conformance.compile.pass.cpp +containers\associative\multiset\multiset.cons\copy_assign.addressof.compile.pass.cpp +containers\associative\multiset\range_concept_conformance.compile.pass.cpp +containers\associative\set\iterator_concept_conformance.compile.pass.cpp +containers\associative\set\range_concept_conformance.compile.pass.cpp +containers\associative\set\set.cons\copy_assign.addressof.compile.pass.cpp +containers\container.adaptors\priority.queue\priqueue.cons\assign_copy.addressof.compile.pass.cpp +containers\container.adaptors\priority.queue\priqueue.cons\ctor_iter_constraint.compile.pass.cpp +containers\container.adaptors\queue\queue.defn\assign_copy.addressof.compile.pass.cpp +containers\iterator.rel_ops.compile.pass.cpp +containers\sequences\array\array.cons\implicit_copy.addressof.compile.pass.cpp +containers\sequences\array\iterator_concept_conformance.compile.pass.cpp +containers\sequences\array\range_concept_conformance.compile.pass.cpp +containers\sequences\deque\deque.cons\move_assign.addressof.compile.pass.cpp +containers\sequences\deque\iterator_concept_conformance.compile.pass.cpp +containers\sequences\deque\range_concept_conformance.compile.pass.cpp +containers\sequences\forwardlist\forwardlist.cons\assign_copy.addressof.compile.pass.cpp +containers\sequences\forwardlist\forwardlist.iter\iterator_concept_conformance.compile.pass.cpp +containers\sequences\forwardlist\forwardlist.ops\merge_lvalue_pred.addressof.compile.pass.cpp +containers\sequences\forwardlist\forwardlist.ops\merge_lvalue.addressof.compile.pass.cpp +containers\sequences\forwardlist\forwardlist.ops\merge_rvalue_pred.addressof.compile.pass.cpp +containers\sequences\forwardlist\forwardlist.ops\merge_rvalue.addressof.compile.pass.cpp +containers\sequences\forwardlist\range_concept_conformance.compile.pass.cpp +containers\sequences\list\iterator_concept_conformance.compile.pass.cpp +containers\sequences\list\list.cons\assign_copy.addressof.compile.pass.cpp +containers\sequences\list\list.cons\assign_move.addressof.compile.pass.cpp +containers\sequences\list\list.modifiers\emplace.addressof.compile.pass.cpp +containers\sequences\list\list.modifiers\erase_iter.addressof.compile.pass.cpp +containers\sequences\list\list.modifiers\insert_iter_rvalue.addressof.compile.pass.cpp +containers\sequences\list\list.modifiers\insert_iter_size_value.addressof.compile.pass.cpp +containers\sequences\list\list.modifiers\insert_iter_value.addressof.compile.pass.cpp +containers\sequences\list\list.ops\merge_comp.addressof.compile.pass.cpp +containers\sequences\list\list.ops\splice_pos_list_iter_iter.addressof.compile.pass.cpp +containers\sequences\list\list.ops\splice_pos_list_iter.addressof.compile.pass.cpp +containers\sequences\list\list.special\swap.addressof.compile.pass.cpp +containers\sequences\list\range_concept_conformance.compile.pass.cpp +containers\sequences\vector.bool\iterator_concept_conformance.compile.pass.cpp +containers\sequences\vector.bool\range_concept_conformance.compile.pass.cpp +containers\sequences\vector\iterator_concept_conformance.compile.pass.cpp +containers\sequences\vector\range_concept_conformance.compile.pass.cpp +containers\sequences\vector\vector.cons\assign_copy.addressof.compile.pass.cpp +containers\sequences\vector\vector.cons\assign_move.addressof.compile.pass.cpp +containers\sequences\vector\vector.cons\move.addressof.compile.pass.cpp +containers\sequences\vector\vector.modifiers\emplace.addressof.compile.pass.cpp +containers\sequences\vector\vector.modifiers\erase_iter_iter.addressof.compile.pass.cpp +containers\sequences\vector\vector.modifiers\erase_iter.addressof.compile.pass.cpp +containers\sequences\vector\vector.modifiers\insert_iter_iter_iter.addressof.compile.pass.cpp +containers\sequences\vector\vector.modifiers\insert_iter_rvalue.addressof.compile.pass.cpp +containers\sequences\vector\vector.modifiers\insert_iter_size_value.addressof.compile.pass.cpp +containers\sequences\vector\vector.modifiers\insert_iter_value.addressof.compile.pass.cpp +containers\sequences\vector\vector.special\swap.addressof.compile.pass.cpp +containers\unord\unord.map\iterator_concept_conformance.compile.pass.cpp +containers\unord\unord.map\range_concept_conformance.compile.pass.cpp +containers\unord\unord.map\unord.map.cnstr\assign_copy.addressof.compile.pass.cpp +containers\unord\unord.multimap\iterator_concept_conformance.compile.pass.cpp +containers\unord\unord.multimap\range_concept_conformance.compile.pass.cpp +containers\unord\unord.multimap\unord.multimap.cnstr\assign_copy.addressof.compile.pass.cpp +containers\unord\unord.multiset\iterator_concept_conformance.compile.pass.cpp +containers\unord\unord.multiset\range_concept_conformance.compile.pass.cpp +containers\unord\unord.multiset\unord.multiset.cnstr\assign_copy.addressof.compile.pass.cpp +containers\unord\unord.set\iterator_concept_conformance.compile.pass.cpp +containers\unord\unord.set\range_concept_conformance.compile.pass.cpp +containers\unord\unord.set\unord.set.cnstr\assign_copy.addressof.compile.pass.cpp +containers\views\enable_borrowed_range.compile.pass.cpp +containers\views\range_concept_conformance.compile.pass.cpp +containers\views\span.cons\span.dtor.compile.pass.cpp +containers\views\span.iterators\iterator_concept_conformance.compile.pass.cpp +containers\views\trivially_copyable.compile.pass.cpp +depr\depr.c.headers\stdlib_h.aligned_alloc.compile.pass.cpp +input.output\filesystems\class.directory_iterator\iterator_concept_conformance.compile.pass.cpp +input.output\filesystems\class.directory_iterator\range_concept_conformance.compile.pass.cpp +input.output\filesystems\class.path\range_concept_conformance.compile.pass.cpp +input.output\filesystems\class.rec.dir.itr\range_concept_conformance.compile.pass.cpp +input.output\filesystems\fs.filesystem.synopsis\enable_borrowed_range.compile.pass.cpp +input.output\filesystems\fs.filesystem.synopsis\enable_view.compile.pass.cpp +input.output\filesystems\fs.filesystem.synopsis\file_time_type_resolution.compile.pass.cpp +iterators\iterator.primitives\iterator.traits\cxx20_iterator_traits.compile.pass.cpp +iterators\iterator.primitives\iterator.traits\iter_reference_t.compile.pass.cpp +iterators\iterator.primitives\range.iter.ops\range.iter.ops.next\constraints.compile.pass.cpp +iterators\iterator.primitives\range.iter.ops\range.iter.ops.prev\constraints.compile.pass.cpp +iterators\iterator.requirements\alg.req.ind.move\indirectly_movable_storable.compile.pass.cpp +iterators\iterator.requirements\alg.req.ind.move\indirectly_movable_storable.subsumption.compile.pass.cpp +iterators\iterator.requirements\alg.req.ind.move\indirectly_movable.compile.pass.cpp +iterators\iterator.requirements\alg.req.ind.move\indirectly_movable.subsumption.compile.pass.cpp +iterators\iterator.requirements\alg.req.ind.swap\indirectly_swappable.compile.pass.cpp +iterators\iterator.requirements\alg.req.ind.swap\indirectly_swappable.subsumption.compile.pass.cpp +iterators\iterator.requirements\indirectcallable\indirectinvocable\indirect_binary_predicate.compile.pass.cpp +iterators\iterator.requirements\indirectcallable\indirectinvocable\indirect_equivalence_relation.compile.pass.cpp +iterators\iterator.requirements\indirectcallable\indirectinvocable\indirect_result_t.compile.pass.cpp +iterators\iterator.requirements\indirectcallable\indirectinvocable\indirect_strict_weak_order.compile.pass.cpp +iterators\iterator.requirements\indirectcallable\indirectinvocable\indirect_unary_predicate.compile.pass.cpp +iterators\iterator.requirements\indirectcallable\indirectinvocable\indirectly_comparable.compile.pass.cpp +iterators\iterator.requirements\indirectcallable\indirectinvocable\indirectly_regular_unary_invocable.compile.pass.cpp +iterators\iterator.requirements\indirectcallable\indirectinvocable\indirectly_unary_invocable.compile.pass.cpp +iterators\iterator.requirements\indirectcallable\projected\projected.compile.pass.cpp +iterators\iterator.requirements\iterator.assoc.types\incrementable.traits\incrementable_traits.compile.pass.cpp +iterators\iterator.requirements\iterator.assoc.types\incrementable.traits\iter_difference_t.compile.pass.cpp +iterators\iterator.requirements\iterator.assoc.types\readable.traits\indirectly_readable_traits.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.bidir\bidirectional_iterator.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.bidir\subsumption.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.forward\forward_iterator.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.forward\subsumption.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.inc\incrementable.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.inc\subsumption.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.input\input_iterator.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.input\subsumption.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.iterator\input_or_output_iterator.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.iterator\subsumption.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.output\output_iterator.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.random.access\contiguous_iterator.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.random.access\random_access_iterator.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.readable\indirectly_readable.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.readable\iter_common_reference_t.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.sentinel\sentinel_for.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.sentinel\sentinel_for.subsumption.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.sentinel\sized_sentinel_for.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.winc\weakly_incrementable.compile.pass.cpp +iterators\iterator.requirements\iterator.concepts\iterator.concept.writable\indirectly_writable.compile.pass.cpp +iterators\predef.iterators\counted.iterator\iterator_concept_conformance.compile.pass.cpp +iterators\predef.iterators\counted.iterator\iterator_traits.compile.pass.cpp +iterators\predef.iterators\counted.iterator\member_types.compile.pass.cpp +iterators\predef.iterators\insert.iterators\back.insert.iterator\iterator_concept_conformance.compile.pass.cpp +iterators\predef.iterators\insert.iterators\front.insert.iterator\iterator_concept_conformance.compile.pass.cpp +iterators\predef.iterators\insert.iterators\insert.iterator\iterator_concept_conformance.compile.pass.cpp +iterators\predef.iterators\iterators.common\iterator_traits.compile.pass.cpp +iterators\predef.iterators\move.iterators\move.iterator\iterator_concept_conformance.compile.pass.cpp +iterators\predef.iterators\reverse.iterators\iterator_concept_conformance.compile.pass.cpp +iterators\stream.iterators\istream.iterator\iterator_concept_conformance.compile.pass.cpp +iterators\stream.iterators\istreambuf.iterator\iterator_concept_conformance.compile.pass.cpp +iterators\stream.iterators\ostream.iterator\iterator_concept_conformance.compile.pass.cpp +iterators\stream.iterators\ostreambuf.iterator\iterator_concept_conformance.compile.pass.cpp +language.support\cmp\cmp.concept\three_way_comparable_with.compile.pass.cpp +language.support\cmp\cmp.concept\three_way_comparable.compile.pass.cpp +language.support\cmp\cmp.result\compare_three_way_result.compile.pass.cpp +language.support\support.runtime\cstdlib.aligned_alloc.compile.pass.cpp +language.support\support.runtime\ctime.timespec.compile.pass.cpp +language.support\support.types\max_align_t.compile.pass.cpp +library\description\conventions\customization.point.object\cpo.compile.pass.cpp +numerics\bit\bit.cast\bit_cast.compile.pass.cpp +numerics\numarray\template.valarray\valarray.assign\value_assign.addressof.compile.pass.cpp +ranges\range.adaptors\range.all\all_t.compile.pass.cpp +ranges\range.adaptors\range.all\range.owning.view\borrowing.compile.pass.cpp +ranges\range.adaptors\range.common.view\borrowing.compile.pass.cpp +ranges\range.adaptors\range.common.view\ctad.compile.pass.cpp +ranges\range.adaptors\range.drop\ctad.compile.pass.cpp +ranges\range.adaptors\range.join.view\ctad.compile.pass.cpp +ranges\range.adaptors\range.join.view\iterator\member_types.compile.pass.cpp +ranges\range.adaptors\range.reverse\borrowing.compile.pass.cpp +ranges\range.adaptors\range.reverse\ctad.compile.pass.cpp +ranges\range.adaptors\range.reverse\range_concept_conformance.compile.pass.cpp +ranges\range.adaptors\range.take\borrowing.compile.pass.cpp +ranges\range.adaptors\range.take\ctad.compile.pass.cpp +ranges\range.adaptors\range.take\range_concept_conformance.compile.pass.cpp +ranges\range.adaptors\range.transform\ctad.compile.pass.cpp +ranges\range.adaptors\range.transform\iterator\requirements.compile.pass.cpp +ranges\range.factories\range.iota.view\borrowing.compile.pass.cpp +ranges\range.factories\range.iota.view\ctad.compile.pass.cpp +ranges\range.factories\range.iota.view\iterator\member_typedefs.compile.pass.cpp +ranges\range.factories\range.iota.view\range_concept_conformance.compile.pass.cpp +ranges\range.factories\range.iota.view\type.compile.pass.cpp +ranges\range.factories\range.single.view\ctad.compile.pass.cpp +ranges\range.factories\range.single.view\range_concept_conformance.compile.pass.cpp +ranges\range.req\range.range\borrowed_range.compile.pass.cpp +ranges\range.req\range.range\borrowed_range.subsumption.compile.pass.cpp +ranges\range.req\range.range\enable_borrowed_range.compile.pass.cpp +ranges\range.req\range.range\helper_aliases.compile.pass.cpp +ranges\range.req\range.range\iterator_t.compile.pass.cpp +ranges\range.req\range.range\range_size_t.compile.pass.cpp +ranges\range.req\range.range\range.compile.pass.cpp +ranges\range.req\range.range\sentinel_t.compile.pass.cpp +ranges\range.req\range.refinements\bidirectional_range.compile.pass.cpp +ranges\range.req\range.refinements\common_range.compile.pass.cpp +ranges\range.req\range.refinements\contiguous_range.compile.pass.cpp +ranges\range.req\range.refinements\forward_range.compile.pass.cpp +ranges\range.req\range.refinements\input_range.compile.pass.cpp +ranges\range.req\range.refinements\output_range.compile.pass.cpp +ranges\range.req\range.refinements\random_access_range.compile.pass.cpp +ranges\range.req\range.refinements\subsumption.compile.pass.cpp +ranges\range.req\range.refinements\viewable_range.compile.pass.cpp +ranges\range.req\range.sized\sized_range.compile.pass.cpp +ranges\range.req\range.sized\subsumption.compile.pass.cpp +ranges\range.req\range.view\enable_view.compile.pass.cpp +ranges\range.req\range.view\view_base.compile.pass.cpp +ranges\range.req\range.view\view.compile.pass.cpp +ranges\range.req\range.view\view.subsumption.compile.pass.cpp +ranges\range.utility\range.dangling\borrowed_iterator.compile.pass.cpp +ranges\range.utility\range.dangling\borrowed_subrange.compile.pass.cpp +ranges\range.utility\range.subrange\ctad.compile.pass.cpp +ranges\range.utility\range.subrange\enable_borrowed_range.compile.pass.cpp +ranges\range.utility\range.subrange\general.compile.pass.cpp +re\re.iter\re.regiter\iterator_concept_conformance.compile.pass.cpp +re\re.iter\re.tokiter\iterator_concept_conformance.compile.pass.cpp +re\re.results\range_concept_conformance.compile.pass.cpp +strings\basic.string\range_concept_conformance.compile.pass.cpp +strings\basic.string\string.cons\nullptr.compile.pass.cpp +strings\basic.string\string.iterators\iterator_concept_conformance.compile.pass.cpp +strings\string.view\enable_borrowed_range.compile.pass.cpp +strings\string.view\range_concept_conformance.compile.pass.cpp +strings\string.view\string.view.cons\nullptr.compile.pass.cpp strings\string.view\string.view.io\stream_insert_decl_present.compile.pass.cpp +strings\string.view\string.view.iterators\iterator_concept_conformance.compile.pass.cpp +strings\string.view\trivially_copyable.compile.pass.cpp +thread\thread.semaphore\ctor.compile.pass.cpp +utilities\function.objects\comparisons\transparent_three_way.compile.pass.cpp +utilities\memory\default.allocator\PR50299.compile.pass.cpp +utilities\memory\storage.iterator\types.compile.pass.cpp +utilities\memory\unique.ptr\iterator_concept_conformance.compile.pass.cpp +utilities\memory\util.smartptr\util.smartptr.shared\iterator_concept_conformance.compile.pass.cpp +utilities\optional\iterator_concept_conformance.compile.pass.cpp +utilities\tuple\tuple.tuple\tuple.cnstr\cnstr_with_any.compile.pass.cpp +utilities\tuple\tuple.tuple\tuple.cnstr\empty_tuple_trivial.compile.pass.cpp +utilities\tuple\tuple.tuple\tuple.rel\size_incompatible_three_way.compile.pass.cpp From 8a72a064ec4eb18aae713bd0c6906ae9accf47c2 Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Fri, 21 Jan 2022 21:39:41 -0800 Subject: [PATCH 21/31] Update skips to allow for ARM/ARM64 variations --- tests/libcxx/expected_results.txt | 11 ++++++----- tests/libcxx/skipped_tests.txt | 6 +++--- 2 files changed, 9 insertions(+), 8 deletions(-) diff --git a/tests/libcxx/expected_results.txt b/tests/libcxx/expected_results.txt index 03b49b8974..6a0289f111 100644 --- a/tests/libcxx/expected_results.txt +++ b/tests/libcxx/expected_results.txt @@ -14,7 +14,7 @@ std/input.output/iostreams.base/ios.base/ios.base.storage/pword.pass.cpp SKIPPED # "The behavior demonstrated in this test is not meant to be standard" std/utilities/smartptr/unique.ptr/unique.ptr.class/unique.ptr.ctor/null.pass.cpp FAIL -# allocator. +# allocator std/iterators/iterator.requirements/iterator.cust/iterator.cust.move/iter_rvalue_reference_t.pass.cpp FAIL std/utilities/memory/default.allocator/allocator.ctor.pass.cpp FAIL @@ -24,6 +24,7 @@ std/iterators/iterator.primitives/iterator.operations/prev.pass.cpp FAIL # Itanium ABI assumptions that current_exception and rethrow_exception don't copy the exception object std/language.support/support.exception/except.nested/rethrow_if_nested.pass.cpp SKIPPED +std/language.support/support.exception/propagation/current_exception.pass.cpp SKIPPED std/language.support/support.exception/propagation/make_exception_ptr.pass.cpp FAIL std/language.support/support.exception/propagation/rethrow_exception.pass.cpp FAIL @@ -431,10 +432,10 @@ std/ranges/range.req/range.range/range.compile.pass.cpp:1 FAIL # *** CLANG ISSUES, NOT YET ANALYZED *** # Clang doesn't enable sized deallocation by default. Should we add -fsized-deallocation or do something else? -std/language.support/support.dynamic/new.delete/new.delete.array/sized_delete_array_fsizeddeallocation.pass.cpp:1 FAIL -std/language.support/support.dynamic/new.delete/new.delete.array/sized_delete_array14.pass.cpp:1 FAIL -std/language.support/support.dynamic/new.delete/new.delete.single/sized_delete_fsizeddeallocation.pass.cpp:1 FAIL -std/language.support/support.dynamic/new.delete/new.delete.single/sized_delete14.pass.cpp:1 FAIL +std/language.support/support.dynamic/new.delete/new.delete.array/sized_delete_array_fsizeddeallocation.pass.cpp:1 SKIPPED +std/language.support/support.dynamic/new.delete/new.delete.array/sized_delete_array14.pass.cpp:1 SKIPPED +std/language.support/support.dynamic/new.delete/new.delete.single/sized_delete_fsizeddeallocation.pass.cpp:1 SKIPPED +std/language.support/support.dynamic/new.delete/new.delete.single/sized_delete14.pass.cpp:1 SKIPPED # Not yet analyzed. Clang apparently defines platform macros differently from C1XX. std/language.support/support.limits/limits/numeric.limits.members/traps.pass.cpp:1 FAIL diff --git a/tests/libcxx/skipped_tests.txt b/tests/libcxx/skipped_tests.txt index 38b25c0707..726abe88cc 100644 --- a/tests/libcxx/skipped_tests.txt +++ b/tests/libcxx/skipped_tests.txt @@ -14,7 +14,7 @@ input.output\iostreams.base\ios.base\ios.base.storage\pword.pass.cpp # "The behavior demonstrated in this test is not meant to be standard" utilities\smartptr\unique.ptr\unique.ptr.class\unique.ptr.ctor\null.pass.cpp -# allocator. +# allocator iterators\iterator.requirements\iterator.cust\iterator.cust.move\iter_rvalue_reference_t.pass.cpp utilities\memory\default.allocator\allocator.ctor.pass.cpp @@ -24,6 +24,7 @@ iterators\iterator.primitives\iterator.operations\prev.pass.cpp # Itanium ABI assumptions that current_exception and rethrow_exception don't copy the exception object language.support\support.exception\except.nested\rethrow_if_nested.pass.cpp +language.support\support.exception\propagation\current_exception.pass.cpp language.support\support.exception\propagation\make_exception_ptr.pass.cpp language.support\support.exception\propagation\rethrow_exception.pass.cpp @@ -1067,10 +1068,9 @@ utilities\memory\unique.ptr\iterator_concept_conformance.compile.pass.cpp # *** SKIPPED FOR MSVC-INTERNAL CONTEST ONLY *** -# XFAIL: msvc +# "XFAIL: msvc" or "XFAIL: clang" algorithms\algorithms.results\in_out_result.compile.pass.cpp algorithms\algorithms.results\no_unique_address.compile.pass.cpp -language.support\support.exception\propagation\current_exception.pass.cpp utilities\function.objects\func.wrap\func.wrap.func\noncopyable_return_type.pass.cpp # Our machinery doesn't understand compile-only `.compile.pass.cpp` tests. From 6aa149a858063bfea7672baef308ee54e746154a Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Fri, 21 Jan 2022 23:35:30 -0800 Subject: [PATCH 22/31] Two more skips --- tests/libcxx/expected_results.txt | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/tests/libcxx/expected_results.txt b/tests/libcxx/expected_results.txt index 6a0289f111..cbcb884ff1 100644 --- a/tests/libcxx/expected_results.txt +++ b/tests/libcxx/expected_results.txt @@ -36,7 +36,6 @@ std/thread/futures/futures.task/futures.task.members/dtor.pass.cpp SKIPPED std/thread/futures/futures.unique_future/wait_until.pass.cpp SKIPPED # libcxx is incorrect on what the type passed to allocator::construct should be (https://reviews.llvm.org/D61364) - std/containers/associative/map/map.modifiers/insert_and_emplace_allocator_requirements.pass.cpp FAIL std/containers/associative/set/insert_and_emplace_allocator_requirements.pass.cpp FAIL std/containers/unord/unord.map/unord.map.modifiers/insert_and_emplace_allocator_requirements.pass.cpp FAIL @@ -768,8 +767,8 @@ std/ranges/range.adaptors/range.transform/iterator/subscript.pass.cpp FAIL std/ranges/range.utility/view.interface/view.interface.pass.cpp FAIL # tests invalid range -std/utilities/memory/specialized.algorithms/uninitialized.copy/ranges_uninitialized_copy.pass.cpp FAIL -std/utilities/memory/specialized.algorithms/uninitialized.move/ranges_uninitialized_move.pass.cpp FAIL +std/utilities/memory/specialized.algorithms/uninitialized.copy/ranges_uninitialized_copy.pass.cpp SKIPPED +std/utilities/memory/specialized.algorithms/uninitialized.move/ranges_uninitialized_move.pass.cpp SKIPPED # Narrowing conversion std/utilities/memory/specialized.algorithms/uninitialized.copy/ranges_uninitialized_copy_n.pass.cpp:0 FAIL From 743dd63b1e6d5464de576c121930641856cafef5 Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Sun, 23 Jan 2022 09:54:14 -0800 Subject: [PATCH 23/31] Update tests.py for C++23 This has no effect on the number of discovered test cases (30829), I believe because libcxx has no C++23-only tests. I did verify that the test suite picks up a synthesized `// REQUIRES: c++2b` test case with this change that was `UNSUPPORTED` without it. Fixes #2001. --- tests/utils/stl/test/tests.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/utils/stl/test/tests.py b/tests/utils/stl/test/tests.py index 9d8dc869dc..09fdeb86fc 100644 --- a/tests/utils/stl/test/tests.py +++ b/tests/utils/stl/test/tests.py @@ -238,9 +238,9 @@ def _parseFlags(self, litConfig): if flag[1:5] == 'std:': foundStd = True if flag[5:] == 'c++latest': - self._addCustomFeature('c++2a') + self._addCustomFeature('c++2b') elif flag[5:] == 'c++20': - self._addCustomFeature('c++2a') + self._addCustomFeature('c++20') elif flag[5:] == 'c++17': self._addCustomFeature('c++17') elif flag[5:] == 'c++14': From 3854b91d4ccc18ef47a426620d7042e7038a1a30 Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Sun, 23 Jan 2022 09:58:43 -0800 Subject: [PATCH 24/31] Merge: views::counted tweak --- stl/inc/ranges | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stl/inc/ranges b/stl/inc/ranges index 27ae028792..2e40817f05 100644 --- a/stl/inc/ranges +++ b/stl/inc/ranges @@ -4120,7 +4120,7 @@ namespace ranges { noexcept(_Choice<_It>._No_throw) { // clang-format on _STL_ASSERT(_Count >= 0, "The size passed to views::counted must be non-negative"); - constexpr _St _Strat = _Choice>._Strategy; + constexpr _St _Strat = _Choice<_It>._Strategy; if constexpr (_Strat == _St::_Span) { return span(_STD to_address(_STD forward<_It>(_First)), static_cast(_Count)); From 25c87dddde1a98f917655da3ed1f2803df1ab938 Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Sun, 30 Jan 2022 10:06:51 -0800 Subject: [PATCH 25/31] Replace duplicate LLVM bug --- tests/libcxx/expected_results.txt | 2 +- tests/libcxx/skipped_tests.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/libcxx/expected_results.txt b/tests/libcxx/expected_results.txt index cbcb884ff1..95b29acec7 100644 --- a/tests/libcxx/expected_results.txt +++ b/tests/libcxx/expected_results.txt @@ -422,7 +422,7 @@ std/language.support/support.coroutines/end.to.end/multishot_func.pass.cpp:1 FAI std/language.support/support.coroutines/end.to.end/oneshot_func.pass.cpp:1 FAIL std/language.support/support.limits/support.limits.general/coroutine.version.pass.cpp:1 FAIL -# LLVM-52643 Requires-expression too eagerly completes associated type +# LLVM-52970 SFINAEing p.x on a pointer wrongly tries to complete the pointee's type std/ranges/range.access/begin.pass.cpp:1 FAIL std/ranges/range.access/data.pass.cpp:1 FAIL std/ranges/range.access/end.pass.cpp:1 FAIL diff --git a/tests/libcxx/skipped_tests.txt b/tests/libcxx/skipped_tests.txt index 726abe88cc..f937f27534 100644 --- a/tests/libcxx/skipped_tests.txt +++ b/tests/libcxx/skipped_tests.txt @@ -463,7 +463,7 @@ language.support\support.coroutines\end.to.end\multishot_func.pass.cpp language.support\support.coroutines\end.to.end\oneshot_func.pass.cpp language.support\support.limits\support.limits.general\coroutine.version.pass.cpp -# LLVM-52643 Requires-expression too eagerly completes associated type +# LLVM-52970 SFINAEing p.x on a pointer wrongly tries to complete the pointee's type ranges\range.access\begin.pass.cpp ranges\range.access\data.pass.cpp ranges\range.access\end.pass.cpp From 876bf5196b9d82ad935c33cc92e67db1f9b10c29 Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Wed, 9 Feb 2022 16:22:00 -0800 Subject: [PATCH 26/31] Update skips after merging main --- tests/libcxx/expected_results.txt | 6 ++++++ tests/libcxx/skipped_tests.txt | 6 ++++++ 2 files changed, 12 insertions(+) diff --git a/tests/libcxx/expected_results.txt b/tests/libcxx/expected_results.txt index 95b29acec7..d814af8b0e 100644 --- a/tests/libcxx/expected_results.txt +++ b/tests/libcxx/expected_results.txt @@ -800,6 +800,12 @@ std/ranges/range.utility/range.subrange/primitives.pass.cpp:0 FAIL # libc++ speculatively implements LWG-3645 std/strings/basic.string/string.capacity/resize_and_overwrite.pass.cpp FAIL +# libc++ is missing various DRs +std/language.support/support.limits/support.limits.general/format.version.pass.cpp FAIL + +# We speculatively implement LWG-3670 +std/ranges/range.factories/range.iota.view/iterator/member_typedefs.compile.pass.cpp FAIL + # *** LIKELY STL BUGS *** # Not yet analyzed, likely STL bugs. Assertions and other runtime failures. diff --git a/tests/libcxx/skipped_tests.txt b/tests/libcxx/skipped_tests.txt index f937f27534..0a21df6d35 100644 --- a/tests/libcxx/skipped_tests.txt +++ b/tests/libcxx/skipped_tests.txt @@ -837,6 +837,12 @@ ranges\range.utility\range.subrange\primitives.pass.cpp # libc++ speculatively implements LWG-3645 strings\basic.string\string.capacity\resize_and_overwrite.pass.cpp +# libc++ is missing various DRs +language.support\support.limits\support.limits.general\format.version.pass.cpp + +# We speculatively implement LWG-3670 +ranges\range.factories\range.iota.view\iterator\member_typedefs.compile.pass.cpp + # *** LIKELY STL BUGS *** # Not yet analyzed, likely STL bugs. Assertions and other runtime failures. From 28573098e01b61524f5157d2219645770d3d8224 Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Thu, 10 Feb 2022 12:23:22 -0800 Subject: [PATCH 27/31] Restore _Iotinel's aggregateness Also make _Iot{inel,erator} structs again, and add test coverage for all branches of `_Ioterator`'s `operator-`. --- stl/inc/ranges | 27 ++-------- tests/libcxx/expected_results.txt | 3 ++ tests/libcxx/skipped_tests.txt | 3 ++ tests/std/tests/P0896R4_views_iota/test.cpp | 56 +++++++++++++++++++++ 4 files changed, 67 insertions(+), 22 deletions(-) diff --git a/stl/inc/ranges b/stl/inc/ranges index 5fe4ed6fde..480d65ea2f 100644 --- a/stl/inc/ranges +++ b/stl/inc/ranges @@ -1022,19 +1022,9 @@ namespace ranges { template requires copyable<_Wi> - class _Ioterator : public _Ioterator_category_base<_Wi> { - private: + struct _Ioterator : _Ioterator_category_base<_Wi> { /* [[no_unique_address]] */ _Wi _Current{}; - template - requires _Weakly_equality_comparable_with<_Wi2, _Bo2> && copyable<_Wi2> - friend class _Iotinel; - - template - requires _Weakly_equality_comparable_with<_Wi2, _Bo2> && copyable<_Wi2> - friend class iota_view; - - public: using iterator_concept = conditional_t<_Advanceable<_Wi>, random_access_iterator_tag, conditional_t<_Decrementable<_Wi>, bidirectional_iterator_tag, conditional_t, forward_iterator_tag, input_iterator_tag>>>; @@ -1191,12 +1181,14 @@ namespace ranges { static_cast<_Wi>(_It._Current + _Off))) /* strengthened */ requires _Advanceable<_Wi> { return _Ioterator{static_cast<_Wi>(_It._Current + _Off)}; } + _NODISCARD friend constexpr _Ioterator operator-(_Ioterator _It, const difference_type _Off) noexcept( is_nothrow_move_constructible_v<_Ioterator>&& noexcept( _It -= _Off)) /* strengthened */ requires _Advanceable<_Wi> { _It -= _Off; return _It; } + _NODISCARD friend constexpr difference_type operator-(const _Ioterator& _Left, const _Ioterator& _Right) noexcept( noexcept(_Left._Current - _Right._Current)) /* strengthened */ requires _Advanceable<_Wi> { @@ -1219,17 +1211,11 @@ namespace ranges { // clang-format off template requires _Weakly_equality_comparable_with<_Wi, _Bo> && copyable<_Wi> - class _Iotinel { + struct _Iotinel { // clang-format on private: using _It = _Ioterator<_Wi>; - /* [[no_unique_address]] */ _Bo _Last{}; - - template - requires _Weakly_equality_comparable_with<_Wi2, _Bo2> && copyable<_Wi2> - friend class iota_view; - _NODISCARD constexpr bool _Equal(const _It& _That) const noexcept(noexcept(_That._Current == _Last)) { return _That._Current == _Last; } @@ -1241,10 +1227,7 @@ namespace ranges { } public: - _Iotinel() = default; - - constexpr explicit _Iotinel(_Bo _Last_) noexcept(is_nothrow_move_constructible_v<_Bo>) - : _Last(_STD move(_Last_)) {} + /* [[no_unique_address]] */ _Bo _Last{}; _NODISCARD friend constexpr bool operator==(const _It& _Left, const _Iotinel& _Right) noexcept( noexcept(_Right._Equal(_Left))) /* strengthened */ { diff --git a/tests/libcxx/expected_results.txt b/tests/libcxx/expected_results.txt index d814af8b0e..fca56a17d0 100644 --- a/tests/libcxx/expected_results.txt +++ b/tests/libcxx/expected_results.txt @@ -428,6 +428,9 @@ std/ranges/range.access/data.pass.cpp:1 FAIL std/ranges/range.access/end.pass.cpp:1 FAIL std/ranges/range.req/range.range/range.compile.pass.cpp:1 FAIL +# Clang doesn't yet implement P0960 "Initializing Aggregates With Parentheses" +std/ranges/range.factories/range.iota.view/sentinel/ctor.value.pass.cpp:1 FAIL + # *** CLANG ISSUES, NOT YET ANALYZED *** # Clang doesn't enable sized deallocation by default. Should we add -fsized-deallocation or do something else? diff --git a/tests/libcxx/skipped_tests.txt b/tests/libcxx/skipped_tests.txt index 0a21df6d35..8cfff3c2cc 100644 --- a/tests/libcxx/skipped_tests.txt +++ b/tests/libcxx/skipped_tests.txt @@ -469,6 +469,9 @@ ranges\range.access\data.pass.cpp ranges\range.access\end.pass.cpp ranges\range.req\range.range\range.compile.pass.cpp +# Clang doesn't yet implement P0960 "Initializing Aggregates With Parentheses" +ranges\range.factories\range.iota.view\sentinel\ctor.value.pass.cpp + # *** CLANG ISSUES, NOT YET ANALYZED *** # Clang doesn't enable sized deallocation by default. Should we add -fsized-deallocation or do something else? diff --git a/tests/std/tests/P0896R4_views_iota/test.cpp b/tests/std/tests/P0896R4_views_iota/test.cpp index 20aea90c5f..59429f76c8 100644 --- a/tests/std/tests/P0896R4_views_iota/test.cpp +++ b/tests/std/tests/P0896R4_views_iota/test.cpp @@ -4,6 +4,8 @@ #include #include #include +#include +#include #include #include #include @@ -239,6 +241,57 @@ constexpr void test_integral() { } } +template +constexpr void test_one_difference() { + ranges::iota_view r{numeric_limits::min(), numeric_limits::max()}; + using Diff = conditional_t= sizeof(long long), _Signed128, + conditional_t= sizeof(int), long long, int>>; + static_assert(same_as); + static_assert(noexcept(r.end() - r.begin())); + const auto n = (Diff{1} << (numeric_limits::digits + (signed_integral ? 1 : 0))) - 1; + assert(r.end() - r.begin() == n); // left > right + assert(r.begin() - r.end() == -n); // right > left +} + +constexpr bool test_difference() { + // Ensure we have full coverage of all branches in `operator-(i, s)` + + // signed integer-like, sizeof(W) < sizeof(int) + test_one_difference(); + test_one_difference(); + + // unsigned integer-like, sizeof(W) < sizeof(int) + test_one_difference(); + test_one_difference(); + + // signed integer-like, sizeof <= sizeof(W) < sizeof(long long) + test_one_difference(); + + // unsigned integer-like, sizeof <= sizeof(W) < sizeof(long long) + test_one_difference(); + + // signed integer-like, sizeof <= sizeof(W) + test_one_difference(); + + // unsigned integer-like, sizeof <= sizeof(W) + test_one_difference(); + + // non-integer-like + { + char* some_chars = new char[1ull << 24]; + ranges::iota_view r{&some_chars[0], &some_chars[1ull << 24]}; + using Diff = ptrdiff_t; + static_assert(same_as); + static_assert(noexcept(r.end() - r.begin())); + const auto n = Diff{1} << 24; + assert(r.end() - r.begin() == n); // left > right + assert(r.begin() - r.end() == -n); // right > left + delete[] some_chars; + } + + return true; +} + int main() { // Validate standard signed integer types static_assert((test_integral(), true)); @@ -304,4 +357,7 @@ int main() { assert(ranges::equal(r, even_ints, ranges::equal_to{}, deref)); } + + test_difference(); + static_assert(test_difference()); } From e2ab01dc7d2a4470f5005be5d0cfc69f14371798 Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Thu, 10 Feb 2022 13:28:57 -0800 Subject: [PATCH 28/31] More review comments --- tests/libcxx/expected_results.txt | 94 +----- tests/libcxx/skipped_tests.txt | 271 +++++++++--------- .../P0645R10_text_formatting_death/test.cpp | 5 + .../std/tests/P0896R4_views_counted/test.cpp | 11 + 4 files changed, 156 insertions(+), 225 deletions(-) diff --git a/tests/libcxx/expected_results.txt b/tests/libcxx/expected_results.txt index fca56a17d0..f78914759c 100644 --- a/tests/libcxx/expected_results.txt +++ b/tests/libcxx/expected_results.txt @@ -204,22 +204,6 @@ std/input.output/filesystems/fs.op.funcs/fs.op.weakly_canonical/weakly_canonical # generate_feature_test_macro_components.py needs to learn about C1XX std/language.support/support.limits/support.limits.general/version.version.pass.cpp FAIL -# Contest does not understand .sh tests, which must be run specially -std/atomics/atomics.general/replace_failure_order_codegen.sh.cpp SKIPPED -std/containers/associative/map/PR28469_undefined_behavior_segfault.sh.cpp SKIPPED -std/input.output/iostream.objects/narrow.stream.objects/cerr.sh.cpp SKIPPED -std/input.output/iostream.objects/narrow.stream.objects/cin.sh.cpp SKIPPED -std/input.output/iostream.objects/narrow.stream.objects/clog.sh.cpp SKIPPED -std/input.output/iostream.objects/narrow.stream.objects/cout.sh.cpp SKIPPED -std/input.output/iostream.objects/wide.stream.objects/wcerr.sh.cpp SKIPPED -std/input.output/iostream.objects/wide.stream.objects/wcin.sh.cpp SKIPPED -std/input.output/iostream.objects/wide.stream.objects/wclog.sh.cpp SKIPPED -std/input.output/iostream.objects/wide.stream.objects/wcout.sh.cpp SKIPPED -std/namespace/addressable_functions.sh.cpp SKIPPED -std/strings/basic.string/string.capacity/shrink_to_fit.explicit_instantiation.sh.cpp SKIPPED -std/thread/thread.condition/thread.condition.condvarany/wait_terminates.sh.cpp SKIPPED -std/utilities/format/format.arguments/format.arg.store/make_format_args.sh.cpp SKIPPED - # These tests set an allocator with a max_size() too small to default construct an unordered container # (due to our minimum bucket size). std/containers/unord/unord.map/max_size.pass.cpp FAIL @@ -231,80 +215,11 @@ std/containers/unord/unord.set/max_size.pass.cpp FAIL std/utilities/tuple/tuple.tuple/tuple.apply/apply_large_arity.pass.cpp SKIPPED std/utilities/tuple/tuple.tuple/tuple.cnstr/recursion_depth.pass.cpp SKIPPED -# .verify.cpp tests use clang-verify to validate warnings -std/containers/associative/map/map.access/empty.verify.cpp SKIPPED -std/containers/associative/multimap/empty.verify.cpp SKIPPED -std/containers/associative/multiset/empty.verify.cpp SKIPPED -std/containers/associative/set/empty.verify.cpp SKIPPED -std/containers/container.adaptors/priority.queue/priqueue.members/empty.verify.cpp SKIPPED -std/containers/container.adaptors/queue/queue.defn/empty.verify.cpp SKIPPED -std/containers/container.adaptors/stack/stack.defn/empty.verify.cpp SKIPPED -std/containers/sequences/array/empty.verify.cpp SKIPPED -std/containers/sequences/deque/deque.capacity/empty.verify.cpp SKIPPED -std/containers/sequences/forwardlist/empty.verify.cpp SKIPPED -std/containers/sequences/list/list.capacity/empty.verify.cpp SKIPPED -std/containers/sequences/vector.bool/empty.verify.cpp SKIPPED -std/containers/sequences/vector/vector.capacity/empty.verify.cpp SKIPPED -std/containers/sequences/vector/vector.cons/copy.move_only.verify.cpp SKIPPED -std/containers/unord/unord.map/empty.verify.cpp SKIPPED -std/containers/unord/unord.multimap/empty.verify.cpp SKIPPED -std/containers/unord/unord.multiset/empty.verify.cpp SKIPPED -std/containers/unord/unord.set/empty.verify.cpp SKIPPED -std/depr/depr.lib.binders/depr.lib.bind.1st/bind1st.depr_in_cxx11.verify.cpp SKIPPED -std/depr/depr.lib.binders/depr.lib.bind.2nd/bind2nd.depr_in_cxx11.verify.cpp SKIPPED -std/depr/depr.lib.binders/depr.lib.binder.1st/binder1st.depr_in_cxx11.verify.cpp SKIPPED -std/depr/depr.lib.binders/depr.lib.binder.2nd/binder2nd.depr_in_cxx11.verify.cpp SKIPPED -std/input.output/filesystems/class.path/path.member/path.decompose/empty.verify.cpp SKIPPED -std/input.output/iostream.format/input.streams/istream.rvalue/not_istreamable.verify.cpp SKIPPED -std/input.output/iostream.format/output.streams/ostream.rvalue/not_ostreamable.verify.cpp SKIPPED -std/input.output/iostream.format/quoted.manip/quoted_char.verify.cpp SKIPPED -std/input.output/iostream.format/quoted.manip/quoted_traits.verify.cpp SKIPPED -std/iterators/iterator.container/empty.array.verify.cpp SKIPPED -std/iterators/iterator.container/empty.container.verify.cpp SKIPPED -std/iterators/iterator.container/empty.initializer_list.verify.cpp SKIPPED -std/language.support/cmp/cmp.categories.pre/zero_type.verify.cpp SKIPPED -std/language.support/support.dynamic/new.delete/new.delete.array/new_size_align_nothrow.verify.cpp SKIPPED -std/language.support/support.dynamic/new.delete/new.delete.array/new_size_align.verify.cpp SKIPPED -std/language.support/support.dynamic/new.delete/new.delete.array/new_size_nothrow.verify.cpp SKIPPED -std/language.support/support.dynamic/new.delete/new.delete.array/new_size.verify.cpp SKIPPED -std/language.support/support.dynamic/new.delete/new.delete.placement/new_array_ptr.verify.cpp SKIPPED -std/language.support/support.dynamic/new.delete/new.delete.placement/new_ptr.verify.cpp SKIPPED -std/language.support/support.dynamic/new.delete/new.delete.single/new_size_align_nothrow.verify.cpp SKIPPED -std/language.support/support.dynamic/new.delete/new.delete.single/new_size_align.verify.cpp SKIPPED -std/language.support/support.dynamic/new.delete/new.delete.single/new_size_nothrow.verify.cpp SKIPPED -std/language.support/support.dynamic/new.delete/new.delete.single/new_size.verify.cpp SKIPPED -std/language.support/support.dynamic/ptr.launder/launder.nodiscard.verify.cpp SKIPPED -std/numerics/numbers/illformed.verify.cpp SKIPPED -std/re/re.results/re.results.size/empty.verify.cpp SKIPPED -std/strings/basic.string/string.capacity/empty.verify.cpp SKIPPED -std/strings/string.view/string.view.capacity/empty.verify.cpp SKIPPED -std/thread/futures/futures.async/async.verify.cpp SKIPPED -std/thread/futures/futures.promise/copy_assign.verify.cpp SKIPPED -std/thread/futures/futures.promise/copy_ctor.verify.cpp SKIPPED -std/thread/futures/futures.unique_future/copy_assign.verify.cpp SKIPPED -std/thread/futures/futures.unique_future/copy_ctor.verify.cpp SKIPPED -std/utilities/allocator.adaptor/allocator.adaptor.members/allocate_size_hint.verify.cpp SKIPPED -std/utilities/allocator.adaptor/allocator.adaptor.members/allocate_size.verify.cpp SKIPPED -std/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/alloc_F.verify.cpp SKIPPED -std/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/alloc_function.verify.cpp SKIPPED -std/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/alloc_nullptr.verify.cpp SKIPPED -std/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/alloc_rfunction.verify.cpp SKIPPED -std/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/alloc.verify.cpp SKIPPED -std/utilities/function.objects/negators/binary_negate.depr_in_cxx17.verify.cpp SKIPPED -std/utilities/function.objects/negators/not1.depr_in_cxx17.verify.cpp SKIPPED -std/utilities/function.objects/negators/not2.depr_in_cxx17.verify.cpp SKIPPED -std/utilities/function.objects/negators/unary_negate.depr_in_cxx17.verify.cpp SKIPPED -std/utilities/memory/allocator.traits/allocator.traits.members/allocate.verify.cpp SKIPPED -std/utilities/memory/default.allocator/allocator_types.deprecated_in_cxx17.verify.cpp SKIPPED -std/utilities/memory/default.allocator/allocator_types.removed_in_cxx20.verify.cpp SKIPPED -std/utilities/memory/default.allocator/allocator.members/allocate.constexpr.size.verify.cpp SKIPPED -std/utilities/memory/default.allocator/allocator.members/allocate.verify.cpp SKIPPED - # Deprecation is a mess. We disable all deprecations in msvc_stdlib_force_include.hpp to allow libc++ tests for # deprecated features to pass, which breaks when libc++ deprecates the feature and adds two tests that (1) pass -# with deprecation suppressed, and (2) fail without deprecation suppression. I think we should instead translate -# libc++ un-deprecation macros to STL un-deprecation macros in the force-include header, and just skip tests when -# we deprecate before they do. +# with deprecation suppressed, and (2) fail without deprecation suppression. We should instead translate libc++ +# un-deprecation macros to STL un-deprecation macros in the force-include header, and just skip tests when we +# deprecate before they do. std/utilities/meta/meta.unary/meta.unary.prop/is_literal_type.deprecated.fail.cpp FAIL @@ -524,7 +439,7 @@ std/numerics/c.math/cmath.pass.cpp FAIL std/input.output/filesystems/class.path/range_concept_conformance.compile.pass.cpp FAIL # GH-1374: Spaceship CPO wording in [cmp.alg] needs an overhaul -# (Technically an STL bug until I fix the wording in the working draft to agree.) +# (Technically an STL bug until the wording in the working draft is fixed to agree.) std/language.support/cmp/cmp.alg/partial_order.pass.cpp FAIL std/language.support/cmp/cmp.alg/strong_order.pass.cpp FAIL std/language.support/cmp/cmp.alg/weak_order.pass.cpp FAIL @@ -1000,7 +915,6 @@ std/utilities/variant/variant.visit/robust_against_adl.pass.cpp FAIL # Not yet analyzed. Possibly C1XX constexpr bug. std/utilities/function.objects/func.invoke/invoke_constexpr.pass.cpp:0 FAIL -std/ranges/range.adaptors/range.join.view/iterator/increment.pass.cpp:0 FAIL # Not yet analyzed. Failing for "[a[.ch.]z]". std/re/re.alg/re.alg.match/awk.locale.pass.cpp FAIL diff --git a/tests/libcxx/skipped_tests.txt b/tests/libcxx/skipped_tests.txt index 8cfff3c2cc..b2cb429021 100644 --- a/tests/libcxx/skipped_tests.txt +++ b/tests/libcxx/skipped_tests.txt @@ -72,7 +72,7 @@ utilities\format\format.formatter\format.parse.ctx\end.pass.cpp # libc++ doesn't correctly constrain the iterator_traits specialization for common_iterator (https://reviews.llvm.org/D117449) iterators\predef.iterators\iterators.common\iterator_traits.compile.pass.cpp -# libc++ hasn't updated move_iterator for P0896R4 +# libc++ hasn't updated {move,reverse}_iterator for P0896R4 iterators\predef.iterators\move.iterators\move.iter.ops\move.iter.op=\move_iterator.pass.cpp iterators\predef.iterators\move.iterators\move.iterator\iterator_concept_conformance.compile.pass.cpp iterators\predef.iterators\reverse.iterators\iterator_concept_conformance.compile.pass.cpp @@ -204,22 +204,6 @@ input.output\filesystems\fs.op.funcs\fs.op.weakly_canonical\weakly_canonical.pas # generate_feature_test_macro_components.py needs to learn about C1XX language.support\support.limits\support.limits.general\version.version.pass.cpp -# Contest does not understand .sh tests, which must be run specially -atomics\atomics.general\replace_failure_order_codegen.sh.cpp -containers\associative\map\PR28469_undefined_behavior_segfault.sh.cpp -input.output\iostream.objects\narrow.stream.objects\cerr.sh.cpp -input.output\iostream.objects\narrow.stream.objects\cin.sh.cpp -input.output\iostream.objects\narrow.stream.objects\clog.sh.cpp -input.output\iostream.objects\narrow.stream.objects\cout.sh.cpp -input.output\iostream.objects\wide.stream.objects\wcerr.sh.cpp -input.output\iostream.objects\wide.stream.objects\wcin.sh.cpp -input.output\iostream.objects\wide.stream.objects\wclog.sh.cpp -input.output\iostream.objects\wide.stream.objects\wcout.sh.cpp -namespace\addressable_functions.sh.cpp -strings\basic.string\string.capacity\shrink_to_fit.explicit_instantiation.sh.cpp -thread\thread.condition\thread.condition.condvarany\wait_terminates.sh.cpp -utilities\format\format.arguments\format.arg.store\make_format_args.sh.cpp - # These tests set an allocator with a max_size() too small to default construct an unordered container # (due to our minimum bucket size). containers\unord\unord.map\max_size.pass.cpp @@ -231,121 +215,11 @@ containers\unord\unord.set\max_size.pass.cpp utilities\tuple\tuple.tuple\tuple.apply\apply_large_arity.pass.cpp utilities\tuple\tuple.tuple\tuple.cnstr\recursion_depth.pass.cpp -# .verify.cpp tests use clang-verify to validate warnings -atomics\atomics.types.generic\trivially_copyable.verify.cpp -atomics\atomics.types.operations\atomics.types.operations.req\copy.assign.ptr.volatile.verify.cpp -atomics\atomics.types.operations\atomics.types.operations.req\copy.assign.volatile.verify.cpp -concepts\concepts.lang\concept.default.init\default_initializable.verify.cpp -containers\associative\map\map.access\empty.verify.cpp -containers\associative\multimap\empty.verify.cpp -containers\associative\multiset\empty.verify.cpp -containers\associative\set\empty.verify.cpp -containers\container.adaptors\priority.queue\priqueue.members\empty.verify.cpp -containers\container.adaptors\queue\queue.defn\empty.verify.cpp -containers\container.adaptors\stack\stack.defn\empty.verify.cpp -containers\container.node\node_handle.nodiscard.verify.cpp -containers\sequences\array\empty.verify.cpp -containers\sequences\deque\deque.capacity\empty.verify.cpp -containers\sequences\forwardlist\empty.verify.cpp -containers\sequences\list\list.capacity\empty.verify.cpp -containers\sequences\vector\vector.capacity\empty.verify.cpp -containers\sequences\vector\vector.cons\copy.move_only.verify.cpp -containers\sequences\vector.bool\empty.verify.cpp -containers\unord\unord.map\empty.verify.cpp -containers\unord\unord.multimap\empty.verify.cpp -containers\unord\unord.multiset\empty.verify.cpp -containers\unord\unord.set\empty.verify.cpp -containers\views\span.cons\iterator_len.verify.cpp -containers\views\span.cons\iterator_sentinel.verify.cpp -containers\views\span.obs\empty.nodiscard.verify.cpp -depr\depr.atomics\depr.atomics.nonmembers\atomic_init.depr_in_cxx20.verify.cpp -depr\depr.lib.binders\depr.lib.bind.1st\bind1st.depr_in_cxx11.verify.cpp -depr\depr.lib.binders\depr.lib.bind.2nd\bind2nd.depr_in_cxx11.verify.cpp -depr\depr.lib.binders\depr.lib.binder.1st\binder1st.depr_in_cxx11.verify.cpp -depr\depr.lib.binders\depr.lib.binder.2nd\binder2nd.depr_in_cxx11.verify.cpp -input.output\filesystems\class.path\path.member\path.decompose\empty.verify.cpp -input.output\iostream.format\input.streams\istream.rvalue\not_istreamable.verify.cpp -input.output\iostream.format\output.streams\ostream.rvalue\not_ostreamable.verify.cpp -input.output\iostream.format\quoted.manip\quoted_char.verify.cpp -input.output\iostream.format\quoted.manip\quoted_traits.verify.cpp -iterators\iterator.container\empty.array.verify.cpp -iterators\iterator.container\empty.container.verify.cpp -iterators\iterator.container\empty.initializer_list.verify.cpp -iterators\iterator.primitives\iterator.basic\deprecated.verify.cpp -iterators\iterator.primitives\range.iter.ops\range.iter.ops.advance\constraints.verify.cpp -iterators\iterator.requirements\iterator.cust\iterator.cust.move\iter_move.nodiscard.verify.cpp -iterators\predef.iterators\move.iterators\move.iter.ops\move.iter.op.const\ctor.convert.LWG3435.verify.cpp -iterators\predef.iterators\move.iterators\move.iter.ops\move.iter.op.const\ctor.iter.explicit.verify.cpp -iterators\predef.iterators\move.iterators\move.iter.ops\move.iter.op=\assign.LWG3435.verify.cpp -iterators\predef.iterators\reverse.iterators\reverse.iter.cons\assign.LWG3435.verify.cpp -iterators\predef.iterators\reverse.iterators\reverse.iter.cons\ctor.iter.explicit.verify.cpp -iterators\predef.iterators\reverse.iterators\reverse.iter.cons\ctor.reverse_iterator.LWG3435.verify.cpp -language.support\cmp\cmp.alg\strong_order_long_double.verify.cpp -language.support\cmp\cmp.categories.pre\zero_type.verify.cpp -language.support\support.dynamic\new.delete\new.delete.array\new_size.verify.cpp -language.support\support.dynamic\new.delete\new.delete.array\new_size_align.verify.cpp -language.support\support.dynamic\new.delete\new.delete.array\new_size_align_nothrow.verify.cpp -language.support\support.dynamic\new.delete\new.delete.array\new_size_nothrow.verify.cpp -language.support\support.dynamic\new.delete\new.delete.placement\new_array_ptr.verify.cpp -language.support\support.dynamic\new.delete\new.delete.placement\new_ptr.verify.cpp -language.support\support.dynamic\new.delete\new.delete.single\new_size.verify.cpp -language.support\support.dynamic\new.delete\new.delete.single\new_size_align.verify.cpp -language.support\support.dynamic\new.delete\new.delete.single\new_size_align_nothrow.verify.cpp -language.support\support.dynamic\new.delete\new.delete.single\new_size_nothrow.verify.cpp -language.support\support.dynamic\ptr.launder\launder.nodiscard.verify.cpp -localization\locale.categories\category.ctype\locale.codecvt\codecvt_char16_t_char.depr_in_cxx20.verify.cpp -localization\locale.categories\category.ctype\locale.codecvt\codecvt_char32_t_char.depr_in_cxx20.verify.cpp -localization\locale.categories\category.ctype\locale.codecvt.byname\codecvt_byname_char16_t_char.depr_in_cxx20.verify.cpp -localization\locale.categories\category.ctype\locale.codecvt.byname\codecvt_byname_char32_t_char.depr_in_cxx20.verify.cpp -numerics\c.math\abs.verify.cpp -numerics\numbers\illformed.verify.cpp -ranges\range.adaptors\range.join.view\ctad.verify.cpp -re\re.results\re.results.size\empty.verify.cpp -strings\basic.string\string.capacity\empty.verify.cpp -strings\basic.string\string.capacity\reserve.deprecated_in_cxx20.verify.cpp -strings\basic.string.literals\literal.verify.cpp -strings\string.view\string.view.capacity\empty.verify.cpp -strings\string.view\string_view.literals\literal.verify.cpp -thread\futures\futures.async\async.verify.cpp -thread\futures\futures.promise\copy_assign.verify.cpp -thread\futures\futures.promise\copy_ctor.verify.cpp -thread\futures\futures.unique_future\copy_assign.verify.cpp -thread\futures\futures.unique_future\copy_ctor.verify.cpp -utilities\allocator.adaptor\allocator.adaptor.members\allocate_size.verify.cpp -utilities\allocator.adaptor\allocator.adaptor.members\allocate_size_hint.verify.cpp -utilities\any\any.nonmembers\any.cast\const_correctness.verify.cpp -utilities\any\any.nonmembers\any.cast\not_copy_constructible.verify.cpp -utilities\format\format.formatter\format.parse.ctx\check_arg_id.verify.cpp -utilities\function.objects\func.bind_front\bind_front.verify.cpp -utilities\function.objects\func.wrap\func.wrap.func\func.wrap.func.con\alloc.verify.cpp -utilities\function.objects\func.wrap\func.wrap.func\func.wrap.func.con\alloc_F.verify.cpp -utilities\function.objects\func.wrap\func.wrap.func\func.wrap.func.con\alloc_function.verify.cpp -utilities\function.objects\func.wrap\func.wrap.func\func.wrap.func.con\alloc_nullptr.verify.cpp -utilities\function.objects\func.wrap\func.wrap.func\func.wrap.func.con\alloc_rfunction.verify.cpp -utilities\function.objects\negators\binary_negate.depr_in_cxx17.verify.cpp -utilities\function.objects\negators\not1.depr_in_cxx17.verify.cpp -utilities\function.objects\negators\not2.depr_in_cxx17.verify.cpp -utilities\function.objects\negators\unary_negate.depr_in_cxx17.verify.cpp -utilities\memory\allocator.traits\allocator.traits.members\allocate.verify.cpp -utilities\memory\default.allocator\allocator.members\allocate.constexpr.size.verify.cpp -utilities\memory\default.allocator\allocator.members\allocate.verify.cpp -utilities\memory\default.allocator\allocator_types.deprecated_in_cxx17.verify.cpp -utilities\memory\default.allocator\allocator_types.removed_in_cxx20.verify.cpp -utilities\memory\pointer.conversion\to_address_on_funcptr.verify.cpp -utilities\memory\pointer.conversion\to_address_on_function.verify.cpp -utilities\memory\storage.iterator\deprecated.verify.cpp -utilities\meta\meta.trans\meta.trans.other\result_of.deprecated.verify.cpp -utilities\smartptr\unique.ptr\unique.ptr.class\unique.ptr.observers\dereference.verify.cpp -utilities\smartptr\unique.ptr\unique.ptr.class\unique.ptr.observers\op_arrow.verify.cpp -utilities\tuple\tuple.tuple\tuple.cnstr\default.lazy.verify.cpp -utilities\tuple\tuple.tuple\tuple.rel\size_incompatible_comparison.verify.cpp -utilities\utility\utility.underlying\to_underlying.verify.cpp - # Deprecation is a mess. We disable all deprecations in msvc_stdlib_force_include.hpp to allow libc++ tests for # deprecated features to pass, which breaks when libc++ deprecates the feature and adds two tests that (1) pass -# with deprecation suppressed, and (2) fail without deprecation suppression. I think we should instead translate -# libc++ un-deprecation macros to STL un-deprecation macros in the force-include header, and just skip tests when -# we deprecate before they do. +# with deprecation suppressed, and (2) fail without deprecation suppression. We should instead translate libc++ +# un-deprecation macros to STL un-deprecation macros in the force-include header, and just skip tests when we +# deprecate before they do. utilities\meta\meta.unary\meta.unary.prop\is_literal_type.deprecated.fail.cpp @@ -565,7 +439,7 @@ numerics\c.math\cmath.pass.cpp input.output\filesystems\class.path\range_concept_conformance.compile.pass.cpp # GH-1374: Spaceship CPO wording in [cmp.alg] needs an overhaul -# (Technically an STL bug until I fix the wording in the working draft to agree.) +# (Technically an STL bug until the wording in the working draft is fixed to agree.) language.support\cmp\cmp.alg\partial_order.pass.cpp language.support\cmp\cmp.alg\strong_order.pass.cpp language.support\cmp\cmp.alg\weak_order.pass.cpp @@ -982,7 +856,7 @@ utilities\format\format.formatter\format.parse.ctx\next_arg_id.pass.cpp # Likely STL bug in `bind_front`: we don't respect deletion of the target call operator utilities\function.objects\func.bind_front\bind_front.pass.cpp -# Likely STL bug in `join_view::_Iterator`: Clang-only constexpr weirdness +# Likely STL bug in `join_view::_Iterator`: constexpr weirdness ranges\range.adaptors\range.join.view\end.pass.cpp ranges\range.adaptors\range.join.view\iterator\decrement.pass.cpp ranges\range.adaptors\range.join.view\iterator\increment.pass.cpp @@ -1035,7 +909,7 @@ utilities\function.objects\func.wrap\func.wrap.func\robust_against_adl.pass.cpp utilities\function.objects\refwrap\refwrap.invoke\robust_against_adl.pass.cpp utilities\variant\variant.visit\robust_against_adl.pass.cpp -# Not yet analyzed. Possibly C1XX constexpr bugs. +# Not yet analyzed. Possibly C1XX constexpr bug. utilities\function.objects\func.invoke\invoke_constexpr.pass.cpp # Not yet analyzed. Failing for "[a[.ch.]z]". @@ -1082,8 +956,8 @@ algorithms\algorithms.results\in_out_result.compile.pass.cpp algorithms\algorithms.results\no_unique_address.compile.pass.cpp utilities\function.objects\func.wrap\func.wrap.func\noncopyable_return_type.pass.cpp -# Our machinery doesn't understand compile-only `.compile.pass.cpp` tests. -# (Implemented for GitHub, see GH-1382.) +# Contest doesn't understand compile-only `.compile.pass.cpp` tests. Tests with a stub `main` are +# fine, but tests with no `main` function are effectively GitHub-only. algorithms\robust_against_adl.compile.pass.cpp algorithms\robust_re_difference_type.compile.pass.cpp atomics\atomics.types.generic\constexpr_noexcept.compile.pass.cpp @@ -1317,3 +1191,130 @@ utilities\optional\iterator_concept_conformance.compile.pass.cpp utilities\tuple\tuple.tuple\tuple.cnstr\cnstr_with_any.compile.pass.cpp utilities\tuple\tuple.tuple\tuple.cnstr\empty_tuple_trivial.compile.pass.cpp utilities\tuple\tuple.tuple\tuple.rel\size_incompatible_three_way.compile.pass.cpp + +# .verify.cpp tests use clang-verify to validate warnings; GitHub knows not to run them, +# Contest must be told. +atomics\atomics.types.generic\trivially_copyable.verify.cpp +atomics\atomics.types.operations\atomics.types.operations.req\copy.assign.ptr.volatile.verify.cpp +atomics\atomics.types.operations\atomics.types.operations.req\copy.assign.volatile.verify.cpp +concepts\concepts.lang\concept.default.init\default_initializable.verify.cpp +containers\associative\map\map.access\empty.verify.cpp +containers\associative\multimap\empty.verify.cpp +containers\associative\multiset\empty.verify.cpp +containers\associative\set\empty.verify.cpp +containers\container.adaptors\priority.queue\priqueue.members\empty.verify.cpp +containers\container.adaptors\queue\queue.defn\empty.verify.cpp +containers\container.adaptors\stack\stack.defn\empty.verify.cpp +containers\container.node\node_handle.nodiscard.verify.cpp +containers\sequences\array\empty.verify.cpp +containers\sequences\deque\deque.capacity\empty.verify.cpp +containers\sequences\forwardlist\empty.verify.cpp +containers\sequences\list\list.capacity\empty.verify.cpp +containers\sequences\vector.bool\empty.verify.cpp +containers\sequences\vector\vector.capacity\empty.verify.cpp +containers\sequences\vector\vector.cons\copy.move_only.verify.cpp +containers\unord\unord.map\empty.verify.cpp +containers\unord\unord.multimap\empty.verify.cpp +containers\unord\unord.multiset\empty.verify.cpp +containers\unord\unord.set\empty.verify.cpp +containers\views\span.cons\iterator_len.verify.cpp +containers\views\span.cons\iterator_sentinel.verify.cpp +containers\views\span.obs\empty.nodiscard.verify.cpp +depr\depr.atomics\depr.atomics.nonmembers\atomic_init.depr_in_cxx20.verify.cpp +depr\depr.lib.binders\depr.lib.bind.1st\bind1st.depr_in_cxx11.verify.cpp +depr\depr.lib.binders\depr.lib.bind.2nd\bind2nd.depr_in_cxx11.verify.cpp +depr\depr.lib.binders\depr.lib.binder.1st\binder1st.depr_in_cxx11.verify.cpp +depr\depr.lib.binders\depr.lib.binder.2nd\binder2nd.depr_in_cxx11.verify.cpp +input.output\filesystems\class.path\path.member\path.decompose\empty.verify.cpp +input.output\iostream.format\input.streams\istream.rvalue\not_istreamable.verify.cpp +input.output\iostream.format\output.streams\ostream.rvalue\not_ostreamable.verify.cpp +input.output\iostream.format\quoted.manip\quoted_char.verify.cpp +input.output\iostream.format\quoted.manip\quoted_traits.verify.cpp +iterators\iterator.container\empty.array.verify.cpp +iterators\iterator.container\empty.container.verify.cpp +iterators\iterator.container\empty.initializer_list.verify.cpp +iterators\iterator.primitives\iterator.basic\deprecated.verify.cpp +iterators\iterator.primitives\range.iter.ops\range.iter.ops.advance\constraints.verify.cpp +iterators\iterator.requirements\iterator.cust\iterator.cust.move\iter_move.nodiscard.verify.cpp +iterators\predef.iterators\move.iterators\move.iter.ops\move.iter.op.const\ctor.convert.LWG3435.verify.cpp +iterators\predef.iterators\move.iterators\move.iter.ops\move.iter.op.const\ctor.iter.explicit.verify.cpp +iterators\predef.iterators\move.iterators\move.iter.ops\move.iter.op=\assign.LWG3435.verify.cpp +iterators\predef.iterators\reverse.iterators\reverse.iter.cons\assign.LWG3435.verify.cpp +iterators\predef.iterators\reverse.iterators\reverse.iter.cons\ctor.iter.explicit.verify.cpp +iterators\predef.iterators\reverse.iterators\reverse.iter.cons\ctor.reverse_iterator.LWG3435.verify.cpp +language.support\cmp\cmp.alg\strong_order_long_double.verify.cpp +language.support\cmp\cmp.categories.pre\zero_type.verify.cpp +language.support\support.dynamic\new.delete\new.delete.array\new_size_align_nothrow.verify.cpp +language.support\support.dynamic\new.delete\new.delete.array\new_size_align.verify.cpp +language.support\support.dynamic\new.delete\new.delete.array\new_size_nothrow.verify.cpp +language.support\support.dynamic\new.delete\new.delete.array\new_size.verify.cpp +language.support\support.dynamic\new.delete\new.delete.placement\new_array_ptr.verify.cpp +language.support\support.dynamic\new.delete\new.delete.placement\new_ptr.verify.cpp +language.support\support.dynamic\new.delete\new.delete.single\new_size_align_nothrow.verify.cpp +language.support\support.dynamic\new.delete\new.delete.single\new_size_align.verify.cpp +language.support\support.dynamic\new.delete\new.delete.single\new_size_nothrow.verify.cpp +language.support\support.dynamic\new.delete\new.delete.single\new_size.verify.cpp +language.support\support.dynamic\ptr.launder\launder.nodiscard.verify.cpp +localization\locale.categories\category.ctype\locale.codecvt.byname\codecvt_byname_char16_t_char.depr_in_cxx20.verify.cpp +localization\locale.categories\category.ctype\locale.codecvt.byname\codecvt_byname_char32_t_char.depr_in_cxx20.verify.cpp +localization\locale.categories\category.ctype\locale.codecvt\codecvt_char16_t_char.depr_in_cxx20.verify.cpp +localization\locale.categories\category.ctype\locale.codecvt\codecvt_char32_t_char.depr_in_cxx20.verify.cpp +numerics\c.math\abs.verify.cpp +numerics\numbers\illformed.verify.cpp +ranges\range.adaptors\range.join.view\ctad.verify.cpp +re\re.results\re.results.size\empty.verify.cpp +strings\basic.string.literals\literal.verify.cpp +strings\basic.string\string.capacity\empty.verify.cpp +strings\basic.string\string.capacity\reserve.deprecated_in_cxx20.verify.cpp +strings\string.view\string_view.literals\literal.verify.cpp +strings\string.view\string.view.capacity\empty.verify.cpp +thread\futures\futures.async\async.verify.cpp +thread\futures\futures.promise\copy_assign.verify.cpp +thread\futures\futures.promise\copy_ctor.verify.cpp +thread\futures\futures.unique_future\copy_assign.verify.cpp +thread\futures\futures.unique_future\copy_ctor.verify.cpp +utilities\allocator.adaptor\allocator.adaptor.members\allocate_size_hint.verify.cpp +utilities\allocator.adaptor\allocator.adaptor.members\allocate_size.verify.cpp +utilities\any\any.nonmembers\any.cast\const_correctness.verify.cpp +utilities\any\any.nonmembers\any.cast\not_copy_constructible.verify.cpp +utilities\format\format.formatter\format.parse.ctx\check_arg_id.verify.cpp +utilities\function.objects\func.bind_front\bind_front.verify.cpp +utilities\function.objects\func.wrap\func.wrap.func\func.wrap.func.con\alloc_F.verify.cpp +utilities\function.objects\func.wrap\func.wrap.func\func.wrap.func.con\alloc_function.verify.cpp +utilities\function.objects\func.wrap\func.wrap.func\func.wrap.func.con\alloc_nullptr.verify.cpp +utilities\function.objects\func.wrap\func.wrap.func\func.wrap.func.con\alloc_rfunction.verify.cpp +utilities\function.objects\func.wrap\func.wrap.func\func.wrap.func.con\alloc.verify.cpp +utilities\function.objects\negators\binary_negate.depr_in_cxx17.verify.cpp +utilities\function.objects\negators\not1.depr_in_cxx17.verify.cpp +utilities\function.objects\negators\not2.depr_in_cxx17.verify.cpp +utilities\function.objects\negators\unary_negate.depr_in_cxx17.verify.cpp +utilities\memory\allocator.traits\allocator.traits.members\allocate.verify.cpp +utilities\memory\default.allocator\allocator_types.deprecated_in_cxx17.verify.cpp +utilities\memory\default.allocator\allocator_types.removed_in_cxx20.verify.cpp +utilities\memory\default.allocator\allocator.members\allocate.constexpr.size.verify.cpp +utilities\memory\default.allocator\allocator.members\allocate.verify.cpp +utilities\memory\pointer.conversion\to_address_on_funcptr.verify.cpp +utilities\memory\pointer.conversion\to_address_on_function.verify.cpp +utilities\memory\storage.iterator\deprecated.verify.cpp +utilities\meta\meta.trans\meta.trans.other\result_of.deprecated.verify.cpp +utilities\smartptr\unique.ptr\unique.ptr.class\unique.ptr.observers\dereference.verify.cpp +utilities\smartptr\unique.ptr\unique.ptr.class\unique.ptr.observers\op_arrow.verify.cpp +utilities\tuple\tuple.tuple\tuple.cnstr\default.lazy.verify.cpp +utilities\tuple\tuple.tuple\tuple.rel\size_incompatible_comparison.verify.cpp +utilities\utility\utility.underlying\to_underlying.verify.cpp + +# Contest does not understand .sh tests, which must be run specially +atomics\atomics.general\replace_failure_order_codegen.sh.cpp +containers\associative\map\PR28469_undefined_behavior_segfault.sh.cpp +input.output\iostream.objects\narrow.stream.objects\cerr.sh.cpp +input.output\iostream.objects\narrow.stream.objects\cin.sh.cpp +input.output\iostream.objects\narrow.stream.objects\clog.sh.cpp +input.output\iostream.objects\narrow.stream.objects\cout.sh.cpp +input.output\iostream.objects\wide.stream.objects\wcerr.sh.cpp +input.output\iostream.objects\wide.stream.objects\wcin.sh.cpp +input.output\iostream.objects\wide.stream.objects\wclog.sh.cpp +input.output\iostream.objects\wide.stream.objects\wcout.sh.cpp +namespace\addressable_functions.sh.cpp +strings\basic.string\string.capacity\shrink_to_fit.explicit_instantiation.sh.cpp +thread\thread.condition\thread.condition.condvarany\wait_terminates.sh.cpp +utilities\format\format.arguments\format.arg.store\make_format_args.sh.cpp diff --git a/tests/std/tests/P0645R10_text_formatting_death/test.cpp b/tests/std/tests/P0645R10_text_formatting_death/test.cpp index 86e74da603..e597f994cd 100644 --- a/tests/std/tests/P0645R10_text_formatting_death/test.cpp +++ b/tests/std/tests/P0645R10_text_formatting_death/test.cpp @@ -17,12 +17,17 @@ void test_case_advance_no_range() { context.advance_to(other_format_string.begin()); } +void test_case_zero_dynamic_width() { + (void) format("{:{}}", 42, 0); +} + int main(int argc, char* argv[]) { std_testing::death_test_executive exec; #if _ITERATOR_DEBUG_LEVEL != 0 exec.add_death_tests({ test_case_advance_no_range, + test_case_zero_dynamic_width, }); #endif // _ITERATOR_DEBUG_LEVEL != 0 diff --git a/tests/std/tests/P0896R4_views_counted/test.cpp b/tests/std/tests/P0896R4_views_counted/test.cpp index bd7b5e5e34..541dbaa00b 100644 --- a/tests/std/tests/P0896R4_views_counted/test.cpp +++ b/tests/std/tests/P0896R4_views_counted/test.cpp @@ -10,6 +10,14 @@ using namespace std; +// clang-format off +template +concept Countable = requires { typename iter_difference_t>; } + && requires(I&& i, iter_difference_t> n) { + views::counted(forward(i), n); + }; +// clang-format on + template struct convertible_difference { constexpr convertible_difference(const int _val_) noexcept : _val(_val_) {} @@ -31,6 +39,9 @@ struct instantiator { ranges::subrange; int input[] = {13, 42, 1729, -1, -1}; + STATIC_ASSERT(Countable); + STATIC_ASSERT(Countable == copy_constructible); + auto result = ranges::views::counted(Iter{input}, convertible_difference{3}); if constexpr (contiguous_iterator) { STATIC_ASSERT(same_as>, dynamic_extent>>); From b76b4fbad7066224b18931ec2c87ec5f291442f7 Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Thu, 10 Feb 2022 17:14:17 -0800 Subject: [PATCH 29/31] More review comments --- stl/inc/format | 6 +++--- stl/inc/iterator | 2 +- stl/inc/ranges | 2 +- tests/std/tests/P0896R4_views_iota/test.cpp | 22 +++++++++++---------- 4 files changed, 17 insertions(+), 15 deletions(-) diff --git a/stl/inc/format b/stl/inc/format index 63a3b226d4..99ae7b5d29 100644 --- a/stl/inc/format +++ b/stl/inc/format @@ -1130,10 +1130,10 @@ public: _NODISCARD constexpr unsigned long long operator()(const _Ty _Value) const { if constexpr (is_integral_v<_Ty>) { bool _Positive; - if constexpr (is_signed_v<_Ty>) { - _Positive = _Value > 0; - } else { + if constexpr (same_as<_Ty, bool>) { // avoid "bool > 0", which triggers C4804 _Positive = _Value != 0; + } else { + _Positive = _Value > 0; } if (!_Positive) { diff --git a/stl/inc/iterator b/stl/inc/iterator index 9a66f7459b..76f4bb2467 100644 --- a/stl/inc/iterator +++ b/stl/inc/iterator @@ -177,7 +177,7 @@ _NODISCARD _CONSTEXPR20 insert_iterator<_Container> inserter(_Container& _Cont, } #else // ^^^ No Ranges / Ranges vvv template -_NODISCARD _CONSTEXPR20 insert_iterator<_Container> inserter(_Container& _Cont, _RANGES iterator_t<_Container> _Where) { +_NODISCARD constexpr insert_iterator<_Container> inserter(_Container& _Cont, _RANGES iterator_t<_Container> _Where) { return insert_iterator<_Container>(_Cont, _Where); } diff --git a/stl/inc/ranges b/stl/inc/ranges index 480d65ea2f..0e8e1f97e5 100644 --- a/stl/inc/ranges +++ b/stl/inc/ranges @@ -3450,10 +3450,10 @@ namespace ranges { inline constexpr _Join_fn join; } // namespace views - // clang-format off template // _Require_constant is a valid template-id iff E is a constant expression of structural type struct _Require_constant; + // clang-format off template concept _Tiny_range = sized_range<_Ty> && requires { typename _Require_constant::size()>; } diff --git a/tests/std/tests/P0896R4_views_iota/test.cpp b/tests/std/tests/P0896R4_views_iota/test.cpp index 59429f76c8..ca83946879 100644 --- a/tests/std/tests/P0896R4_views_iota/test.cpp +++ b/tests/std/tests/P0896R4_views_iota/test.cpp @@ -3,9 +3,9 @@ #include #include +#include #include #include -#include #include #include #include @@ -248,7 +248,7 @@ constexpr void test_one_difference() { conditional_t= sizeof(int), long long, int>>; static_assert(same_as); static_assert(noexcept(r.end() - r.begin())); - const auto n = (Diff{1} << (numeric_limits::digits + (signed_integral ? 1 : 0))) - 1; + constexpr auto n = (Diff{1} << (numeric_limits::digits + (signed_integral ? 1 : 0))) - 1; assert(r.end() - r.begin() == n); // left > right assert(r.begin() - r.end() == -n); // right > left } @@ -264,26 +264,28 @@ constexpr bool test_difference() { test_one_difference(); test_one_difference(); - // signed integer-like, sizeof <= sizeof(W) < sizeof(long long) + // signed integer-like, sizeof(int) <= sizeof(W) < sizeof(long long) test_one_difference(); + test_one_difference(); - // unsigned integer-like, sizeof <= sizeof(W) < sizeof(long long) + // unsigned integer-like, sizeof(int) <= sizeof(W) < sizeof(long long) test_one_difference(); + test_one_difference(); - // signed integer-like, sizeof <= sizeof(W) + // signed integer-like, sizeof(long long) <= sizeof(W) test_one_difference(); - // unsigned integer-like, sizeof <= sizeof(W) + // unsigned integer-like, sizeof(long long) <= sizeof(W) test_one_difference(); // non-integer-like { - char* some_chars = new char[1ull << 24]; - ranges::iota_view r{&some_chars[0], &some_chars[1ull << 24]}; - using Diff = ptrdiff_t; + using Diff = ptrdiff_t; + constexpr Diff n = 128 * 1024; + char* some_chars = new char[n]; + ranges::iota_view r{some_chars + 0, some_chars + n}; static_assert(same_as); static_assert(noexcept(r.end() - r.begin())); - const auto n = Diff{1} << 24; assert(r.end() - r.begin() == n); // left > right assert(r.begin() - r.end() == -n); // right > left delete[] some_chars; From 4cb99acfeb28ef39aa517eb02dc4159966970f32 Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Wed, 16 Feb 2022 19:02:01 -0800 Subject: [PATCH 30/31] Charlie's comments --- stl/inc/format | 10 ++-------- stl/inc/xutility | 17 +++++++++-------- 2 files changed, 11 insertions(+), 16 deletions(-) diff --git a/stl/inc/format b/stl/inc/format index 76651bc8c8..4e08ecd2ff 100644 --- a/stl/inc/format +++ b/stl/inc/format @@ -1129,14 +1129,8 @@ public: template _NODISCARD constexpr unsigned long long operator()(const _Ty _Value) const { if constexpr (is_integral_v<_Ty>) { - bool _Positive; - if constexpr (same_as<_Ty, bool>) { // avoid "bool > 0", which triggers C4804 - _Positive = _Value != 0; - } else { - _Positive = _Value > 0; - } - - if (!_Positive) { +#pragma warning(suppress : 4804) // '>': unsafe use of type 'bool' in operation + if (!(_Value > 0)) { _THROW(format_error("width is not positive.")); } return static_cast(_Value); diff --git a/stl/inc/xutility b/stl/inc/xutility index 087798d9e9..310e5efabb 100644 --- a/stl/inc/xutility +++ b/stl/inc/xutility @@ -799,16 +799,17 @@ _NODISCARD constexpr auto _To_signed_like(const _Ty _Value) noexcept { // clang-format off template -concept weakly_incrementable = movable<_Ty> && requires(_Ty __i) { - typename iter_difference_t<_Ty>; - requires _Signed_integer_like>; - { ++__i } -> same_as<_Ty&>; - __i++; -} +concept weakly_incrementable = movable<_Ty> + && requires(_Ty __i) { + typename iter_difference_t<_Ty>; + requires _Signed_integer_like>; + { ++__i } -> same_as<_Ty&>; + __i++; + } #ifdef __clang__ // TRANSITION, LLVM-48173 -&& !same_as<_Ty, bool> + && !same_as<_Ty, bool> #endif // TRANSITION, LLVM-48173 -; + ; template concept incrementable = regular<_Ty> && weakly_incrementable<_Ty> && requires(_Ty __t) { From 1494fb14821098441bacc5a5d3efbfd5493974f1 Mon Sep 17 00:00:00 2001 From: Casey Carter Date: Wed, 16 Feb 2022 19:20:17 -0800 Subject: [PATCH 31/31] Revert warning suppression --- stl/inc/format | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/stl/inc/format b/stl/inc/format index 4e08ecd2ff..76651bc8c8 100644 --- a/stl/inc/format +++ b/stl/inc/format @@ -1129,8 +1129,14 @@ public: template _NODISCARD constexpr unsigned long long operator()(const _Ty _Value) const { if constexpr (is_integral_v<_Ty>) { -#pragma warning(suppress : 4804) // '>': unsafe use of type 'bool' in operation - if (!(_Value > 0)) { + bool _Positive; + if constexpr (same_as<_Ty, bool>) { // avoid "bool > 0", which triggers C4804 + _Positive = _Value != 0; + } else { + _Positive = _Value > 0; + } + + if (!_Positive) { _THROW(format_error("width is not positive.")); } return static_cast(_Value);