This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: V3 static data in classes vs AIX


	Investigating this further, GCC only produces the common symbol if
the static class member actually is defined, not just referenced.  In
other words,

class foo {
public:
        static int i;
};

void p()
{
        foo::i = 99;
}

does not produce a common symbol, only the reference.

	The existence of a common symbol for the testcases means that
there is some definition in the header files or the compiler is generating
a definition for some input where it should not.  This clearly is a bug.
I am going to try to see exactly what input is required to produce the
common symbol.

David


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]