[RFA] Use location_t to record declaration location in tree_decl

Mark Mitchell mark@codesourcery.com
Tue Jun 25 16:04:00 GMT 2002



--On Tuesday, June 25, 2002 07:52:19 PM +0200 Gabriel Dos Reis 
<gdr@codesourcery.com> wrote:

> Neil Booth <neil@daikokuya.co.uk> writes:
>
> [...]
>
> | >    location_t saved_locus;
> | >    saved_locus = current_input_locus;
> | >    current_input_locus = DECL_SOURCE_LOCATION (decl);
> | >    /* ... */
> | >    current_input_locus = saved_locus;
> |
> | Can I suggest "loc" instead of "locus"?  My mathematician's
> | understanding of "locus" is a set of points, in particular a path.
>
> Point taken.

I think Gaby's direction is a good one.  We can always make "location_t"
(or whatever the type is named) contain a linearized index if we want to
do so.  Abstraction is a good thing.

So, Gaby, assuming no veto from Richard, the patch is OK.

-- 
Mark Mitchell                mark@codesourcery.com
CodeSourcery, LLC            http://www.codesourcery.com



More information about the Gcc-patches mailing list