^\s*[)]*\s*$
and
^\s*[(]*\s*$
matches the brackets `(` and `)` which commented as matched. That is, what am trying is to ignore brackets that are single and not (condition1) brackets.. i want to regex to match the brackets which are commented as not matched.. ie 1 or more brackets on the same line..
while ( #matches here ( #matches here (condition1) && (condition2) && condition3 ) || (#matches here (condition4) || condition5 && (condition6) ) #matches here ) #matches here
but if I have like this it does not match:
while (( #does not match here (condition1) && (condition2) && condition3 ) || ( (condition4) || condition5 && (condition6) ) ) #does not match here
or
while ((( #does not match here (condition1) && (condition2) && condition3 )) || (( #does not match here (condition4) || condition5 && (condition6) ) ) ) #does not match here
How can I match all the brackets that are single?
In reply to doubt on regex by loki
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |