Is always passing by reference a bad practice?
This question already has an answer here:
One common style is to pass input arguments by const reference, and output arguments by pointer. In this style, we don't pass output arguments by non-const reference to more clearly delineate input from output arguments.
链接地址: http://www.djcxy.com/p/20722.html上一篇: 指针和参考参数之间的区别?
下一篇: 总是通过引用传递一个不好的做法?