title: Internal compiler error with Boost.Spirit
body: <p>I'm trying to compile the following seemingly simple code using GCC 3.4.6 and Boost 1.43 and it's generating an internal compiler error:</p>
  
  <pre><code>#include &lt;string&gt;
  #include &lt;boost/spirit/include/lex_lexertl.hpp&gt;
  #include &lt;boost/spirit/include/qi.hpp&gt;
  
  namespace lex    = boost::spirit::lex;
  namespace qi     = boost::spirit::qi;
  
  typedef lex::lexertl::token&lt;std::string::iterator&gt; TokenT;
  typedef lex::lexertl::actor_lexer&lt;TokenT&gt; LexerT;
  
  template &lt;typename LexerT&gt;
  struct Tokens: public lex::lexer&lt;LexerT&gt;
  {};
  
  int main()
  {
     typedef Tokens&lt;LexerT&gt;::iterator_type IteratorT;
     qi::rule&lt;IteratorT, int&gt; expression;
  
     expression = (qi::int_ &gt;&gt; qi::int_) [ qi::_val = qi::_1 ];
  }
  </code></pre>
  
  <p>The generated error:</p>
  
  <pre><code>.../boost/mpl/aux_/preprocessed/gcc/template_arity.hpp:83: internal compiler error: in lookup_member, at cp/search.c:1300
  </code></pre>
  
  <p>The last line in <code>main()</code> is generating this error. This error goes away by either letting the <code>expression</code> rule work on an <code>std::string::iterator</code> instead of <code>IteratorT</code>.</p>
  
  <p>Any help with fixing the error while still working with a lexer is much appreciated.</p>
  
  <p>Thanks!</p>