http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51426
Bug #: 51426 Summary: explicit instantiation declaration without definition Classification: Unclassified Product: gcc Version: 4.6.2 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ AssignedTo: unassig...@gcc.gnu.org ReportedBy: mk...@wp.pl The below code can be compiled (with -std=C++0x option). -------------------------- template <typename T> struct A { }; extern template struct A<int>; int main() { A<int> a; } -------------------------- According to C++11 standard (14.7 paragraph 5) it shouldn't "an explicit instantiation definition shall appear at most once in a program" I was trying to test 'extern templates' based on Bjarne Stroustrup's page: http://www2.research.att.com/~bs/C++0xFAQ.html#extern-templates Regards, Marcin