Re: GCC Front End: Finding the location of a Symbol Definition

Martin von Loewis <loewis@informatik.hu-berlin.de>
6 Aug 2001 04:04:41 -0400

          From comp.compilers

Related articles
GCC Front End: Finding the location of a Symbol Definition hardnett@cc.gatech.edu (Charles Hardnett) (2001-08-02)
Re: GCC Front End: Finding the location of a Symbol Definition loewis@informatik.hu-berlin.de (Martin von Loewis) (2001-08-06)
| List of all articles for this month |
From: Martin von Loewis <loewis@informatik.hu-berlin.de>
Newsgroups: comp.compilers
Date: 6 Aug 2001 04:04:41 -0400
Organization: Humboldt University Berlin, Department of Computer Science
References: 01-08-013
Keywords: GCC
Posted-Date: 06 Aug 2001 04:04:41 EDT

Charles Hardnett <hardnett@cc.gatech.edu> writes:


> If the GCC frontend determines that struct stat is defined in another
> location either a library or another file, then I want to preserve this
> information to have the BE translator use it to determine whether or not
> to create a definition of this type.
>
> Does anyone have any idea of how / where I can get this kind of
> information?


If you have a decl node, you can use DECL_SOURCE_FILE and
DECL_SOURCE_LINE to find out where it was originally declared.


Regards,
Martin


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.