categorize_decl_for_section bogosity

Zack Weinberg zack@codesourcery.com
Tue May 25 18:38:00 GMT 2004


"Dave Korn" <dk@artimi.com> writes:

[...]
>   Anyone got any thoughts on this?  I'm tempted to look out for whatever
> flag it is that tells me that this is an extern declaration and add "&& !"
> that test to the DECL_INITIAL (decl) == NULL clause, but that might have
> knockon effects.  Has anyone else considered this issue before?

Naively, I would think this is a bug which has gone unnoticed because
most of the time the compiler doesn't care what section an external
reference is in.

To test for an external reference I *think* you do
  DECL_EXTERNAL(decl) && !TREE_PUBLIC(decl)
but someone else may know better.

zw



More information about the Gcc mailing list