Forums before death by AOL, social media and spammers... "We can't have nice things"
|    comp.lang.c++.moderated    |    Moderated discussion of C++ superhackery    |    33,346 messages    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
|    Message 32,891 of 33,346    |
|    =?ISO-8859-15?Q?Daniel_Kr=FCgler?= to All    |
|    Re: Order of destruction of vector eleme    |
|    04 Mar 13 22:06:05    |
      From: daniel.kruegler@googlemail.com              Am 04.03.2013 23:14, schrieb Frank Birbacher:       > Is there a defined order of destruction for the elements of std       > containers, such as a vector?       >       > I have a problem where I'd like the "reverse" order for destruction,       > that is from back() to front(). That would correspond to the usual       > "reverse order of construction" as is known with class members.              C++03 did not specify the order of the destruction of the elements of       containers. As an (unintended) side-effect of wording changes during       C++11 development, the wording can now be interpreted to require reverse       destruction order, see              http://www.open-std.org/jtc1/sc22/wg21/docs/lwg-active.html#2160              for some more details.              It needs to be decided whether the current state is intended or whether       it would be better to keep the order unspecified as before.              HTH & Greetings from Bremen,              Daniel Krügler                     --        [ See http://www.gotw.ca/resources/clcm.htm for info about ]        [ comp.lang.c++.moderated. First time posters: Do this! ]              --- SoupGate-Win32 v1.05        * Origin: you cannot sedate... all the things you hate (1:229/2)    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
(c) 1994, bbs@darkrealms.ca