Kompilatorfel C3268

"funktion" : en allmän funktion eller en medlemsfunktion i en generisk klass kan inte ha en lista med variabelparametrar

Anmärkningar

Alternativen /clr:pure och /clr:safe compiler är inaktuella i Visual Studio 2015 och stöds inte i Visual Studio 2017.

För mer information, se Generics.

Example

I följande exempel genereras C3268.

// C3268.cpp
// compile with: /clr:pure /c
generic <class ItemType>
void Test(ItemType item, ...) {}   // C3268
// try the following line instead
// void Test(ItemType item) {}

generic <class ItemType2>
ref struct MyStruct { void Test(...){} };   // C3268
// try the following line instead
// ref struct MyStruct { void Test2(){} };   // OK