摘要:
默认情况下,C++的函数调用是传值调用,也就是说形参拷贝实参的内容。举书上的例子: 1 class Person 2 { 3 private: 4 string name; 5 string address; 6 public: 7 Person(){} 8 virtual ~Person(){} 9 };10 11 class Student: public Person12 {13 private:14 string schoolName;15 string schoolAddress;16 public:17 Student(){}... 阅读全文