title: How to draw a square with SDL 2.0?
body: <p>I would like to do something simple like draw a square on the screen using C and SDL. The example that I copied is not working.</p>
  
  <pre><code>//Get window surface
  SDL_Surface *screenSurface = SDL_GetWindowSurface(window);
  
  //Fill the surface white
  SDL_FillRect(screenSurface, NULL, SDL_MapRGB(screenSurface-&gt;format, 0xFF, 0xFF, 0xFF));
  
  //create a square
  SDL_FillRect(screenSurface, SDL_Rect(0,0,100,100), SDL_MapRGB(screenSurface-&gt;format, 0x00, 0x00, 0x00));
  </code></pre>
  
  <p>It correctly fills the screen white, but fails on the call to <code>SDL_Rect</code>:</p>
  
  <pre><code>error: expected expression before ‘SDL_Rect’
  </code></pre>
  
  <p>How do I correctly draw a square using SDL 2.0?</p>