Regex lookahead example not as stated in Camel 4th

Aaron Crane perl at
Wed Jun 19 15:53:31 BST 2013

Bob MacCallum <uncoolbob at> wrote:
> From my reading of the 5.12 perlre docs, there is no mention of moving the
> cursor along by one position after each match.
> Maybe that is a more general thing I wasn't aware of.

Yes, though only when the match was zero-length.  This is done on the
grounds that an infinite loop would be a relatively unhelpful outcome
in such situations.

The documentation for this feature in 5.12 is here:

but I suggest reading the latest version, as it's been expanded a
little (without any change to the underlying feature):

Aaron Crane **

More information about the mailing list