Export (0) Print
Expand All
Expand Minimize

Compiler Error C3636

Visual Studio .NET 2003

The type 'type' is inaccessible or undefined in 'file'

A type was referenced but is not accessible.

The following sequence of samples generates C3636:

// C3636a.cpp
// compile with: /clr:noAssembly /LD
#using <mscorlib.dll>
private __gc class A {
   void Method(){}
// C3636b.cpp
// compile with: /clr:noAssembly /LD /W1
// post-build command: al /out:C3636c.dll C3636a.dll C3636b.dll
#using <mscorlib.dll>
#using "C3636a.dll"
public __gc class B {
   A* Method2() {   // C4677
      return new A();
// C3636d.cpp
// compile with: /clr
#using <mscorlib.dll>
#using "C3636c.dll"
int main() {
   B* b = new B();
   A* a = b->Method2();
   a->Method ();   // C3636
© 2015 Microsoft