in reply to Re: Can I use backreferences as quantifiers in a regex?
in thread Can I use backreferences as quantifiers in a regex?

This works beautifully.

I tried this without the ^N for a while, but couldn't get the backreferences to work. Thanks for the new knowledge about the 'postponed eval' and the ^N.

I had seen the postponed eval previously, but had stayed away from trying it due to the comments about 'highly experimental'.

Thanks for everyone's help!

johnbo
  • Comment on Re^2: Can I use backreferences as quantifiers in a regex?

Replies are listed 'Best First'.
Re^3: Can I use backreferences as quantifiers in a regex?
by ikegami (Patriarch) on Mar 30, 2009 at 06:12 UTC

    $1 could be used for the first $^N, and $2 the second, but $^N is more meaningful.

    They're not that experimental, and they're require to do what you want to do in a match op.