This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Is this a bug?


Songtao Chen wrote:-

> Hi Neil,
> 
> Thanks for replying.
> 
> Can you tell me why the parentheses are irrelevant,
> any doc to support that?

For the same reason that (2) is the same as 2, and not 3.  Like I said,
post-increment returns the value before incrementing.

Neil.

> 
> Songtao
> 
> At 09:23 PM 1/2/2003 +0000, Neil Booth wrote:
> >Songtao Chen wrote:-
> >
> >> Hi there,
> >>
> >> It appears to be a bug to me.
> >
> >No, i++ returns the value before increment.  Parentheses are irrelevant.
> >
> >Neil.
> 


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]