title: Zero size struct
body: <p>I noticed that when compiled with GCC 4.6 <code>sizeof(Foo)</code> is 0 and <code>sizeof(Bar)</code> is 1. For some reason adding an empty array into an empty structure made its size 0. I thought that the sizes of both structures must be the same. What is going on here?</p>
  
  <pre><code>struct Foo
  {
      char x[];
  };
  
  struct Bar {};
  </code></pre>