title: Pasting formed an invalid processing token '.'
body: <p>I am trying to use macro for calling appropriate object based on the type.</p>
  
  <pre><code>#define DELEGATE_FUNC(FuncName, kind, paramPtr)         \
      if (kind == 1) {                                    \
          return PolicyObject1.##FuncName(paramPtr);      \
      }                                                   \
      else {                                              \
          return PolicyObject2.##FuncName(paramPtr);      \
      }                                                   \
      return 0;                                           \
  </code></pre>
  
  <p>(PolicyObject1 &amp; PolicyObject2 are two static objects.)
  Now when using the macro, e.g.</p>
  
  <p>DELEGATE_FUNC(ProcessPreCreate, 1, null_ptr);</p>
  
  <p>It compiles fine in VS 2015, but gives error with LLVM "Pasting formed an invalid processing token '.ProcessPreCreate'"</p>
  
  <p>I looked for, and found a few posts and understood it up to some level - Need double level of indirection, e.g.
  <a href="https://stackoverflow.com/questions/8231966/why-do-i-need-double-layer-of-indirection-for-macros">Why do I need double layer of indirection for macros?</a></p>
  
  <p>However I am unable to define those two layers of macro, can anyone help?</p>
  
  <p>(Please leave aside the discussion on design aspects)</p>
  
  <p>Thanks</p>