How to use Boost Spirit auto rules with AST?
问题 EDIT: I expanded sehe's example to show the problem when I want to use it on another rule: http://liveworkspace.org/code/22lxL7$17 I'm trying to improve the performances of my Boost Spirit parser and I saw that since C++11, it was possible to use auto-rules like that: auto comment = "/*" >> *(char_ - "*/") >> "*/"; (or with BOOST_AUTO or BOOST_SPIRIT_AUTO). I have a rule declarer like that: qi::rule<lexer::Iterator, ast::SimpleType()> simple_type; and defined like that: simple_type %= const_