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 C2845

'operator' : cannot perform pointer arithmetic on pointer to managed class 'class'

You cannot increment the pointer to a managed class.

The following sample generates C2845:

#using <mscorlib.dll>

__gc class X {
};

void main() {
   X *pX = new X;

   pX++;   // C2845
}