Title
Alias templates and template declaration matching
Status
drafting
Section
13.6 [temp.type]
Submitter
Richard Smith

Created on 2014-11-06.00:00:00 last changed 123 months ago

Messages

Date: 2014-11-06.00:00:00

For the following example,

  template<int N> struct A {};
  template<short N> using B = A<N>;
  template<int N> void f(B<N>) {} // #1
  template<int N> void f(A<N>) {} // #2

There is implementation variance as to whether there is one f or two. As with previously-discussed cases, these have different SFINAE effects, perhaps equivalent but not functionally equivalent. Should the argument to #1 be treated as something like A<(int)(short)N> and not just A<N>.

See also issues 1668 and 1979.

History
Date User Action Args
2014-11-06 00:00:00admincreate