a little parser, like boost::spirit::qi