Consider the following pattern, which contains non-significant white space to make it more readable (assume the PCRE_EXTENDED option) and to divide it into three parts for ease of discussion: (\ ()? [^()] + (?(1)\)) The first part matches an optional opening parenthesis, and if that character is present, sets it as the first capturedConsider the following pattern, which contains non-significant white space to make it more readable (assume the PCRE_EXTENDED option) and to divide it into three parts for ease of discussion: (\ ()? [^()] + (?(1)\)) The first part matches an optional opening parenthesis, and if that character is present, sets it as the first captured substring.
end of subject or newline at end (independent of multiline mode)