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 C2180

controlling expression has type 'void'

The controlling expression in an if, while, for, or do statement is a function with return type void or an expression cast to void. The following sample generates C2180:

void test() {
}

int test2() {
   return 0;
}

void main() {
   if (test())   // C2180
      ;
   // try ..
   /*
   if (test2())
      ;
   */   
}