title: Qt Creator's intellisense thinks that min and max were defined even though they weren't
body: <p>In my code I have</p>
  
  <pre><code>#define NOMINMAX
  #include &lt;windows.h&gt;
  </code></pre>
  
  <p>But whenever I use <code>std::max</code> or <code>std::min</code> the intellisense <strong>underlines the line with red</strong>, even though the compiler does not complain about it. If I change the code to</p>
  
  <pre><code>#define NOMINMAX
  #include &lt;windows.h&gt;
  
  // make sure they min/max weren't defined
  #if defined(min) || defined(max)
  #error "min or max were defined"
  #endif
  
  // but intellisense still thinks they were, 
  // so this is needed
  #undef min
  #undef max
  </code></pre>
  
  <p>the problem disappears. But defining <code>NOMINMAX</code> prevents <code>windows.h</code> from defining min/max, so why is intellisense thinking that they were defined, even though they were not? And I've checked, the preprocessor error I've added is never hit.</p>