CWG 616, 1213 - value category of subobject references.
authorJason Merrill <jason@redhat.com>
Wed, 23 May 2018 17:21:22 +0000 (13:21 -0400)
committerJason Merrill <jason@gcc.gnu.org>
Wed, 23 May 2018 17:21:22 +0000 (13:21 -0400)
commit955da5e5443724cb59f8fbd854c13e78c68bf000
tree5376594ef4febecacfb8c0a3a1831fbdda417c0c
parenta6b29221604547ab14143081b45d955dd7a61a26
CWG 616, 1213 - value category of subobject references.

* tree.c (lvalue_kind): A reference to a subobject of a prvalue is
an xvalue.
* typeck2.c (build_m_component_ref): Likewise.
* typeck.c (cp_build_addr_expr_1, lvalue_or_else): Remove diagnostic
distinction between temporary and xvalue.

From-SVN: r260621
gcc/cp/ChangeLog
gcc/cp/tree.c
gcc/cp/typeck.c
gcc/cp/typeck2.c
gcc/testsuite/g++.dg/cpp0x/addressof2.C
gcc/testsuite/g++.dg/cpp0x/decltype49.C
gcc/testsuite/g++.dg/cpp0x/rv-lvalue-req.C
gcc/testsuite/g++.dg/ext/c99struct1.C
gcc/testsuite/g++.dg/ext/complit11.C
gcc/testsuite/g++.old-deja/g++.law/temps1.C