use strict; use warnings; use Text::ParseWords; my @words = quotewords(',', 0, q{"Foo,Bar","","Blah"}); print "$_\n" for @words;