ApSIC Xbench Forum

Regex and/or Power search to assure paired nested parenthesis

#1

Is there a support in POSIX ERE to write regex pattern that supports recursive call to find unbalanced nested parenthesis.

0 Likes

#2

Do you mean to find something like the following?:

Source: (random text between parentheses (more random text between parentheses))
Target: (random text between parentheses (more random text between parentheses)

If that’s the case, I guess you could use the following search:
Source: "\((.+)?\(.+\)(.+)?\)"
Target: -"\((.+)?\(.+\)(.+)?\)"
Power Search: ON
Regular Expression: ON

0 Likes

#3

Yes, this is exactly I meant. Thank you so much.

0 Likes