Open
Description
template<template<class T> class> struct A {};
template<class T> struct Q {};
template<class T> using R = Q<T>;
int f(A<R>);
int g(A<Q> a) { return f(a); }
GCC accepts (since 4.9.0), Clang rejects with:
<source>:5:24: error: no matching function for call to 'f'
int g(A<Q> a) { return f(a); }
^
<source>:4:5: note: candidate function not viable: no known conversion from 'A<template Q>' to 'A<template R>' for 1st argument
int f(A<R>);
^
-frelaxed-template-template-args
doesn't seem to help in any recent major.