in reply to Re: How to find the outermost pair of square brackets with a regex?
in thread How to find the outermost pair of square brackets with a regex?

that's beautiful... so, if i have this right... match the first bracket, IF, non-backtracking, we find an additional or , then recurse, match the last bracket? what is the purpose of the ^?
  • Comment on Re^2: How to find the outermost pair of square brackets with a regex?
  • Download Code

Replies are listed 'Best First'.
Re^3: How to find the outermost pair of square brackets with a regex?
by lokiloki (Beadle) on Jan 17, 2007 at 01:20 UTC
    sorry, i meant to say...

    that's beautiful...

    so, if i have this right... match the first bracket; IF, non-backtracking, we find an additional [ or ], then recurse; match the last bracket?

    what is the purpose of the ^?

      oops, caret is inverted character class
    A reply falls below the community's threshold of quality. You may see it by logging in.