sub trim { @_ = @_ ? @_ : $_ if defined wantarray; # disconnect aliases in non-void context for (@_ ? @_ : $_) { s/\A\s+//; s/\s+\z// } return wantarray ? @_ : "@_"; }