title: Wrong parse tree while importing multiple grammars
body: <p>I have following grammars for numbers and date:</p>
  
  <p><strong>numbers grammar:</strong></p>
  
  <pre><code>    grammar numbers;
      import DateLexer;
      spelled_first_to_thirty_first:
          int_01_to_31_optional_prefix (TH | ND |RD|ST)
          ;
      int_01_to_31_optional_prefix
          : int_01_to_12
          | int_1_to_5
          | int_6_to_9
          | int_13_to_23
          | int_24_to_31
          ;
      int_13_to_23
          :(('1')('3'|'4'|'5'|int_6_to_9))|(('2')('0'|'1'|'2'|'3'))
          ;
      int_01_to_12 
          :(('0')(int_1_to_5|int_6_to_9))|(('1')('0'|'1'|'2'))
          ;
      int_1_to_5
          : '1'|'2'|'3'|'4'|'5'
          ;
      int_6_to_9
          :'6' | '7' | '8' | '9'
          ;
      int_24_to_31
          :(('2')('4'|'5'|int_6_to_9))|(('3')('0'|'1'|'2'))
          ;
  </code></pre>
  
  <p><strong>date lexer grammar:</strong></p>
  
  <pre><code>        lexer grammar datelex;
          JANUARY   : 'january'   's'?  | 'jan' DOT? ;
          FEBRUARY  : 'february'  's'?  | 'feb' DOT?;
          MARCH     : 'march'     'es'? | 'mar' DOT?;
          APRIL     : 'april'     's'?  | 'apr' DOT?;
          MAY       : 'may'       's'?;
          JUNE      : 'june'      's'?  | 'jun' DOT?;
          JULY      : 'july'      's'?  | 'jul' DOT?;
          AUGUST    : 'august'    's'?  | 'aug' DOT?;
          SEPTEMBER : 'september' 's'?  | 'sep' DOT? | 'sept' DOT?;
          OCTOBER   : 'october'   's'?  | 'oct' DOT?;
          NOVEMBER  : 'november'  's'?  | 'nov' DOT?;
          DECEMBER  : 'december'  's'?  | 'dec' DOT?;
  </code></pre>
  
  <p><strong>date grammar:</strong></p>
  
  <pre><code>        grammar Date;
          import dateLex,numbers;
          d:day_of_month;
  
          month
          : JANUARY
          | FEBRUARY
          | MARCH
          | APRIL
          | MAY
          | JUNE
          | JULY
          | AUGUST
          | SEPTEMBER
          | OCTOBER
          | NOVEMBER
          | DECEMBER
          ;
  
          day_of_month
          : spelled_first_to_thirty_first 'of'? month;
  </code></pre>
  
  <p>first of all I test the numbers grammar with <code>15th</code> and i got this parse tree:</p>
  
  <p><code>(r (spelled_first_to_thirty_first (int_01_to_31_optional_prefix (int_13_to_23 1 5)) th))</code></p>
  
  <p>and it seems right but when i test the date grammar with <code>15th of sep</code> i got this pars tree:</p>
  
  <pre><code>(d (day_of_month (spelled_first_to_thirty_first (int_01_to_31_optional_prefix (int_1_to_5 1)) 5) of (month sep)))
  </code></pre>
  
  <p>which is wrong because it separates 1 and 5 in <code>15</code> and recognize it as a number <code>1</code>.
   why this happen? what should i do to fix this problem?</p>