Suppose there exists a type T
such that std::is_trivially_destructable<T>::value == true
, and suppose further that T
is the value type of some vector class. When the vector's destructor is called, or the vector is assigned to another vector, it must destroy and deallocate its current storage. As T
is trivially destructable, is it necessary that I call T
's destructor?
Thanks for your help!
See Question&Answers more detail:os