[Bug c/11751] wrong evaluation order of an expression

d_picco at hotmail dot com gcc-bugzilla@gcc.gnu.org
Thu Feb 24 13:41:00 GMT 2005


------- Additional Comments From d_picco at hotmail dot com  2005-02-23 23:27 -------
I won't press the issue further because I have other things more pressing ;)

But I think the decision to not change the behaviour here is wrong.  I cannot
create an Integer class that acts as an int due to the operator++.  Just because
it is undefined does not mean that we have to arbitrarily have to choose a
method that adds no value over one that adds good value.  Nearly all other
compiler vendors have adopted this method since it has an element of
common-sense in the face of an undefined process.  I get the feeling that the
only reason it isn't changed is simply because no-one wants to do it.  If there
is another reason, what is it?  

-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11751



More information about the Gcc-bugs mailing list