I have two files: foo.h:
extern int x; extern int y; foo.c: #include "foo.h" int x; int y; I have written a gcc plugin that traverses the gcc AST ... However in the situation where I compile the above file I cannot seem to access the int x and int y decls. If I place a dummy function in the foo.c file I can get the decl's for x and y and I'm good however this isn't always the case in real code. Is there a list buried in gcc somewhere that I can traverse to get access these decls? Or are they ignored? Thanks, Kyle