NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

Compiler Error C3809

'structure' : a managed class/struct cannot have any friend functions/classes/interfaces

Managed classes and structures do not allow friends. To resolve the error do not declare friends inside managed classes.

The following sample generates C3809:

#using <mscorlib.dll>

__gc class A {
};

__gc class B {
   public:
   friend __gc class A;   // C3809
};

void main(){
}