re PR c++/14586 (Bogus warning in templates about taking address of a temporary in...
authorMark Mitchell <mark@codesourcery.com>
Tue, 16 Mar 2004 22:18:11 +0000 (22:18 +0000)
committerMark Mitchell <mmitchel@gcc.gnu.org>
Tue, 16 Mar 2004 22:18:11 +0000 (22:18 +0000)
commitec835fb2bfc25fb747550aec56d261042659bc54
treec0d3485bbb98b41f57f677cc06f2b3179fd1f192
parent1e0f07d3952be55a453ad3ac7c326481b82f0d59
re PR c++/14586 (Bogus warning in templates about taking address of a temporary in a template)

PR c++/14586
* cp-tree.h (build_new_op): Change prototype.
(build_x_binary_op): Likewise.
* call.c (build_new_op): Add overloaded_p parameter.
* decl2.c (grok_array_decl): Adjust call to build_new_op.
* parser.c (cp_parser_binary_expression): Note that uses of
overloaded operators prevents an expression from being considered
an integral constant.
* pt.c (tsubst_copy_and_build): Adjust calls to build_new_op and/or
build_x_binary_op.
* semantics.c (finish_call_expr): Likewise.
* typeck.c (rationalize_conditional_expr): Likewise.
(build_x_indirect_ref): Likewise.
(build_x_binary_op): Likewise.
(build_x_unary_op): Likewise.
(build_x_compound_expr): Likewise.
(build_modify_expr): Likewise.
* typeck2.c (build_x_arrow): Likewise.

PR c++/14586
* g++.dg/parse/non-dependent3.C: New test.

From-SVN: r79553
gcc/cp/ChangeLog
gcc/cp/call.c
gcc/cp/cp-tree.h
gcc/cp/decl2.c
gcc/cp/parser.c
gcc/cp/pt.c
gcc/cp/semantics.c
gcc/cp/typeck.c
gcc/cp/typeck2.c
gcc/testsuite/ChangeLog
gcc/testsuite/g++.dg/parse/non-dependent3.C [new file with mode: 0644]