Compiler Warning (level 1) C4667 (Windows CE 5.0)
Windows CE 5.0
'function' : no function template defined that matches forced instantiation
You cannot instantiate a function template that has not been declared. For example, the following sample will cause C4667:
// compile with cl /c template void max(const int &, const int &);
To avoid this warning, first declare the function template:
//
// Declare the function template
//
template<typename T>
const T &max(const T &a, const T &b)
{
return (a > b) ? a : b;
}
// Then forcibly instantiate it with a desired type ... for example 'int'
//
template
const int &max(const int &, const int &);
Send Feedback on this topic to the authors
© 2006 Microsoft Corporation. All rights reserved.