[Bug c++/58714] Bogus overload resolution for the assignment operator in assignment to a conditional

2014-08-07 Thread jason at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58714

--- Comment #7 from Jason Merrill jason at gcc dot gnu.org ---
Author: jason
Date: Thu Aug  7 18:54:27 2014
New Revision: 213724

URL: https://gcc.gnu.org/viewcvs?rev=213724root=gccview=rev
Log:
PR c++/58714
* tree.c (stabilize_expr): A stabilized prvalue is an xvalue.

Added:
branches/gcc-4_9-branch/gcc/testsuite/g++.dg/cpp0x/rv-cond1.C
branches/gcc-4_9-branch/gcc/testsuite/g++.dg/expr/cond12.C
Modified:
branches/gcc-4_9-branch/gcc/cp/ChangeLog
branches/gcc-4_9-branch/gcc/cp/tree.c


[Bug c++/58714] Bogus overload resolution for the assignment operator in assignment to a conditional

2014-08-07 Thread jason at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58714

Jason Merrill jason at gcc dot gnu.org changed:

   What|Removed |Added

 Status|NEW |RESOLVED
 Resolution|--- |FIXED
   Target Milestone|--- |4.9.2

--- Comment #8 from Jason Merrill jason at gcc dot gnu.org ---
Fixed for 4.9.2.


[Bug c++/58714] Bogus overload resolution for the assignment operator in assignment to a conditional

2014-08-07 Thread jason at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58714

--- Comment #9 from Jason Merrill jason at gcc dot gnu.org ---
Author: jason
Date: Thu Aug  7 19:50:04 2014
New Revision: 213734

URL: https://gcc.gnu.org/viewcvs?rev=213734root=gccview=rev
Log:
PR c++/58714
* tree.c (stabilize_expr): A stabilized prvalue is an xvalue.

Added:
branches/gcc-4_8-branch/gcc/testsuite/g++.dg/cpp0x/rv-cond1.C
branches/gcc-4_8-branch/gcc/testsuite/g++.dg/expr/cond12.C
Modified:
branches/gcc-4_8-branch/gcc/cp/ChangeLog
branches/gcc-4_8-branch/gcc/cp/tree.c


[Bug c++/58714] Bogus overload resolution for the assignment operator in assignment to a conditional

2014-08-07 Thread jason at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58714

Jason Merrill jason at gcc dot gnu.org changed:

   What|Removed |Added

   Target Milestone|4.9.2   |4.8.4

--- Comment #10 from Jason Merrill jason at gcc dot gnu.org ---
And 4.8.4.


[Bug c++/58714] Bogus overload resolution for the assignment operator in assignment to a conditional

2014-05-09 Thread jason at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58714

--- Comment #5 from Jason Merrill jason at gcc dot gnu.org ---
Author: jason
Date: Fri May  9 18:16:05 2014
New Revision: 210283

URL: http://gcc.gnu.org/viewcvs?rev=210283root=gccview=rev
Log:
PR c++/58714
* tree.c (stabilize_expr): A stabilized prvalue is an xvalue.

Added:
trunk/gcc/testsuite/g++.dg/cpp0x/rv-cond1.C
trunk/gcc/testsuite/g++.dg/expr/cond12.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/tree.c


[Bug c++/58714] Bogus overload resolution for the assignment operator in assignment to a conditional

2014-05-09 Thread jason at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58714

Jason Merrill jason at gcc dot gnu.org changed:

   What|Removed |Added

 CC||jason at gcc dot gnu.org
   Assignee|unassigned at gcc dot gnu.org  |jason at gcc dot gnu.org

--- Comment #6 from Jason Merrill jason at gcc dot gnu.org ---
Fixed on trunk currently.


[Bug c++/58714] Bogus overload resolution for the assignment operator in assignment to a conditional

2013-10-14 Thread glisse at gcc dot gnu.org
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58714

Marc Glisse glisse at gcc dot gnu.org changed:

   What|Removed |Added

   Keywords||wrong-code

--- Comment #4 from Marc Glisse glisse at gcc dot gnu.org ---
The C++03 wrong-code version:

struct X {
X operator=(const X){}
X operator=(X){__builtin_abort();}
};

int main(int argv,char**) {
  X a, b;
  ((argv  2) ? a : b) = X();
}

I don't know if stabilize_expr is wrong, or if it is wrong to call it, I'll
leave that to someone else.


[Bug c++/58714] Bogus overload resolution for the assignment operator in assignment to a conditional

2013-10-14 Thread paolo.carlini at oracle dot com
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=58714

Paolo Carlini paolo.carlini at oracle dot com changed:

   What|Removed |Added

   Priority|P3  |P2