It is about what the example shows. In sum, these are those conversions
- The function parameter can be a
Base<T>
, while the function argument is a Derived<T>
. Compare with ifstream << "hello"
- left side of operator<<
is deduced in that way.
- The function parameter can be a
const U&
, while the function argument is a U
(same for volatile).
- The function parameter can be a
const U*
or const E C::*
while the function argument is a U*
or E C::*
respectively (these are the qualification conversions) - same for volatile.
Other conversions cannot be done for a function parameter / argument that participate in deduction. The whole range of conversions can be applied if a function parameter does not participate in deduction, but this needs a non-deduced context or a context where there is no argument to be deduced at all, and implementation don't actually agree on it (see here).
In other words:
template<typename T> struct id { typedef T type; };
template<typename T> void f(T, typename id<T>::type);
int main() {
// deduction acts on void(int*, int*) - deduction does not need
// to deduce anything and follows [temp.arg.explicit]p4
f<int*>(0, 0);
// deduction acts on void(T, id<T>::type) - second is a non-deduced context,
// which *will* allow the conversion of int -> int*, since it will not compare
// the argument with parameter during deduction (since it is non-deduced).
f((int*)0, 0);
}
The second example is vital for some partial ordering contexts to work.