+ // Prototype of the yylex function providing subsequent tokens.
+ static yy::parser::token_type yylex(yy::parser::semantic_type* yylval);
+
+ // Printing a list of strings.
+ // Koening look up will look into std, since that's an std::list.
+ namespace std
+ {
+ std::ostream&
+ operator<<(std::ostream& o, const strings_type& s)
+ {
+ std::copy(s.begin(), s.end(),
+ std::ostream_iterator<strings_type::value_type>(o, "\n"));
+ return o;
+ }
+ }
+
+ // Conversion to string.
+ template <typename T>
+ inline
+ std::string
+ string_cast (const T& t)
+ {
+ std::ostringstream o;
+ o << t;
+ return o.str();
+ }