Kompilatorfel C2770

ogiltiga explicita template_or_generic argument för "mall"

Anmärkningar

Funktionsmallskandidater med explicita mallar eller allmänna argument resulterade i otillåtna funktionstyper.

Exempel

I följande exempel genereras C2770:

// C2770.cpp
#include <stdio.h>
template <class T>
int f(typename T::B*);   // expects type with member B

struct Err {};

int main() {
   f<int>(0);   // C2770 int has no B
   // try the following line instead
   f<OK>(0);
}