https://gcc.gnu.org/bugzilla/show_bug.cgi?id=115900

--- Comment #5 from Marek Polacek <mpolacek at gcc dot gnu.org> ---
What changed is the initializer we generate for 'd'.  It used to be:

  d = {.D.2656={.a={.data=0}}}

but now it is:

  D::D ((struct D *) &d)

The second one causes trouble because we evaluate

  ((struct A *) this)->data = NON_LVALUE_EXPR <0>

(where the LHS evaluates to d.D.256.a) *after* 'd' was marked READONLY in
build_aggr_init, which causes the error.

Reply via email to