title: Using if else in c macros
body: <p>i'm trying to define the following macro:</p>
  
  <pre><code>#define UTF8_2B(c) if((0xc0 &amp; c) == 0xc0){return 1;}
  </code></pre>
  
  <p>But i'm met with the error:</p>
  
  <pre><code>expected expression before ‘if’
  </code></pre>
  
  <p>The macro is called like so:</p>
  
  <pre><code>int i = UTF8_2B(c);
  </code></pre>
  
  <p>Where c is an unsigned char read from a file.</p>
  
  <p>Why does this happen? Can you not use if else statements in macros?
  Also, I've read that it's not a good idea to use semicolon in your macros, but i didn't understand why. 
  I'm new to c so the more thorough the answer the better.</p>