I'm not entirely sure about your statement about "the result of an expression is not affected by the context". For example, there is argument dependent lookup where function name lookup is expanded to the namespaces of the arguments. And, in the case presented, a specific hypothetical overload of
operator+()
could be chosen to yield the argument type required by std::copy
.