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 C2457

'macro': predefined macro cannot appear outside of a function body

You attempted to use a predefined macro, such as __FUNCTION__, in a global space. The following sample generates C2457:

#include <stdio.h>
__FUNCTION__;   // C2457, cannot be global

void main() {
   // try ...
   // printf("\n%s",__FUNCTION__);
}