[^\[\]] does match newline.
>perl -le "print( qq{\n} =~ /[^\[\]]/ ?1:0) 1
In reply to Re^5: How to find the outermost pair of square brackets with a regex?
by ikegami
in thread How to find the outermost pair of square brackets with a regex?
by lokiloki
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |