--- Comment #15 from manu at gcc dot gnu dot org 2008-08-29 00:08 ---
Fixed in GCC 4.4
Thanks for the report.
--
manu at gcc dot gnu dot org changed:
What|Removed |Added
--- Comment #14 from manu at gcc dot gnu dot org 2008-08-29 00:07 ---
Subject: Bug 18050
Author: manu
Date: Fri Aug 29 00:06:19 2008
New Revision: 139742
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=139742
Log:
2008-08-28 Manuel Lopez-Ibanez <[EMAIL PROTECTED]>
A
--- Comment #13 from manu at gcc dot gnu dot org 2008-08-28 01:30 ---
(In reply to comment #12)
>
> I think we are still warning in too many places but I can't remember now, it
> was almost 4 years ago and many stuff has changed.
Do you mind if I test it and try to make it work? For th
--- Comment #12 from pinskia at gcc dot gnu dot org 2008-08-28 01:22
---
(In reply to comment #11)
> Andrew, your patch seems to work, so what is the problem?
I think we are still warning in too many places but I can't remember now, it
was almost 4 years ago and many stuff has changed.
--- Comment #11 from manu at gcc dot gnu dot org 2008-08-28 01:18 ---
Andrew, your patch seems to work, so what is the problem?
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=18050
--- Comment #10 from pinskia at gcc dot gnu dot org 2008-08-27 19:44
---
*** Bug 37259 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
-
--- Comment #9 from schwab at suse dot de 2006-03-22 13:08 ---
(In reply to comment #8)
> i = (i += 1);
>
> where for i += 1 the next sequence point is the i = ... assigment?
The next sequence point is the semicolon.
> Of course for the particular testcase the ordering of the two sto
--- Comment #8 from rguenth at gcc dot gnu dot org 2006-03-22 12:53 ---
Sure - but this doesn't matter in this case. And
6.5.3.1 tells you
"The expression ++E is equivalent to (E+=1)."
6.5.16 says
"The side effect of updating the stored value of the left operand shall
occur betw
--- Comment #7 from joseph at codesourcery dot com 2006-03-22 12:26 ---
Subject: Re: -Wsequence-point reports false positives
On Wed, 22 Mar 2006, rguenth at gcc dot gnu dot org wrote:
> i = ++i;
Modified twice between sequence points, so undefined behavior.
> I think the point is
--- Comment #6 from rguenth at gcc dot gnu dot org 2006-03-22 12:19 ---
Another one:
int foo(int i)
{
i = ++i;
return i;
}
I think the point is we should not warn for pre-increment, only post-increment.
Or can someone come up with a testcase that has undefined evaluation order just
--- Additional Comments From pinskia at gcc dot gnu dot org 2004-10-18 22:45
---
Actually the patch will not work when we start warning about full expression, here is
the patch just to
give an example of what the final patch would look like:
Index: c-common.c
==
--- Additional Comments From pinskia at gcc dot gnu dot org 2004-10-18 22:35
---
We cannot just ignore ADDR_EXPR outright though (this is undefined):
struct x
{
int i;
};
void g(struct x*, int *);
void f(struct x *y)
{
g(y++, &y->i);
}
I think I have a fix will test the fix.
--
--- Additional Comments From pinskia at gcc dot gnu dot org 2004-10-18 22:25
---
Oh, you are right I need to look at the test more closely.
--
What|Removed |Added
--- Additional Comments From giovannibajo at libero dot it 2004-10-18 22:15
---
Uh? How can an increment operation change the address of a variable?
--
What|Removed |Added
--- Additional Comments From pinskia at gcc dot gnu dot org 2004-10-18 22:01
---
No the warning is correct. ++a could come before or after taking the address of a
which is why this is
undefined.
--
What|Removed |Added
---
15 matches
Mail list logo