Changeset 19890

Show
Ignore:
Timestamp:
09/25/08 12:35:04 (5 years ago)
Author:
mizuno_takaaki
Message:

lang/perl/App-Hachero: fixed sort subroutine bug

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • lang/perl/App-Hachero/trunk/lib/App/Hachero/Result.pm

    r19883 r19890  
    3131    my $self = shift; 
    3232    $self->arrayref([]); 
    33     my $package = ref $self; 
    34     no strict 'refs'; 
    35     my $cmp = *{"$package\::cmp"}; 
    36     for my $value (sort $cmp CORE::values %{$self->data}) { 
     33    for my $value (sort _cmp CORE::values %{$self->data}) { 
    3734        CORE::push @{$self->arrayref}, $value; 
    3835    } 
    3936} 
    4037 
    41 sub cmp { 
     38sub _cmp { 
    4239    for (@{__PACKAGE__->primary}) { 
    4340        if (my $res = $a->{$_} cmp $b->{$_}) {