https://gcc.gnu.org/bugzilla/show_bug.cgi?id=128805
Drea Pinski <pinskia at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Ever confirmed|0 |1
Status|UNCONFIRMED |NEW
Last reconfirmed| |2026-11-17
--- Comment #1 from Drea Pinski <pinskia at gcc dot gnu.org> ---
Confirmed. This is combo front-end/middle-end issue.
First CONSTRUCTOR does not store the locations for each of the field
assignments. So the front-end does not save that off.
This is why gimplify_init_ctor_eval uses the input_location there.
I think we might need two versions of the CONSTRUCTOR, one for front-ends with
the location and one for gimple.
Though maybe the gimple one can just be VECTOR_VALUE, EMPTY_CONSTRUCTOR and
CLOBBER instead ...
But this requires many IR changes. I am not sure anyone be willing to do this
work any more.
Oh CONSTRUCTOR will be still showing up in DECL_INITs. So maybe instead the
front-end could wrap the value with a location marker and use that. That would
be more localized. For DECL_INIT, we could go through them and remove those
wrappers.