https://gcc.gnu.org/bugzilla/show_bug.cgi?id=11751
--- Comment #90 from Emil Obermayr ---
Dear Oleg,
You have three printf, but only 2 outputs.
You don't tell us, what the right output should be, and why.
Your tests are highly dependent on the order of evaluation. So the only
use is to detect
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=11751
--- Comment #89 from Oleg ---
Is this produces correct output?
#include
#include
int main()
{
int i = 100;
i = i++ + ++i;
printf("i=%d\n", i);
i = 100;
i = ++i + i++;
printf("i=%d\n", i);
i = 100;
i = i + i++;
printf("i=%d
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=11751
Oleg changed:
What|Removed |Added
CC||oraytman1 at comcast dot net
--- Comment #88 from
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11751
Elizbath Martin changed:
What|Removed |Added
CC||elizbathjames at gmail dot com
--- Comm
--- Comment #86 from schwab at linux-m68k dot org 2010-01-12 16:24 ---
*** Bug 42711 has been marked as a duplicate of this bug. ***
--
schwab at linux-m68k dot org changed:
What|Removed |Added
--
--- Comment #85 from schwab at linux-m68k dot org 2009-06-07 09:04 ---
*** Bug 40366 has been marked as a duplicate of this bug. ***
--
schwab at linux-m68k dot org changed:
What|Removed |Added
--
--- Comment #84 from pinskia at gcc dot gnu dot org 2009-02-09 18:45
---
*** Bug 39143 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
-
--- Comment #83 from schwab at suse dot de 2008-12-13 18:26 ---
*** Bug 38516 has been marked as a duplicate of this bug. ***
--
schwab at suse dot de changed:
What|Removed |Added
--- Comment #82 from paolo dot carlini at oracle dot com 2008-10-10 16:33
---
*** Bug 37800 has been marked as a duplicate of this bug. ***
--
paolo dot carlini at oracle dot com changed:
What|Removed |Added
---
--- Comment #81 from pinskia at gcc dot gnu dot org 2007-08-31 16:09
---
*** Bug 33270 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
-
--- Comment #80 from schwab at suse dot de 2007-08-30 16:10 ---
*** Bug 33248 has been marked as a duplicate of this bug. ***
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11751
--- Comment #79 from rguenth at gcc dot gnu dot org 2007-08-30 12:33
---
*** Bug 33248 has been marked as a duplicate of this bug. ***
--
rguenth at gcc dot gnu dot org changed:
What|Removed |Added
-
--- Comment #78 from gjasny at web dot de 2007-08-10 12:02 ---
*** Bug 33043 has been marked as a duplicate of this bug. ***
--
gjasny at web dot de changed:
What|Removed |Added
--
--- Comment #77 from schwab at suse dot de 2007-06-28 16:54 ---
*** Bug 32536 has been marked as a duplicate of this bug. ***
--
schwab at suse dot de changed:
What|Removed |Added
--- Comment #76 from pinskia at gcc dot gnu dot org 2007-05-28 22:47
---
*** Bug 32133 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
-
--- Comment #75 from pinskia at gcc dot gnu dot org 2007-05-24 16:21
---
*** Bug 32067 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
-
--- Comment #74 from rguenth at gcc dot gnu dot org 2007-03-30 13:03
---
*** Bug 31398 has been marked as a duplicate of this bug. ***
--
rguenth at gcc dot gnu dot org changed:
What|Removed |Added
-
--- Comment #73 from rguenth at gcc dot gnu dot org 2007-02-23 15:36
---
*** Bug 30935 has been marked as a duplicate of this bug. ***
--
rguenth at gcc dot gnu dot org changed:
What|Removed |Added
-
--- Comment #72 from pinskia at gcc dot gnu dot org 2006-05-17 19:06
---
*** Bug 27646 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
-
--- Comment #71 from pinskia at gcc dot gnu dot org 2006-04-28 00:00
---
*** Bug 27344 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
-
--- Comment #70 from pinskia at gcc dot gnu dot org 2006-04-21 00:40
---
*** Bug 27233 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
-
--- Comment #69 from pinskia at gcc dot gnu dot org 2006-04-14 16:54
---
*** Bug 27153 has been marked as a duplicate of this bug. ***
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11751
--- Comment #68 from pinskia at gcc dot gnu dot org 2006-04-14 02:50
---
*** Bug 27153 has been marked as a duplicate of this bug. ***
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11751
--- Comment #67 from pinskia at gcc dot gnu dot org 2006-04-14 02:31
---
*** Bug 27153 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
-
--- Comment #66 from pinskia at gcc dot gnu dot org 2006-03-29 19:26
---
*** Bug 26923 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
-
--- Comment #65 from pinskia at gcc dot gnu dot org 2006-03-23 06:30
---
*** Bug 26820 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
-
--- Comment #64 from pinskia at gcc dot gnu dot org 2006-03-17 16:59
---
*** Bug 26730 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
-
--- Comment #63 from dberlin at gcc dot gnu dot org 2006-03-11 16:49
---
(In reply to comment #61)
> referring to duplicate 26642:
>
> The behavior changed between gcc3 and gcc4 and the comment is "there is no
> reason the result should not change"?
There is simply no guarantee at al
--- Comment #62 from pinskia at gcc dot gnu dot org 2006-03-11 16:14
---
(In reply to comment #61)
> referring to duplicate 26642:
>
> The behavior changed between gcc3 and gcc4 and the comment is "there is no
> reason the result should not change"?
Why this is undefined code :).
-
--- Comment #61 from nobs at tigress dot com 2006-03-11 16:10 ---
referring to duplicate 26642:
The behavior changed between gcc3 and gcc4 and the comment is "there is no
reason the result should not change"?
Sorry, but I think that's a really bad way to handle things. When a update
c
--- Comment #60 from pinskia at gcc dot gnu dot org 2006-03-11 15:09
---
*** Bug 26642 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
-
--- Comment #59 from pinskia at gcc dot gnu dot org 2006-02-22 14:04
---
*** Bug 26418 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
-
--- Comment #58 from schwab at suse dot de 2006-02-01 10:34 ---
*** Bug 26060 has been marked as a duplicate of this bug. ***
--
schwab at suse dot de changed:
What|Removed |Added
--- Comment #57 from pinskia at gcc dot gnu dot org 2005-12-12 20:23
---
*** Bug 2673 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
--
--- Comment #56 from pinskia at gcc dot gnu dot org 2005-11-10 03:49
---
*** Bug 6891 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
--
--- Comment #55 from pinskia at gcc dot gnu dot org 2005-11-10 03:49
---
*** Bug 6765 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
--
--- Comment #54 from pinskia at gcc dot gnu dot org 2005-11-10 03:48
---
*** Bug 8175 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
--
--- Comment #53 from pinskia at gcc dot gnu dot org 2005-11-10 03:18
---
*** Bug 5051 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
--
--- Comment #52 from pinskia at gcc dot gnu dot org 2005-11-10 03:17
---
*** Bug 762 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
---
--- Comment #51 from pinskia at gcc dot gnu dot org 2005-11-10 03:17
---
*** Bug 1570 has been marked as a duplicate of this bug. ***
--
pinskia at gcc dot gnu dot org changed:
What|Removed |Added
--
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-09-22
17:07 ---
*** Bug 24015 has been marked as a duplicate of this bug. ***
--
What|Removed |Added
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-07-01
14:29 ---
*** Bug 22248 has been marked as a duplicate of this bug. ***
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11751
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-06-30
13:37 ---
*** Bug 22248 has been marked as a duplicate of this bug. ***
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11751
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-06-30
13:26 ---
*** Bug 22248 has been marked as a duplicate of this bug. ***
--
What|Removed |Added
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-05-05
18:12 ---
*** Bug 21404 has been marked as a duplicate of this bug. ***
--
What|Removed |Added
--- Additional Comments From giovannibajo at libero dot it 2005-04-27
11:40 ---
*** Bug 21246 has been marked as a duplicate of this bug. ***
--
What|Removed |Added
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-04-21
04:58 ---
*** Bug 6409 has been marked as a duplicate of this bug. ***
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11751
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-04-20
03:05 ---
*** Bug 9675 has been marked as a duplicate of this bug. ***
--
What|Removed |Added
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-04-20
03:03 ---
*** Bug 9334 has been marked as a duplicate of this bug. ***
--
What|Removed |Added
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-04-20
02:59 ---
*** Bug 6409 has been marked as a duplicate of this bug. ***
--
What|Removed |Added
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-04-20
02:58 ---
*** Bug 5516 has been marked as a duplicate of this bug. ***
--
What|Removed |Added
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-04-20
02:57 ---
*** Bug 5494 has been marked as a duplicate of this bug. ***
--
What|Removed |Added
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-04-20
02:56 ---
*** Bug 5159 has been marked as a duplicate of this bug. ***
--
What|Removed |Added
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-04-20
02:55 ---
*** Bug 3324 has been marked as a duplicate of this bug. ***
--
What|Removed |Added
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-04-20
02:54 ---
*** Bug 2550 has been marked as a duplicate of this bug. ***
--
What|Removed |Added
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-04-20
02:47 ---
*** Bug 1039 has been marked as a duplicate of this bug. ***
--
What|Removed |Added
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-04-20
02:42 ---
*** Bug 3165 has been marked as a duplicate of this bug. ***
--
What|Removed |Added
--- Additional Comments From schlie at comcast dot net 2005-02-24 10:34
---
Although I can confidently say that I've been less than enthusiastic with
some of GCC's standards interpretations; here GCC's results in each of the
examples you cite are within the set of semantically consent va
--- 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
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-02-23
20:51 ---
(In reply to comment #30)
> I'm not sure what you mean by the system(...) call... I understand that the
> code
> is undefined (meaning its up to the compiler vendor to implement as they see
> fit). I think
--- Additional Comments From d_picco at hotmail dot com 2005-02-23 20:46
---
Here is a better clarification:
Case 1
==
int a = 0;
int b = a++ + a++;
printf("b = %d\n", b); // output is 0
Case 2
==
class A
{
int a_;
public:
A() : a_(0) {}
int operator++() { return a_++;
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-02-23
20:41 ---
(In reply to comment #28)
The code is undefined, which means we should be able to do system("rm -Rf /");,
note we don't.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11751
--- Additional Comments From d_picco at hotmail dot com 2005-02-23 20:38
---
The point I was making with my example is that the native types (int, long,
char, etc...) have different behaviour than a user-defined class with the
operator++. If it is compiler dependent which way the expres
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-02-23
20:26 ---
*** Bug 20181 has been marked as a duplicate of this bug. ***
--
What|Removed |Added
--- Additional Comments From pcarlini at suse dot de 2005-02-07 00:19
---
*** Bug 19798 has been marked as a duplicate of this bug. ***
--
What|Removed |Added
--
What|Removed |Added
Target Milestone|3.4.0 |---
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11751
66 matches
Mail list logo