On Wed, Apr 30, 2008 at 6:21 PM, Tony Cook <tony@develop-help.com> wrote: > > But perhaps it could/should be documented more clearly... (I can't > > easily find it in perlre for example - or atleast not using a basic > > search) > > From perlop: > > If the PATTERN evaluates to the empty string, the last success- > fully matched regular expression is used instead. In this case, > only the "g" and "c" flags on the empty pattern is honoured - > the other flags are taken from the original pattern. If no > match has previously succeeded, this will (silently) act > instead as a genuine empty pattern (which will always match). > this comes up enough that an EMPTY PATTERN section, with an example of how to use the feature, stuns by its absence.Thread Previous