On 02/03/2012 05:31 PM, Michael Stahl wrote:
ah, that's surprising.

that's shocking ;)

see, that is why i almost always write the i++ as an extra statement,
i'm never quite exactly sure what it does, and when  :)

There is a sequence point (in C++03 parlance; the nomenclature changed slightly for C++11) after evaluation of all function arguments, before any statements of the function body are executed. Therefore, erase(i++) fully executes i++ before calling erase (with the old value of i).

Stephan
_______________________________________________
LibreOffice mailing list
LibreOffice@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice

Reply via email to