Various C++17 decomposition fixes.
authorJason Merrill <jason@redhat.com>
Tue, 15 Nov 2016 05:22:28 +0000 (00:22 -0500)
committerJason Merrill <jason@gcc.gnu.org>
Tue, 15 Nov 2016 05:22:28 +0000 (00:22 -0500)
commit47e5d7ccf12c5d11abdd18e8e9089735e4fd3d05
tree376f8789de74bf75a940c9583acaea031e9de6d6
parenta274cc11ac675686a71aef82e2e734795d18f339
Various C++17 decomposition fixes.

* tree.c (bitfield_p): New.
* cp-tree.h: Declare it.
* typeck.c (cxx_sizeof_expr, cxx_alignof_expr)
(cp_build_addr_expr_1): Use it instead of DECL_C_BIT_FIELD.
* decl.c (cp_finish_decomp): Look through reference.  Always
SET_DECL_DECOMPOSITION_P.
* semantics.c (finish_decltype_type): Adjust decomposition handling.

From-SVN: r242408
gcc/cp/ChangeLog
gcc/cp/cp-tree.h
gcc/cp/decl.c
gcc/cp/semantics.c
gcc/cp/tree.c
gcc/cp/typeck.c
gcc/testsuite/g++.dg/cpp0x/addressof2.C
gcc/testsuite/g++.dg/cpp1z/decomp-bitfield1.C [new file with mode: 0644]
gcc/testsuite/g++.dg/cpp1z/decomp-constexpr1.C [new file with mode: 0644]
gcc/testsuite/g++.dg/cpp1z/decomp10.C
gcc/testsuite/g++.dg/cpp1z/decomp11.C [new file with mode: 0644]