in reply to Splitting inside an array

As an example from your's This will split on whitespace and some symbols:
my @array = grep(!/^$/, split(/\s+|(:=)|([+-\/\\])/, $var));
There should be a cleaner version that doesn't need the grep, but with my split it gives some null fields.