复制构造函数, 赋值操作符 operator = ,析构函数 总称为复制控制 (Copy Control)e.g.:Code:#include <iostream>using namespace std;class T{public: T(){ cout<<"T constructor."<<endl; } T(const T& tobj){ cout<<" T copy construct from T:"<<&tobj<<endl; t=tobj.t; } //若 Read More
posted @ 2011-03-02 14:33 庚武 Views(195) Comments(0) Diggs(0) Edit