https://bugs.llvm.org/show_bug.cgi?id=43459
Bug ID: 43459
Summary: templated constexpr constant in a template fails to
deduce auto type
Product: clang
Version: 9.0
Hardware: All
OS: All
Status: NEW
Severity: normal
Priority: P
Component: C++17
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected], [email protected],
[email protected], [email protected]
The following code compiled on clang 8 and is now wrong in clang 9.
See: https://godbolt.org/z/WdLl4c
template<class>
struct Template {
template<typename>
static constexpr auto type_v = 0;
};
using T = Template<int>;
static_assert(T::type_v<int> == 0);
error: invalid operands to binary expression ('const auto' and 'int')
It seems the 'const auto' was never resolved to the real type.
--
You are receiving this mail because:
You are on the CC list for the bug._______________________________________________
llvm-bugs mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs