Georg Brandl <g.brandl at gmx.net> wrote: > or something like > > m = re.match(...) > if m.group(1) as filename: > do something with filename Except that m could be None, which would raise an exception during the .group(1) call. Perhaps you meant... m = re.match(...) if m and m.group(1) as filename: do something with filename I'm -1 on the 'as'-itis. - Josiah