编译器错误 C3623
“variable”: 托管或 WinRT 类型中不支持位域
不允许在托管或 WinRT 类的变量上使用位域。
以下示例生成 C3623:
// C3623.cpp
// compile with: /clr
using namespace System;
ref class CMyClass {
public:
int i : 1; // C3623
};
int main() {
CMyClass^ pMyClass = gcnew CMyClass();
pMyClass->i = 3;
Console::Out->WriteLine(pMyClass->i);
}
反馈
https://aka.ms/ContentUserFeedback。
即将发布:在整个 2024 年,我们将逐步淘汰作为内容反馈机制的“GitHub 问题”,并将其取代为新的反馈系统。 有关详细信息,请参阅:提交和查看相关反馈