This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: STL vector
- From: John Love-Jensen <eljay at adobe dot com>
- To: Mws <mws at twisted-brains dot org>, MSX to GCC <gcc-help at gcc dot gnu dot org>
- Date: Mon, 31 Oct 2005 06:17:01 -0500
- Subject: Re: STL vector
Hi marcel,
Doing a pop_back on an empty std::vector has undefined effect.
Probably a safe bet that whatever the undefined effect, it isn't a desirable
effect.
The size method can be called before the pop_back, to assure that there is
something to pop.
HTH,
--Eljay