c++ - STL containers element destruction order -
does iso c++ standard mandate sort of destruction order of objects inside stl containers?
- are
std::list/std::vector/std::mapelements destroyed starting beginning or end of container? - can rely on
std::mapstoring elements instd::pairs internally key in pair destroyed before value (or vice versa)?
- unspecified in standard.
- yes, means key destroyed after associated value.
Comments
Post a Comment