Skip to content
Closed
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: 1 addition & 1 deletion stl/inc/__msvc_int128.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -319,7 +319,7 @@ struct
}

#if _HAS_CXX20
_NODISCARD_FRIEND constexpr bool operator==(const _Base128&, const _Base128&) noexcept = default;
_NODISCARD_FRIEND constexpr bool operator==(const _Base128&, const _Base128&) = default;
#else // ^^^ _HAS_CXX20 / !_HAS_CXX20 vvv
_NODISCARD_FRIEND constexpr bool operator==(const _Base128& _Left, const _Base128& _Right) noexcept {
return _Left._Word[0] == _Right._Word[0] && _Left._Word[1] == _Right._Word[1];
Expand Down
4 changes: 2 additions & 2 deletions stl/inc/__msvc_tzdb.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -125,9 +125,9 @@ class _Crt_allocator {
using propagate_on_container_move_assignment = true_type;
using is_always_equal = true_type;

constexpr _Crt_allocator() noexcept = default;
constexpr _Crt_allocator() = default;

constexpr _Crt_allocator(const _Crt_allocator&) noexcept = default;
constexpr _Crt_allocator(const _Crt_allocator&) = default;
template <class _Other>
constexpr _Crt_allocator(const _Crt_allocator<_Other>&) noexcept {}

Expand Down
4 changes: 2 additions & 2 deletions stl/inc/atomic
Original file line number Diff line number Diff line change
Expand Up @@ -2357,7 +2357,7 @@ public:
}
}

atomic_ref(const atomic_ref&) noexcept = default;
atomic_ref(const atomic_ref&) = default;

atomic_ref& operator=(const atomic_ref&) = delete;

Expand Down Expand Up @@ -2848,7 +2848,7 @@ _EXPORT_STD struct atomic_flag { // flag with test-and-set semantics
_Storage.store(false, _Order);
}

constexpr atomic_flag() noexcept = default;
constexpr atomic_flag() = default;

#if _HAS_CXX20
void wait(const bool _Expected, const memory_order _Order = memory_order_seq_cst) const noexcept {
Expand Down
6 changes: 3 additions & 3 deletions stl/inc/compare
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ _EXPORT_STD struct partial_ordering {
return _Val._Value == 0;
}

_NODISCARD_FRIEND constexpr bool operator==(partial_ordering, partial_ordering) noexcept = default;
_NODISCARD_FRIEND constexpr bool operator==(partial_ordering, partial_ordering) = default;

_NODISCARD_FRIEND constexpr bool operator<(const partial_ordering _Val, _Literal_zero) noexcept {
return _Val._Value == static_cast<_Compare_t>(_Compare_ord::less);
Expand Down Expand Up @@ -114,7 +114,7 @@ _EXPORT_STD struct weak_ordering {
return _Val._Value == 0;
}

_NODISCARD_FRIEND constexpr bool operator==(weak_ordering, weak_ordering) noexcept = default;
_NODISCARD_FRIEND constexpr bool operator==(weak_ordering, weak_ordering) = default;

_NODISCARD_FRIEND constexpr bool operator<(const weak_ordering _Val, _Literal_zero) noexcept {
return _Val._Value < 0;
Expand Down Expand Up @@ -181,7 +181,7 @@ _EXPORT_STD struct strong_ordering {
return _Val._Value == 0;
}

_NODISCARD_FRIEND constexpr bool operator==(strong_ordering, strong_ordering) noexcept = default;
_NODISCARD_FRIEND constexpr bool operator==(strong_ordering, strong_ordering) = default;

_NODISCARD_FRIEND constexpr bool operator<(const strong_ordering _Val, _Literal_zero) noexcept {
return _Val._Value < 0;
Expand Down
6 changes: 3 additions & 3 deletions stl/inc/coroutine
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ struct coroutine_handle;

template <>
struct coroutine_handle<void> {
constexpr coroutine_handle() noexcept = default;
constexpr coroutine_handle() = default;
constexpr coroutine_handle(nullptr_t) noexcept {}

coroutine_handle& operator=(nullptr_t) noexcept {
Expand Down Expand Up @@ -95,7 +95,7 @@ private:

_EXPORT_STD template <class _Promise>
struct coroutine_handle {
constexpr coroutine_handle() noexcept = default;
constexpr coroutine_handle() = default;
constexpr coroutine_handle(nullptr_t) noexcept {}

_NODISCARD static coroutine_handle from_promise(_Promise& _Prom) noexcept { // strengthened
Expand Down Expand Up @@ -227,7 +227,7 @@ struct coroutine_handle<noop_coroutine_promise> {
}

private:
coroutine_handle() noexcept = default;
coroutine_handle() = default;

void* _Ptr = __builtin_coro_noop();
};
Expand Down
4 changes: 2 additions & 2 deletions stl/inc/exception
Original file line number Diff line number Diff line change
Expand Up @@ -336,7 +336,7 @@ public:
nested_exception() noexcept : _Exc(_STD current_exception()) {}

nested_exception(const nested_exception&) noexcept = default;
nested_exception& operator=(const nested_exception&) noexcept = default;
nested_exception& operator=(const nested_exception&) = default;
virtual ~nested_exception() noexcept {}

[[noreturn]] void rethrow_nested() const { // throw wrapped exception_ptr
Expand Down Expand Up @@ -399,7 +399,7 @@ void rethrow_if_nested(const _Ty&) = delete; // requires /GR option
_EXPORT_STD class bad_variant_access
: public exception { // exception for visit of a valueless variant or get<I> on a variant with index() != I
public:
bad_variant_access() noexcept = default;
bad_variant_access() = default;

_NODISCARD const char* __CLR_OR_THIS_CALL what() const noexcept override {
return "bad variant access";
Expand Down
4 changes: 2 additions & 2 deletions stl/inc/expected
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ public:
}

// clang-format off
expected(expected&&) requires
expected(expected&&) noexcept requires
is_trivially_move_constructible_v<_Ty> && is_trivially_move_constructible_v<_Err> = default;
// clang-format on

Expand Down Expand Up @@ -1185,7 +1185,7 @@ public:
}

// clang-format off
expected(expected&&) requires is_trivially_move_constructible_v<_Err> = default;
expected(expected&&) noexcept requires is_trivially_move_constructible_v<_Err> = default;
// clang-format on

template <class _Uty, class _UErr>
Expand Down
2 changes: 1 addition & 1 deletion stl/inc/experimental/filesystem
Original file line number Diff line number Diff line change
Expand Up @@ -1476,7 +1476,7 @@ public:
_Directory_iterator(const _Directory_iterator&) = default;
_Directory_iterator& operator=(const _Directory_iterator&) = default;

_Directory_iterator(_Directory_iterator&&) = default;
_Directory_iterator(_Directory_iterator&&) noexcept = default;
_Directory_iterator& operator=(_Directory_iterator&&) = default;

_NODISCARD const value_type& operator*() const {
Expand Down
2 changes: 1 addition & 1 deletion stl/inc/filesystem
Original file line number Diff line number Diff line change
Expand Up @@ -1413,7 +1413,7 @@ namespace filesystem {
: _Position(_Position_), _Element(_STD move(_Element_)), _Mypath(_Mypath_) {}

_Path_iterator(const _Path_iterator&) = default;
_Path_iterator(_Path_iterator&&) = default;
_Path_iterator(_Path_iterator&&) noexcept = default;
_Path_iterator& operator=(const _Path_iterator&) = default;
_Path_iterator& operator=(_Path_iterator&&) = default;

Expand Down
8 changes: 4 additions & 4 deletions stl/inc/format
Original file line number Diff line number Diff line change
Expand Up @@ -376,7 +376,7 @@ private:
_State_t _State = _Start;

public:
_NODISCARD constexpr bool operator==(const _GB11_LeftHand_regex&) const noexcept = default;
_NODISCARD constexpr bool operator==(const _GB11_LeftHand_regex&) const = default;

_NODISCARD constexpr bool _Match(
const _Grapheme_Break_property_values _Left_gbp, _Extended_Pictographic_property_values _Left_ExtPic) noexcept {
Expand Down Expand Up @@ -415,7 +415,7 @@ public:
return _WrappedIter == default_sentinel;
}

_NODISCARD constexpr bool operator==(const _Grapheme_break_property_iterator&) const noexcept = default;
_NODISCARD constexpr bool operator==(const _Grapheme_break_property_iterator&) const = default;

using difference_type = ptrdiff_t;
using value_type = iter_value_t<_Wrapped_iter_type>;
Expand Down Expand Up @@ -1906,7 +1906,7 @@ class _Format_arg_store<_Context> {};
_EXPORT_STD template <class _Context>
class basic_format_args {
public:
basic_format_args() noexcept = default;
basic_format_args() = default;

basic_format_args(const _Format_arg_store<_Context>&) noexcept {}

Expand Down Expand Up @@ -2981,7 +2981,7 @@ private:
_Grapheme_break_property_iterator<_CharT> _WrappedIter;

public:
_NODISCARD constexpr bool operator==(const _Measure_string_prefix_iterator_utf&) const noexcept = default;
_NODISCARD constexpr bool operator==(const _Measure_string_prefix_iterator_utf&) const = default;

_NODISCARD constexpr bool operator==(default_sentinel_t) const noexcept {
return _WrappedIter == default_sentinel;
Expand Down
6 changes: 3 additions & 3 deletions stl/inc/functional
Original file line number Diff line number Diff line change
Expand Up @@ -1367,7 +1367,7 @@ public:

_Move_only_function_data _Data;

_Move_only_function_base() noexcept = default; // leaves fields uninitialized
_Move_only_function_base() = default; // leaves fields uninitialized

_Move_only_function_base(_Move_only_function_base&& _Other) noexcept {
_Checked_move(_Data, _Other._Data);
Expand Down Expand Up @@ -1768,7 +1768,7 @@ public:
this->_Construct_with_null();
}

move_only_function(move_only_function&&) noexcept = default;
move_only_function(move_only_function&&) = default;

template <class _Fn, enable_if_t<_Enable_one_arg_constructor<_Fn>, int> = 0>
move_only_function(_Fn&& _Callable) {
Expand Down Expand Up @@ -1818,7 +1818,7 @@ public:
return *this;
}

move_only_function& operator=(move_only_function&& _Other) {
move_only_function& operator=(move_only_function&& _Other) noexcept(false) {
if (this != _STD addressof(_Other)) {
this->_Move_assign(_STD move(_Other));
}
Expand Down
2 changes: 1 addition & 1 deletion stl/inc/future
Original file line number Diff line number Diff line change
Expand Up @@ -1434,7 +1434,7 @@ public:
_STD terminate(); // Very Bad Things
}

_Fake_no_copy_callable_adapter(_Fake_no_copy_callable_adapter&& _Other) = default;
_Fake_no_copy_callable_adapter(_Fake_no_copy_callable_adapter&& _Other) = default;
_Fake_no_copy_callable_adapter& operator=(const _Fake_no_copy_callable_adapter&) = delete;
_Fake_no_copy_callable_adapter& operator=(_Fake_no_copy_callable_adapter&&) = delete;

Expand Down
4 changes: 2 additions & 2 deletions stl/inc/hash_map
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ namespace stdext {
return *this;
}

hash_map(hash_map&& _Right) : _Mybase(_STD move(_Right)) {}
hash_map(hash_map&& _Right) noexcept : _Mybase(_STD move(_Right)) {}

hash_map(hash_map&& _Right, const allocator_type& _Al) : _Mybase(_STD move(_Right), _Al) {}

Expand Down Expand Up @@ -356,7 +356,7 @@ namespace stdext {
return *this;
}

hash_multimap(hash_multimap&& _Right) : _Mybase(_STD move(_Right)) {}
hash_multimap(hash_multimap&& _Right) noexcept : _Mybase(_STD move(_Right)) {}

hash_multimap(hash_multimap&& _Right, const allocator_type& _Al) : _Mybase(_STD move(_Right), _Al) {}

Expand Down
4 changes: 2 additions & 2 deletions stl/inc/hash_set
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ namespace stdext {
return *this;
}

hash_set(hash_set&& _Right) : _Mybase(_STD move(_Right)) {}
hash_set(hash_set&& _Right) noexcept : _Mybase(_STD move(_Right)) {}

hash_set(hash_set&& _Right, const allocator_type& _Al) : _Mybase(_STD move(_Right), _Al) {}

Expand Down Expand Up @@ -286,7 +286,7 @@ namespace stdext {
return *this;
}

hash_multiset(hash_multiset&& _Right) : _Mybase(_STD move(_Right)) {}
hash_multiset(hash_multiset&& _Right) noexcept : _Mybase(_STD move(_Right)) {}

hash_multiset(hash_multiset&& _Right, const allocator_type& _Al) : _Mybase(_STD move(_Right), _Al) {}

Expand Down
4 changes: 2 additions & 2 deletions stl/inc/iterator
Original file line number Diff line number Diff line change
Expand Up @@ -616,7 +616,7 @@ public:
}

// clang-format off
constexpr _Variantish(_Variantish&&) requires is_trivially_move_constructible_v<_Ty1>
constexpr _Variantish(_Variantish&&) noexcept requires is_trivially_move_constructible_v<_Ty1>
&& is_trivially_move_constructible_v<_Ty2> = default;
// clang-format on

Expand Down Expand Up @@ -687,7 +687,7 @@ public:
}

// clang-format off
constexpr _Variantish& operator=(_Variantish&&) requires is_trivially_destructible_v<_Ty1>
constexpr _Variantish& operator=(_Variantish&&) noexcept requires is_trivially_destructible_v<_Ty1>
&& is_trivially_destructible_v<_Ty2>
&& is_trivially_move_constructible_v<_Ty1>
&& is_trivially_move_constructible_v<_Ty2>
Expand Down
2 changes: 1 addition & 1 deletion stl/inc/list
Original file line number Diff line number Diff line change
Expand Up @@ -894,7 +894,7 @@ public:
}
#endif // _HAS_CXX23 && defined(__cpp_lib_concepts)

list(list&& _Right) : _Mypair(_One_then_variadic_args_t{}, _STD move(_Right._Getal())) {
list(list&& _Right) noexcept : _Mypair(_One_then_variadic_args_t{}, _STD move(_Right._Getal())) {
_Alloc_sentinel_and_proxy();
_Swap_val(_Right);
}
Expand Down
4 changes: 2 additions & 2 deletions stl/inc/map
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ public:
return *this;
}

map(map&& _Right) : _Mybase(_STD move(_Right)) {}
map(map&& _Right) noexcept : _Mybase(_STD move(_Right)) {}

map(map&& _Right, const allocator_type& _Al) : _Mybase(_STD move(_Right), _Al) {}

Expand Down Expand Up @@ -539,7 +539,7 @@ public:
return *this;
}

multimap(multimap&& _Right) : _Mybase(_STD move(_Right)) {}
multimap(multimap&& _Right) noexcept : _Mybase(_STD move(_Right)) {}

multimap(multimap&& _Right, const allocator_type& _Al) : _Mybase(_STD move(_Right), _Al) {}

Expand Down
16 changes: 8 additions & 8 deletions stl/inc/memory
Original file line number Diff line number Diff line change
Expand Up @@ -1128,7 +1128,7 @@ private:
_Atomic_counter_t _Weaks = 1;

protected:
constexpr _Ref_count_base() noexcept = default; // non-atomic initializations
constexpr _Ref_count_base() = default; // non-atomic initializations

public:
_Ref_count_base(const _Ref_count_base&) = delete;
Expand Down Expand Up @@ -1325,7 +1325,7 @@ protected:
return _Ptr;
}

constexpr _Ptr_base() noexcept = default;
constexpr _Ptr_base() = default;

~_Ptr_base() = default;

Expand Down Expand Up @@ -1560,7 +1560,7 @@ public:
using weak_type = weak_ptr<_Ty>;
#endif // _HAS_CXX17

constexpr shared_ptr() noexcept = default;
constexpr shared_ptr() = default;

constexpr shared_ptr(nullptr_t) noexcept {} // construct empty shared_ptr

Expand Down Expand Up @@ -3153,7 +3153,7 @@ private:

_EXPORT_STD template <class _Ty>
struct default_delete { // default deleter for unique_ptr
constexpr default_delete() noexcept = default;
constexpr default_delete() = default;

template <class _Ty2, enable_if_t<is_convertible_v<_Ty2*, _Ty*>, int> = 0>
_CONSTEXPR23 default_delete(const default_delete<_Ty2>&) noexcept {}
Expand All @@ -3166,7 +3166,7 @@ struct default_delete { // default deleter for unique_ptr

template <class _Ty>
struct default_delete<_Ty[]> { // default deleter for unique_ptr to array of unknown size
constexpr default_delete() noexcept = default;
constexpr default_delete() = default;

template <class _Uty, enable_if_t<is_convertible_v<_Uty (*)[], _Ty (*)[]>, int> = 0>
_CONSTEXPR23 default_delete(const default_delete<_Uty[]>&) noexcept {}
Expand Down Expand Up @@ -3850,7 +3850,7 @@ template <class _Ty>
class alignas(2 * sizeof(void*)) _Atomic_ptr_base {
// overalignment is to allow potential future use of cmpxchg16b
protected:
constexpr _Atomic_ptr_base() noexcept = default;
constexpr _Atomic_ptr_base() = default;

_Atomic_ptr_base(remove_extent_t<_Ty>* const _Px, _Ref_count_base* const _Ref) noexcept
: _Ptr(_Px), _Repptr(_Ref) {}
Expand Down Expand Up @@ -3975,7 +3975,7 @@ public:
using _Base::notify_all;
using _Base::notify_one;

constexpr atomic() noexcept = default;
constexpr atomic() = default;

constexpr atomic(nullptr_t) noexcept : atomic() {}

Expand Down Expand Up @@ -4094,7 +4094,7 @@ public:
using _Base::notify_all;
using _Base::notify_one;

constexpr atomic() noexcept = default;
constexpr atomic() = default;

atomic(const weak_ptr<_Ty> _Value) noexcept : _Base(_Value._Ptr, _Value._Rep) {
_Value._Incwref();
Expand Down
2 changes: 1 addition & 1 deletion stl/inc/memory_resource
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ namespace pmr {

_STL_INTERNAL_STATIC_ASSERT(is_base_of_v<_Link_type, _Ty>);

constexpr _Intrusive_stack() noexcept = default;
constexpr _Intrusive_stack() = default;
constexpr _Intrusive_stack(_Intrusive_stack&& _That) noexcept : _Head{_That._Head} {
_That._Head = nullptr;
}
Expand Down
2 changes: 1 addition & 1 deletion stl/inc/mutex
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ class unique_lock { // whizzy class with destructor that unlocks mutex
public:
using mutex_type = _Mutex;

unique_lock() noexcept = default;
unique_lock() = default;

_NODISCARD_CTOR_LOCK explicit unique_lock(_Mutex& _Mtx)
: _Pmtx(_STD addressof(_Mtx)), _Owns(false) { // construct and lock
Expand Down
1 change: 0 additions & 1 deletion stl/inc/ostream
Original file line number Diff line number Diff line change
Expand Up @@ -865,7 +865,6 @@ basic_ostream<_Elem, _Traits>& operator<<(basic_ostream<_Elem, _Traits>& _Ostr,
if (_State == ios_base::goodbit && _Ostr.rdbuf()->sputn(_Val, _Count) != _Count) {
_State |= ios_base::badbit;
}

if (_State == ios_base::goodbit) {
for (; 0 < _Pad; --_Pad) { // pad on right
if (_Traits::eq_int_type(_Traits::eof(), _Ostr.rdbuf()->sputc(_Ostr.fill()))) {
Expand Down
Loading