Sdílet prostřednictvím


Chyba kompilátoru C3268

'function' : obecná funkce nebo člen-funkce obecné třídy nemůže mít seznam parametrů proměnné.

Poznámky

Možnosti kompilátoru /clr:pure a /clr:safe jsou v sadě Visual Studio 2015 zastaralé a v sadě Visual Studio 2017 nejsou podporované.

Další informace najdete v obecných tématech .

Příklad

Následující příklad vygeneruje 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