That's endemic to how Switch works, unfortunately. If you're using Perl 5.10 or newer, you can use the given/when construct instead.
In reply to Re: Switch.pm Regular Expression matches getting clobbered?
by chromatic
in thread Switch.pm Regular Expression matches getting clobbered?
by AxleUK
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |