This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug c++/7503] (x < Y ? X : Y) used for assignment causes wrong code
- From: "bangerth at dealii dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 21 Jun 2004 15:01:40 -0000
- Subject: [Bug c++/7503] (x < Y ? X : Y) used for assignment causes wrong code
- References: <20020805221601.7503.moore_mn@cobra.cs.mercer.edu>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From bangerth at dealii dot org 2004-06-21 15:01 -------
One (possibly good) question: does a ?: operator involve sequence
points? If we have an expression like
(a>b ? a : b) = 1;
with a,b being references, then we use some of the variables both
for evaluation and for assignment, and the question is if any of these
operations need to be ordered.
W.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=7503