diff options
author | Richard Biener <rguenther@suse.de> | 2018-08-02 14:25:57 +0000 |
---|---|---|
committer | Richard Biener <rguenth@gcc.gnu.org> | 2018-08-02 14:25:57 +0000 |
commit | f70cb6f5b0ee51223319ec524994e59d356fb862 (patch) | |
tree | e9eae87de63873763871a755185272deb1e12bde /gcc/cp | |
parent | 7c9f1147b866b3fec70fdce60bc37f1f4d41b330 (diff) | |
download | gcc-f70cb6f5b0ee51223319ec524994e59d356fb862.zip gcc-f70cb6f5b0ee51223319ec524994e59d356fb862.tar.gz gcc-f70cb6f5b0ee51223319ec524994e59d356fb862.tar.bz2 |
re PR c++/86763 (Wrong code comparing member of copy of a 237 byte object with nontrivial default constructor on x86-64 arch)
2018-08-02 Richard Biener <rguenther@suse.de>
PR c++/86763
* class.c (layout_class_type): Copy TYPE_TYPELESS_STORAGE
to the CLASSTYPE_AS_BASE.
* g++.dg/torture/pr86763.C: New testcase.
From-SVN: r263261
Diffstat (limited to 'gcc/cp')
-rw-r--r-- | gcc/cp/class.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/gcc/cp/class.c b/gcc/cp/class.c index de59831..76a9e18 100644 --- a/gcc/cp/class.c +++ b/gcc/cp/class.c @@ -6279,6 +6279,7 @@ layout_class_type (tree t, tree *virtuals_p) bitsize_int (BITS_PER_UNIT))); SET_TYPE_ALIGN (base_t, rli->record_align); TYPE_USER_ALIGN (base_t) = TYPE_USER_ALIGN (t); + TYPE_TYPELESS_STORAGE (base_t) = TYPE_TYPELESS_STORAGE (t); /* Copy the non-static data members of T. This will include its direct non-virtual bases & vtable. */ |