https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86763
--- Comment #9 from Richard Biener <rguenth at gcc dot gnu.org> ---
The following seems to work, will test.
Index: gcc/cp/class.c
===================================================================
--- gcc/cp/class.c (revision 263209)
+++ gcc/cp/class.c (working copy)
@@ -6243,6 +6243,7 @@ layout_class_type (tree t, tree *virtual
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. */