title: sizeof operator in #define directives
body: <p>I've been inspecting someone's code and I encountered this:</p>
  
  <pre><code>#else //If not in Debug mode
  
  #define LOG_WARNING(str) do { (void)sizeof(str); } while(0)
  #define LOG_INFO(str) do { (void)sizeof(str); } while(0)
  
  // ... More #define directives
  
  #endif
  </code></pre>
  
  <p>Apparently, <code>do { (void)sizeof(str); } while(0)</code> is carefully written so the directive can be completely ignored by the compiler.</p>
  
  <p>How does this work?</p>