Strengthen exception specifications for [thread] types #3388
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #3324. Towards #363.
These functions are made
noexcept
._Mutex_base::try_lock
(i.e.mutex::try_lock
) (analysis:<mutex>
: Is_Mutex_base::try_lock
actuallynoexcept
? #3324 (comment))notify_all_at_thread_exit
condition_variable
's default constructor,native_handle
, andwait
recursive_mutex
's default constructoradopt_lock_t
constructorsAlso make some special member functions defaulted.
thread::id
's default constructorunique_lock
's default constructorscoped_lock<>
's default constructor and destructor, also strengthening exception specificationtimed_mutex
,recursive_timed_mutex
, andshared_timed_mutex
's default constructors, keeping exception specification strengthened (some comments were missing before, although IMO we don't need to add back now)Comment changes:
timed_mutex::try_lock
isn't markednoexcept
in working draft ([thread.timedmutex.class]). So this PR adds the missing/* strengthened */
comment.