https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83542

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Last reconfirmed|2018-02-17 00:00:00         |2021-8-23

--- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
clang started to reject it in 7:
<source>:14:5: error: no matching function for call to 'foo'
    foo(list<int>{}, list<int>{}, &f);
    ^~~
<source>:6:6: note: candidate template ignored: deduced packs of different
lengths for parameter 'T' (<int> vs. <>)
void foo(list<T...>, list<U...>, void(*)(T..., U...))
     ^

MSVC also rejects it:

<source>(14): error C2672: 'foo': no matching overloaded function found
<source>(14): error C2784: 'void foo(list<T...>,list<U...>,void (__cdecl
*)(T...,U...))': could not deduce template argument for 'void (__cdecl
*)(T...,U...)' from 'void (__cdecl *)(int,int)'
<source>(6): note: see declaration of 'foo'

Reply via email to