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

--- Comment #8 from Manuel López-Ibáñez <manu at gcc dot gnu.org> ---
(In reply to Paolo Carlini from comment #7)
> Thanks Jason.
> 
> Note that '+' eventually boils down to location_of, which does quite a bit
> more than DECL_SOURCE_LOCATION. Thus either we should be very, very careful
> in this work or in some cases use location_of to be safe, at least ad
> interim.

Indeed. And there are other cases that pass an explicit location and use '+',
thus simply removing '+' may regress the location info:

      error_at (type_start_token->location, "redefinition of %q#T",
                type);
      error_at (type_start_token->location, "previous definition of %q+#T",
                type);

Reply via email to