[Bug c++/50835] [4.7 Regression] Lvalue-ness of conditional operator results is incorrect in a function template
jason at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Tue Nov 8 17:14:00 GMT 2011
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=50835
--- Comment #5 from Jason Merrill <jason at gcc dot gnu.org> 2011-11-08 17:10:16 UTC ---
Author: jason
Date: Tue Nov 8 17:10:09 2011
New Revision: 181174
URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=181174
Log:
PR c++/50835
* typeck.c (build_x_conditional_expr): Preserve lvalue/xvalueness.
* tree.c (lvalue_kind) [NON_DEPENDENT_EXPR]: Return clk_ordinary
in C++98.
Added:
trunk/gcc/testsuite/g++.dg/template/lvalue2.C
Modified:
trunk/gcc/cp/ChangeLog
trunk/gcc/cp/tree.c
trunk/gcc/cp/typeck.c
trunk/gcc/testsuite/ChangeLog
More information about the Gcc-bugs
mailing list