if the subroutine returns a list I don't want to evaluate it in scalar context and end up with the length.
You wouldn't. You'd get the last element of the list. Not that that's much preferable. If you assigned the results to a list containing one scalar, you'd get the first. You'd have to do the
$bar = () = foo trick to get the length.
my $foo = sub { return (4,5,8) };
# evaluate in (too-short) list context:
my ($bar) = &$foo;
print "Bar=$bar\n";
# evaluate in scalar context:
$bar = &$foo;
print "Bar=$bar\n";
# array context, sort of
$bar = () = &$foo;
print "Bar=$bar\n";
Caution: Contents may have been coded under pressure.