Steven D'Aprano <st...@remove-this-cybersource.com.au> writes: > One disadvantage is that you have to learn an entire new language, a > language which is painfully terse and obfuscated, with virtually no > support for debugging. Larry Wall has criticised the Perl regex syntax on > a number of grounds: ...
There is a parser combinator library for Python called Pyparsing but it is apparently dog slow. Maybe someone can do a faster one sometime. See: http://pyparsing.wikispaces.com/ for info. I haven't used it, but it is apparently similar in style to Parsec (a Haskell library): http://research.microsoft.com/users/daan/download/papers/parsec-paper.pdf I use Parsec sometimes, and it's much nicer than complicated regexps. There is a version called Attoparsec now that is slightly less powerful but very fast. -- http://mail.python.org/mailman/listinfo/python-list