in reply to split on spaces, except those within quotes?

I would use a negative look ahead: my @arr = split /\s(?!\w+')/, $string;
  • Comment on Re: split on spaces, except those within quotes?