title: undefined reference to `WindowProc(HWND__*, unsigned int, unsigned int, long)@16'
body: <p>I keep getting the following error when I try to compile my very simple program:</p>
  
  <blockquote>
    <p>undefined reference to WindowProc(HWND__*, unsigned int, unsigned int, long)@16'</p>
  </blockquote>
  
  <p>I don't see the problem and it's driving me crazy!</p>
  
  <pre><code>#include &lt;iostream&gt;
  #include &lt;windows.h&gt;
  
  using namespace std;
  
  int sizeX = 500;
  int sizeY = 500;
  
  LRESULT CALLBACK WindowProc(HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam);
  
  char szClassName[ ] = "WindowsApp";
  
  int WINAPI WinMain(
                     HINSTANCE hThisInstance,
                     HINSTANCE hPrevInstance,
                     LPSTR lpszArgument,
                     int nFunsterStil
                     )
  {
      HWND hwnd;
      MSG messages;
      WNDCLASSEX wincl;
  
      wincl.hInstance = hThisInstance;
      wincl.lpszClassName = szClassName;
      wincl.lpfnWndProc = WindowProc;
      wincl.style = CS_DBLCLKS;
      wincl.cbSize = sizeof(WNDCLASSEX);`
  
      wincl.hIcon = LoadIcon(NULL, IDI_APPLICATION);
      wincl.hIconSm = LoadIcon(NULL, IDI_APPLICATION);
      wincl.hCursor = LoadCursor(NULL, IDC_ARROW);
      wincl.lpszMenuName = NULL;
      wincl.cbClsExtra = 0;
      wincl.cbWndExtra = 0;
  
      wincl.hbrBackground = (HBRUSH) COLOR_BACKGROUND;
  
      if(!RegisterClassEx(&amp;wincl))
          return 0;
  
      hwnd = CreateWindowEx(
                            0,
                            szClassName,
                            "Windows App",
                            WS_SYSMENU,
                            CW_USEDEFAULT,
                            CW_USEDEFAULT,
                            sizeX,
                            sizeY,
                            HWND_DESKTOP,
                            NULL,
                            hThisInstance,
                            NULL
                        );
  }
  </code></pre>
  
  <p>What is wrong with the code?</p>