https://llvm.org/bugs/show_bug.cgi?id=30236
Bug ID: 30236
Summary: Fails deduction of parameter pack for pack of function
parameter types
Product: clang
Version: trunk
Hardware: PC
OS: Linux
Status: NEW
Severity: normal
Priority: P
Component: C++14
Assignee: [email protected]
Reporter: [email protected]
CC: [email protected]
Classification: Unclassified
template <typename... T>
void f( void(...t)(T) );
template <typename... T>
void g( void(t)(T) );
int main() {
void h(int);
f(h); // Error
g(h); // Ok?
}
This seems inconsistent, because the deduction of the pack T in the call to f
is done by performing deduction of void(T) against void(int), that is, the
deduction step necessary for the call to g (which succeeds).
The error message suggests that deduction is performed with the decayed type of
'g':
> could not match 'void (T)' against 'void (*)(int)'
Presumably it would succeed if A is left as 'void(int)'.
--
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
[email protected]
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs