Section: 220.127.116.11 [thread.thread.constr], 18.104.22.168 [futures.task.members] Status: Tentatively Ready Submitter: Stephan T. Lavavej Opened: 2017-11-17 Last modified: 2017-11-29
Priority: Not Prioritized
View all other issues in [thread.thread.constr].
View all issues with Tentatively Ready status.
Following P0777R1 "Treating Unnecessary decay", more occurrences can be fixed. When constraints are checking for the same type as thread or a specialization of packaged_task, decaying functions to function pointers and arrays to object pointers can't affect the result.
[28-Nov-2017 Moved to Tentatively Ready after five positive votes on the ML.]
Wording relative to N4700.
Edit 22.214.171.124 [thread.thread.constr] as indicated:
template <class F, class... Args> explicit thread(F&& f, Args&&... args);
-3- Requires: […]-4- Remarks: This constructor shall not participate in overload resolution if
decay_t<F> is the same type as std::thread.
Edit 126.96.36.199 [futures.task.members] as indicated:
template <class F> packaged_task(F&& f);
-2- Requires: […]-3- Remarks: This constructor shall not participate in overload resolution if
decay_t<F> is the same type as packaged_task<R(ArgTypes...)>.