------- Additional Comments From reichelt at gcc dot gnu dot org 2005-07-11 16:15 ------- It doesn't link because of [templ.expl.spec]:
An explicit specialization of a static data member of a template is a definition if the declaration includes an initializer; otherwise, it is a declaration. [Note: there is no syntax for the definition of a static data member of a template that requires default initialization. template<> X Q<int>::x; This is a declaration regardless of whether X can be default initial- ized (_dcl.init_). ] You must provide the initializer, e.g. template<> int ObjectPool<char>::mutex = 0; -- What |Removed |Added ---------------------------------------------------------------------------- CC| |reichelt at gcc dot gnu dot | |org Keywords| |monitored http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20133