编译器错误 C3179

不允许未命名的托管类型或 WinRT 类型

所有 CLR 与 WinRT 类和结构都必须具有名称。

下面的示例生成 C3179,并演示如何修复此错误:

// C3179a.cpp
// compile with: /clr /c
typedef value struct { // C3179
// try the following line instead
// typedef value struct MyStruct {
   int i;
} V;