error C3395: 'MyClass::Function' : __declspec(dllexport) cannot be applied to a
时间:2010-11-19 来源:zip's
error C3395: 'MyClass::Function' : __declspec(dllexport) cannot be applied to a function with the __clrcall calling convention
解决方法是,为参数包上 gcroot<>.
class AFX_EXT_CLASS MyClass{ public: void Function(MyDotNetClass^ obj); // 编译错误 void Function(gcroot<MyDotNetClass^> obj); // OK!}
相关阅读 更多 +
排行榜 更多 +