Compiler Error C2929
Visual Studio 2015
The new home for Visual Studio documentation is Visual Studio 2017 Documentation on docs.microsoft.com.
The latest version of this topic can be found at Compiler Error C2929.
identifier' : explicit instantiation; cannot explicitly force and suppress instantiation of template-class member
You cannot explicitly instantiate an identifier while preventing it from being instantiated.
The following sample generates C2929:
// C2929.cpp
// compile with: /c
template<typename T>
class A {
public:
A() {}
};
template A<int>::A();
extern template A<int>::A(); // C2929
Show: