Answer Posted / munendra kumar
The simple answer is that a virtual destructor is one that is declared with the virtual attribute.
The behavior of a virtual destructor is what is important. If you destroy an object through a pointer or reference to a base class, and the base-class destructor is not virtual, the derived-class destructors are not executed, and the destruction might not be complete.
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Why iomanip is used in c++?
What is the latest c++ version?
How can I learn c++ easily?
What is setf in c++?
How do I run a program in notepad ++?
What is the use of 'this' pointer?
What is stl containers in c++?
What is the difference between a declaration and a definition?
What is a local variable?
How do you find out if a linked-list has an end? (I.e. The list is not a cycle)
What are the four partitions in which c++ compiler divides the ram?
What do you mean by ‘void’ return type?
What is a namespace in c++?
What are the various operations performed on stack?
What do you mean by inheritance in c++?