How do you know that your class needs a virtual destructor?
Answer Posted / melos
If the class will be derived from and it will need a virtual
destructor so that the destructor of the derived class will
be invoked if it referenced using the pointer to the base class.
| Is This Answer Correct ? | 1 Yes | 1 No |
Post New Answer View All Answers
What is this pointer in c++?
Difference between pointer to constant vs. Pointer constant
How would you call C functions from C++ and vice versa?
Can create new c++ operators?
Why do we use string in c++?
Explain the register storage classes in c++.
What do you mean by vtable and vptr in c++?
What are namespaces in c++?
What is class invariant in c++?
Are php strings immutable?
Is it possible for a member function to use delete this?
What is the best c++ compiler?
What is the basic concept of c++?
Do class declarations end with a semicolon? Do class method definitions?
How does c++ sort work?