नोट
इस पृष्ठ तक पहुंच के लिए प्राधिकरण की आवश्यकता होती है। आप साइन इन करने या निर्देशिकाएँ बदलने का प्रयास कर सकते हैं।
इस पृष्ठ तक पहुंच के लिए प्राधिकरण की आवश्यकता होती है। आप निर्देशिकाएँ बदलने का प्रयास कर सकते हैं।
'user-defined type' : possible change in behavior, change in UDT return calling convention
Remarks
A class template specialization wasn't defined before it was used in a return type. Anything that instantiates the class resolves C4686; declaring an instance or accessing a member (for example, C<int>::some_member) are also options.
This warning is off by default. For more information, see Compiler warnings that are off by default.
Example
Try the following instead:
// C4686.cpp
// compile with: /W3
#pragma warning (default : 4686)
template <class T>
class C;
template <class T>
C<T> f(T);
template <class T>
class C {};
int main() {
f(1); // C4686
}
template <class T>
C<T> f(T) {
return C<int>();
}