re PR c++/65945 (C++ alignment of nullptr_t is 1 and might cause unaligned stores...
authorJason Merrill <jason@redhat.com>
Wed, 1 Jul 2015 17:59:19 +0000 (13:59 -0400)
committerJason Merrill <jason@gcc.gnu.org>
Wed, 1 Jul 2015 17:59:19 +0000 (13:59 -0400)
commitd68f848b12654cb359951eb24608d9e1b5f05e64
tree02021abfb17f1a5128da0a9911f59033583619eb
parentf9a12f7b8fd56359f1eee124309fc783f83466b5
re PR c++/65945 (C++ alignment of nullptr_t is 1 and might cause unaligned stores to the frame)

PR c++/65945
* decl.c (cxx_init_decl_processing): Set TYPE_ALIGN of nullptr_t.
* class.c (layout_nonempty_base_or_field): Warn if that affects
the offset of a field.

From-SVN: r225270
gcc/cp/ChangeLog
gcc/cp/class.c
gcc/cp/decl.c
gcc/testsuite/g++.dg/abi/nullptr-align.C [new file with mode: 0644]
gcc/testsuite/g++.dg/abi/nullptr-align2.C [new file with mode: 0644]