title: How to remove the enclosing parentheses with macro?
body: <p>No comma is allowed in a macro argument because it will be treated as more than one arguments and the preprocessing will be wrong. However, we can parenthesize the argument to let preprocessor treat it as one argument. Is there a macro or other techniques which can remove the enclosing parentheses?</p>
  
  <p>For example, if I define a macro like</p>
  
  <pre><code>#define MY_MACRO(a, b)   ...
  </code></pre>
  
  <p>and use it like</p>
  
  <pre><code>MY_MACRO( A&lt;int, double&gt;, text );
  </code></pre>
  
  <p>will be wrong. use it like</p>
  
  <pre><code>MY_MACRO( (A&lt;int, double&gt;), text)
  </code></pre>
  
  <p>with a macro or technique to remove the parentheses will be fine. Boost provides <code>BOOST_IDENTITY_TYPE</code> macro for only types but not general cases</p>