This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: [3.3/3.4] wrong handling of "extern const" variables
On Wed, Aug 20, 2003 at 09:37:26AM -0700, Richard Henderson wrote:
> On Wed, Aug 20, 2003 at 03:35:47PM +0200, Gunther Nikl wrote:
> > extern const char bar[];
>
> TREE_STATIC must be set here. If it isn't, that's the bug.
The value of TREE_STATIC is based on the presence of an extern keyword.
3.3 c-decl.c/grokdeclarator:4649 sets extern_ref to 1 for the case above
and later sets TREE_STATIC to !extern_ref. The same happens in 3.4. What
might be the correct fix?
Gunther