title: What does a "CALLBACK" declaration in C do?
body: <p>I was looking through some code from the <a href="http://www.libsdl.org" rel="noreferrer">SDL</a> library and came across a function declared like this:</p>
  
  <pre><code>LRESULT CALLBACK WndProc(HWND hwnd, UINT msg, WPARAM wParam, LPARAM lParam)
  </code></pre>
  
  <p>Now, I'm a Delphi coder.  No hablo C muy bien, senor.  But I remember enough syntax from my college courses to read it like this:</p>
  
  <p>Function name is WndProc.  Argument list is pretty self-explanatory.  Function return type is LRESULT.  But what in the world is that "CALLBACK" doing there?  In Delphi, any function can be used as a callback; you just need to pass the right type of function pointer.  Is there any particular reason why C doesn't work that way?  Or does it mean something different?</p>