When calling the constructor with a default constructor argument no object gets constructed.
class cl{
private:
public:
cl(){cout << "Default used" << endl;};
cl(const cl & cl_object) {cout << "Copy used" << endl;};
cl & operator=(const cl & cl_object){cout << "Assignment used" << endl; return *this;};
};
When I write:
cl(cl());
no message gets displayed.
Questions: 1) Why no object is constructed ? 2) Why the copy constructor is not used ?