By that logic an unmatched ')' doesn't mean anything so shouldn't need to be escaped, yet it generates an error.
japhy's eplanation is satisfying for unmatched '{' and '}' and extends to an unmatched ']' too. Why not extend the argument to an unmatched ')'? Is that so much more likely a "You Really Mean That?" error that it's worth special casing?
In reply to Re^3: Perl Regular Expression inconsistency
by GrandFather
in thread Perl Regular Expression inconsistency
by jkva
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |