title: What is double evaluation and why should it be avoided?
body: <p>I was reading that in C++ using macros like</p>
  
  <pre><code>#define max(a,b) (a &gt; b ? a : b)
  </code></pre>
  
  <p>can result in a 'double evaluation'. Can someone give me an example of when a double evaluation occurs and why it's bad?</p>
  
  <p>P.S.: Surprisingly I couldn't find any detailed explanation when googling for it except for an example in <a href="http://en.wikipedia.org/wiki/Clojure">Clojure</a> (which I can't understand).</p>