Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

What is a virtual destructor?

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


Please Help Members By Posting Answers For Below Questions

What are the two types of comments, and how do they differ?

1069


Discussion on error handling of C++ .

1085


What is switch case in c++ syntax?

1073


How much do c++ programmers make?

1075


Explain virtual destructor?

1133


What is endianness?

1051


You have two pairs: new() and delete() and another pair : alloc() and free(). Explain differences between eg. New() and malloc()

1105


What can I use instead of namespace std?

1093


Write a program using display() function which takes two arguments.

1022


If all is successful, what should main return a) 0 b) 1 c) void

985


How do we implement inheritance in c++?

1092


Does c++ cost money?

963


How do you traverse a btree in backward in-order?

993


Who was the creator of c++?

1010


Can we make any program in c++ without using any header file and what is the shortest program in c++.

1089