This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [C PATCH] Improve locinfo in the C FE (PR c/59940)


On Wed, 29 Jan 2014, Marek Polacek wrote:

> Finally I managed to get this patch into regression-free shape.  It
> should improve the column info for quite a lot of warnings, fixing
> PR59940 on the way.  I had to add location_t to bunch of functions;
> SET_EXPR_LOCATION is of no use here - we're dealing with
> {VAR,PARM}_DECLs, which do not carry a locus info.  Yet the function
> parameters are often called expr...
> I had to use expansion_point_location_if_in_system_header to
> get this working even with -ftrack-macro-expansion.
> 
> Surely there are lots of other spots to fix, but this should be
> a step forward.  Interestingly, adding locs here and there sometimes
> reminds me of a Whac-A-Mole game.
> 
> Regtested/bootstrapped on x86_64-linux, ok for trunk?

The c/ and c-family/ changes are OK.  (One of the other things left to fix 
would be that it looks like convert_arguments could do with locations for 
each argument, rather than just a single main location.)

-- 
Joseph S. Myers
joseph@codesourcery.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]