Created on 2011-03-25.00:00:00 last changed 131 months ago
[Voted into the WP at the February, 2012 meeting; moved to DR at the October, 2012 meeting.]
Proposed resolution (August, 2011):
Change 13.2 [temp.param] paragraph 11 as follows:
...A template parameter pack of a function template shall not be followed by another template parameter unless that template parameter can be deduced from the parameter-type-list of the function template or has a default argument (13.10.3 [temp.deduct]). [Example:
template<class T1 = int, class T2> class B; // error // U cannot be deduced from the parameter-type-list or specified template<class... T, class... U> void f() { } // error template<class... T, class U> void g() { } // error—end example]
The following example from 13.2 [temp.param] paragraph 11 is incorrect:
// U cannot be deduced or specified template<class... T, class... U> void f() { } template<class... T, class U> void g() { }
In fact, U can be deduced to an empty sequence by 13.10.2 [temp.arg.explicit] paragraph 3:
A trailing template parameter pack (13.7.4 [temp.variadic]) not otherwise deduced will be deduced to an empty sequence of template arguments.
History | |||
---|---|---|---|
Date | User | Action | Args |
2014-03-03 00:00:00 | admin | set | status: drwp -> cd3 |
2012-11-03 00:00:00 | admin | set | status: dr -> drwp |
2012-09-24 00:00:00 | admin | set | messages: + msg4013 |
2012-02-27 00:00:00 | admin | set | messages: + msg3830 |
2012-02-27 00:00:00 | admin | set | status: ready -> dr |
2011-03-25 00:00:00 | admin | create |