Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions stl/inc/memory
Original file line number Diff line number Diff line change
Expand Up @@ -1800,7 +1800,6 @@ template <class _Ty1, class _Ty2>
_NODISCARD strong_ordering operator<=>(const shared_ptr<_Ty1>& _Left, const shared_ptr<_Ty2>& _Right) noexcept {
return _Left.get() <=> _Right.get();
}

#else // ^^^ _HAS_CXX20 / !_HAS_CXX20 vvv
template <class _Ty1, class _Ty2>
_NODISCARD bool operator!=(const shared_ptr<_Ty1>& _Left, const shared_ptr<_Ty2>& _Right) noexcept {
Expand Down Expand Up @@ -1838,7 +1837,6 @@ template <class _Ty>
_NODISCARD strong_ordering operator<=>(const shared_ptr<_Ty>& _Left, nullptr_t) noexcept {
return _Left.get() <=> static_cast<typename shared_ptr<_Ty>::element_type*>(nullptr);
}

#else // ^^^ _HAS_CXX20 / !_HAS_CXX20 vvv
template <class _Ty>
_NODISCARD bool operator==(nullptr_t, const shared_ptr<_Ty>& _Right) noexcept {
Expand Down
3 changes: 2 additions & 1 deletion stl/inc/queue
Original file line number Diff line number Diff line change
Expand Up @@ -156,12 +156,13 @@ public:
friend bool operator> <>(const queue&, const queue&);
friend bool operator<= <>(const queue&, const queue&);
friend bool operator>= <>(const queue&, const queue&);
// clang-format on

#ifdef __cpp_lib_concepts
template <class _Ty2, three_way_comparable _Container2>
friend compare_three_way_result_t<_Container2> operator<=>(
const queue<_Ty2, _Container2>&, const queue<_Ty2, _Container2>&);
#endif // __cpp_lib_concepts
// clang-format on

protected:
_Container c{};
Expand Down
10 changes: 4 additions & 6 deletions stl/inc/scoped_allocator
Original file line number Diff line number Diff line change
Expand Up @@ -248,22 +248,20 @@ scoped_allocator_adaptor(_Outer, _Inner...) -> scoped_allocator_adaptor<_Outer,

template <class _Outer1, class _Outer2, class _Inner1, class... _Inner>
_NODISCARD bool operator==(const scoped_allocator_adaptor<_Outer1, _Inner1, _Inner...>& _Left,
const scoped_allocator_adaptor<_Outer2, _Inner1, _Inner...>&
_Right) noexcept { // compare scoped_allocator_adaptors for equality
const scoped_allocator_adaptor<_Outer2, _Inner1, _Inner...>& _Right) noexcept {
return _Left.outer_allocator() == _Right.outer_allocator() && _Left.inner_allocator() == _Right.inner_allocator();
}

template <class _Outer1, class _Outer2>
_NODISCARD bool operator==(const scoped_allocator_adaptor<_Outer1>& _Left,
const scoped_allocator_adaptor<_Outer2>& _Right) noexcept { // compare scoped_allocator_adaptors for equality
_NODISCARD bool operator==(
const scoped_allocator_adaptor<_Outer1>& _Left, const scoped_allocator_adaptor<_Outer2>& _Right) noexcept {
return _Left.outer_allocator() == _Right.outer_allocator();
}

#if !_HAS_CXX20
template <class _Outer1, class _Outer2, class... _Inner>
_NODISCARD bool operator!=(const scoped_allocator_adaptor<_Outer1, _Inner...>& _Left,
const scoped_allocator_adaptor<_Outer2, _Inner...>&
_Right) noexcept { // compare scoped_allocator_adaptors for equality
const scoped_allocator_adaptor<_Outer2, _Inner...>& _Right) noexcept {
return !(_Left == _Right);
}
#endif // !_HAS_CXX20
Expand Down
3 changes: 2 additions & 1 deletion stl/inc/stack
Original file line number Diff line number Diff line change
Expand Up @@ -146,12 +146,13 @@ public:
friend bool operator> <>(const stack&, const stack&);
friend bool operator<= <>(const stack&, const stack&);
friend bool operator>= <>(const stack&, const stack&);
// clang-format on

#ifdef __cpp_lib_concepts
template <class _Ty2, three_way_comparable _Container2>
friend compare_three_way_result_t<_Container2> operator<=>(
const stack<_Ty2, _Container2>&, const stack<_Ty2, _Container2>&);
#endif // __cpp_lib_concepts
// clang-format on

protected:
_Container c{};
Expand Down
3 changes: 3 additions & 0 deletions tests/tr1/expected_results.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,5 @@
# Copyright (c) Microsoft Corporation.
# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception

# TRANSITION, flaky test (see GH-1642 and GH-718)
tests/thread SKIPPED
2 changes: 1 addition & 1 deletion tests/tr1/test.lst
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ tests\string2
tests\strstream
tests\system_error

# TRANSITION, flaky test
# TRANSITION, flaky test (see GH-1642 and GH-718)
# tests\thread

tests\tuple
Expand Down