No doubt I should know this regex point but ..
Gustavo Niemeyer
niemeyer at conectiva.com
Thu Aug 14 16:53:09 EDT 2003
> I am writing a class that walks through a file tree and (among other
> things) filters out which files it considers. So I want to have
> __init__( .. ,filterExpression='..') For the default I want to filter
> nothing. So I need a Python regular expression that never matches.
> What is (the best) one?
There are many.. "(?=a)b" is just one of them. OTOH, this is awful. :-)
Do as Aahz suggested and use None as default.
--
Gustavo Niemeyer
http://niemeyer.net
More information about the Python-list
mailing list