Monday, November 8, 2010

Post-increment Operators

In general, a compiler cannot optimize postincrement to inhibit the creation of a temporary.

It can optimize it for a built-in type, but it is not allowed to try and optimize it for a user-defined type.

Reference: Exceptional C++ by Herb Sutter. Addison-Wesley, 1999, p. 20.

No comments:

Post a Comment