On 09/09/2013 12:08 PM, Paolo Carlini wrote:
Everything happens via call backs. Thus from the generic diagnostic
machinery, you go to cp_printer for C++, thus location_of for C++. In
C is different, but again there is, evidently, a mechanism which uses
DECL_CONTEXT for PARM_DECLs which leads to an inaccurate location when
we *really* want the location of the parameter (exactly as I explained
for C++).
See line # 615 of pretty-print.c, that call leads you back to the
front-end, thus cp_printer etc, for C++
Paolo.