Tim Roberts wrote: > "OKB (not okblacke)" <[EMAIL PROTECTED]> wrote: >> >> For years now Python has not supported variable-length >> lookbehinds. >>I'm just curious whether there are any plans to change this in >>Python 3.0, or before, or after. It seems that Perl 6 will allow >>variable- width lookbehinds (see >>http://dev.perl.org/perl6/doc/design/apo/A05.html and >>http://dev.perl.org/perl6/rfc/72.html ). > > If I may be just a bit catty, your last sentence may actually be > the best reason NOT to include it in Python 3.0. Perl 6 has become > a worthy successor to ALGOL 68 and PL/I. They are attempting to > pack in every feature that has ever been requested by every person > in the known universe.
That's as may be, but if I may be a bit redundant with myself, I'd like to reiterate that I don't see this is as a new "feature". Regular expressions already exist in Python. Lookbehinds already exist in Python regular expressions. The only thing that doesn't exist is the ability to use arbitrary regular expressions in lookbehinds, and my understanding is that this is just because regular expression engines have typically been implemented in a way that makes this hard to add on. In other words, what I'm describing isn't an extension of what regular expressions are, it's just the lifting of a bothersome implementation- based restriction on one aspect of their use. -- --OKB (not okblacke) Brendan Barnwell "Do not follow where the path may lead. Go, instead, where there is no path, and leave a trail." --author unknown -- http://mail.python.org/mailman/listinfo/python-list