include "vector.h"{ Vector b(a); // calls copy-constructor, compiles and works fine
Vector c = a; // should call copy-constructor, but does not compile
而代码2中将出现3种情况:b) the copy-constructor copies the tmp to the location of the outside即the copy-constructor copies the tmp to the location of the outside return value.