Compiler Error C2724

'identifier' : 'static' should not be used on member functions defined at file scope

A static member function was defined at file scope. Static member functions should be declared with external linkage.

This is a warning when Microsoft extensions are used (/Ze) and is an error when Microsoft extensions are disabled (/Za).

The following is an example of this error:

class C 
{
   static void func(); 
};

static void C::func(){};    // error