When we use an overloaded operator, the call does not tell us anything about the scope of the operator function that is being used.Therefore, both member and nonmember versions must be considered.

  • 使用重载操作符是时,调用本身不会告诉我们与使用的操作符函数作用域相关的任何事情,因此,成员和非成员版本都必须考虑。
目录 查词历史