नोट
इस पृष्ठ तक पहुंच के लिए प्राधिकरण की आवश्यकता होती है। आप साइन इन करने या निर्देशिकाएँ बदलने का प्रयास कर सकते हैं।
इस पृष्ठ तक पहुंच के लिए प्राधिकरण की आवश्यकता होती है। आप निर्देशिकाएँ बदलने का प्रयास कर सकते हैं।
'identifier' : too many type arguments
Remarks
A generic or template has too many actual arguments. Check the generic or template declaration to find the correct number of parameters.
Examples
The following example generates C2977:
// C2977.cpp
// compile with: /c
template<class T, int i>
class MyClass {};
template MyClass< int , 1, 1 >; // C2977
template MyClass< int , 1 >; // OK
C2977 can also occur when using generics:
// C2977b.cpp
// compile with: /clr
// C2977 expected
generic <class T, class U>
void f(){}
generic <class T>
ref struct GC1 {};
int main() {
// Delete the following 2 lines to resolve.
GC1<int, char> ^ pgc1;
f<int,int,int>();
// OK
GC1<int> ^ pgc1;
f<int, int>();
}