Well, if you want to keep the stuff you split on, use capturing parentheses. If you don't want to keep the stuff, don't use them. $1 is never set, so the way you are trying it will never work.
In reply to Re^3: Curios use of regular expressions in split
by Corion
in thread Curios use of regular expressions in split
by juliosergio
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |