[llvm-bugs] [Bug 41591] New: LWG 3062 Unnecessary decay_t in is_execution_policy_v should be remove_cvref_t
via llvm-bugs
llvm-bugs at lists.llvm.org
Wed Apr 24 14:07:47 PDT 2019
https://bugs.llvm.org/show_bug.cgi?id=41591
Bug ID: 41591
Summary: LWG 3062 Unnecessary decay_t in is_execution_policy_v
should be remove_cvref_t
Product: parallel STL
Version: unspecified
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: P
Component: New
Assignee: ldionne at apple.com
Reporter: zilla at kayari.org
CC: llvm-bugs at lists.llvm.org
https://cplusplus.github.io/LWG/issue3062 says to replace std::decay with
std::remove_cvref, which means in the __enable_if_execution_policy helper in
pstl/execution_defs.h:
namespace __internal
{
template <class ExecPolicy, class T>
using __enable_if_execution_policy =
typename std::enable_if<__pstl::execution::is_execution_policy<typename
std::remove_reference<ExecPolicy>::type>::value,
T>::type;
} // namespace __internal
As remove_cvref is only available since C++2a it might have to be typename
remove_cv<typename remove_reference<ExecPolicy>::type>::type instead, but that
should still be more efficient to compile than std::decay.
--
You are receiving this mail because:
You are on the CC list for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-bugs/attachments/20190424/1c60f0c2/attachment.html>
More information about the llvm-bugs
mailing list