in reply to Re: Re: Best way to extract RE backreferences
in thread Best way to extract RE backreferences

However if you wanted to save only a subset of the saved subexpressions, the ()'s around the match will let you use brackets to get a slice (but then you might be better off using non-capturing parens instead).

<nit>Maybe. You might have a large parsing regex that's been compiled with /o and you want the 3rd through 9th columns of 12 columns.</nit>

------
We are the carpenters and bricklayers of the Information Age.

Don't go borrowing trouble. For programmers, this means Worry only about what you need to implement.

  • Comment on Re: Re: Re: Best way to extract RE backreferences

Replies are listed 'Best First'.
Re^4: Best way to extract RE backreferences
by Aristotle (Chancellor) on Feb 06, 2003 at 12:33 UTC
    Your objection is valid but you shouldn't be using /o anymore. We have qr() now.

    Makeshifts last the longest.