When virtual destructor is not needed even there is a virtual function, Why ?

Posted by skydoor on Stack Overflow See other posts from Stack Overflow or by skydoor
Published on 2010-03-19T21:14:40Z Indexed on 2010/03/19 21:21 UTC
Read the original article Hit count: 108

Filed under:

It says that if there is a virtual function, it is a good practice to have a virtual destructor. However, if the object is created on the stack but not on heap, do we still need to do that?

Regards,

© Stack Overflow or respective owner

Related posts about c++