c++ primer exercise 15.26
Hello everybody! :)
This is my first post here so I hope that all will be ok, otherwise please be patients ;)
I've trouble defining the copy-control move assignment of a derived class, it should be trivial however I don't know how to call the base class move assignment (should I?) the code I wrote is here.
The concerned part is:
Code:
// Move assignment
Bulk_quote& Bulk_quote::operator=(Bulk_quote&& q) noexcept
{
if(this != &q)
{
*this=Quote::operator=(q); // <---- !!!???
min_qty=q.min_qty; discount=q.discount;
cout << "Class: " << (typeid(*this).name()) << ", Move assigment" << endl;
}
return *this;
}
Could anybody give me some hints? Thank in advance