'type' : type is inaccessible
The type is not accessible. To resolve the error, make the type public. To generate C3376, create two source code files and compile them as described below:
// a.cpp // compile with /com+ and /LD // creates a DLL called a.dll #using <mscorlib.dll> private __gc class X { // change 'private' to 'public' to resolve }; public __gc class Y { public: Y() { } X *m_pX; }; // b.cpp // compile with /com+ // creates an EXE called b.exe #using "a.dll" #using <mscorlib.dll> void main() { Y *pY = new Y; // C3376 }