Also note that if you have a tokeniser as a regexp, then once you've eliminated left-recursion from a grammar it's dead easy to write a pure perl parser for that grammar without using a parser module. See XML::XPath::Parser for an example of this, and also XML::SAX::PurePerl.