in reply to Unusual sorting requirements; comparing three implementations.
keysort is an XS implementation of the Schwartzian transformWell, not really. It is more like this:
sub sortkey (\&@) { my $calc_key = shift; my @key = map $calc_key->(), @_; return @_[sort { $key[$a] cmp $key[$b] } 0..$#_]; }
In Section
Meditations