共用方式為


編譯器錯誤 C3755

'delegate': 無法定義委派

委派 (C++ 元件延伸模組) 可以宣告但無法定義。

範例

下列範例會產生 C3755。

// C3755.cpp
// compile with: /clr /c
delegate void MyDel() {};   // C3755

如果您嘗試建立委派範本,也可能會發生 C3755。 下列範例會產生 C3755。

// C3755_b.cpp
// compile with: /clr /c
ref struct R {
   template<class T>
   delegate void D(int) {}   // C3755
};