https://gcc.gnu.org/bugzilla/show_bug.cgi?id=54319
--- Comment #8 from Andrew Pinski <pinskia at gcc dot gnu.org> --- I think the problem is here in init.c: /* If the type has data but no user-provided default ctor, we need to zero out the object. */ if (type_has_non_user_provided_default_constructor (type) && !is_really_empty_class (type, /*ignore_vptr*/true)) { tree field_size = NULL_TREE; if (exp != true_exp && CLASSTYPE_AS_BASE (type) != type) /* Don't clobber already initialized virtual bases. */ field_size = TYPE_SIZE (CLASSTYPE_AS_BASE (type)); init = build_zero_init_1 (type, NULL_TREE, /*static_storage_p=*/false, field_size); init = build2 (INIT_EXPR, type, exp, init); finish_expr_stmt (init); }