A trailing template parameter pack (
[temp.variadic]) not otherwise deduced will be
deduced as an empty sequence of template arguments
. If all of the template arguments can be deduced, they may all be omitted;
in this case, the empty template argument list
<>
itself may also be omitted
. In contexts where deduction is done and fails, or in contexts where
deduction is not done, if a template argument list is specified and it,
along with any default template arguments, identifies a single function
template specialization, then the
template-id
is an lvalue for the function template specialization
. [
Example 2:
template<class X, class Y> X f(Y);
template<class X, class Y, class ... Z> X g(Y);
void h() {
int i = f<int>(5.6);
int j = f(5.6);
f<void>(f<int, bool>);
f<void>(f<int>);
int k = g<int>(5.6);
f<void>(g<int, bool>);
}
—
end example]