Article ID: 150573
Article Last Modified on 7/5/2005
/* Compile options needed: /c
*/
template <class T>
class A {
public:
A(); // give this ctor a body for workaround 1
A(const T&);
};
template <class T> A<T>::A(const T&) {}; // move this ctor body
// inside the class
// definition for
// workaround 2
template A<int>; // this is an explicit instantiation -
// comment this line out and uncomment the
// next line for workaround 3
// A<int> x = 3; // this is an implicit instantiation
Additional query words: kbVC400bug
Keywords: kbbug kbfix kbvc500fix kbcpponly kbcompiler KB150573