I was recently bitten by this, and it's not clear to me (and others) if this is
correct Perl behavior or not.

If you have a user defined function 'func' that returns a list and you'd like to
sort that return value it's reasonable to try:

  sort(func(@list));

but apparently Perl interprets this as:

  sort func @list;

thereby using 'func' as an ordering function instead of first processing '@list'
with 'func' then sorting.  Now I've read the stuff on page 1 of PERLFUNC(1)
about parenthesis and whitespace being optional, but still this just strikes me
as wrong.  No?

Reply via email to