title: Flex C++ - #ifdef inside flex block
body: <p>I want to define constant in preprocessor which launches matching some patterns only when it's defined. Is it possible to do this, or there is the other way how to deal with this problem? 
  i.e. simplified version of removing one-line comments in C:</p>
  
  <pre><code>%{
  #define COMMENT
  %}
  
  %%
  #ifdef COMMENT
  [\/][\/].*$ ;
  #endif
  
  [1-9][0-9]* printf("It's a number, and it works with and without defining COMMENT");
  %%
  </code></pre>