This documentation is archived and is not being maintained.

Compiler Warning (level 4) C4562

Visual Studio .NET 2003

fully prototyped functions are required with the '/clr' option: converting '()' to '(void)'

Function prototypes should be fully defined when compiling a C source code file using the /clr compiler option. The compiler automatically converts empty parameter lists to void. The following sample generates C4562:

// C4562.cpp
// compile with: /clr /W4 /Tc
int main() {   // C4562, use (void) instead of () to resolve
}
Show: