summaryrefslogtreecommitdiffstats
path: root/perl-install/common.pm
diff options
context:
space:
mode:
authorFrancois Pons <fpons@mandriva.com>2001-04-12 11:35:46 +0000
committerFrancois Pons <fpons@mandriva.com>2001-04-12 11:35:46 +0000
commitcc3321b90b2ee25deec842e1177d57bd92a4de87 (patch)
treee0fc2d99828d831a48c2bed503a46df465b8802f /perl-install/common.pm
parent4fc46b7ce637145bafac5682a06d915776fbecb4 (diff)
downloaddrakx-backup-do-not-use-cc3321b90b2ee25deec842e1177d57bd92a4de87.tar
drakx-backup-do-not-use-cc3321b90b2ee25deec842e1177d57bd92a4de87.tar.gz
drakx-backup-do-not-use-cc3321b90b2ee25deec842e1177d57bd92a4de87.tar.bz2
drakx-backup-do-not-use-cc3321b90b2ee25deec842e1177d57bd92a4de87.tar.xz
drakx-backup-do-not-use-cc3321b90b2ee25deec842e1177d57bd92a4de87.zip
improved bestMatchSentence2.
Diffstat (limited to 'perl-install/common.pm')
-rw-r--r--perl-install/common.pm3
1 files changed, 3 insertions, 0 deletions
diff --git a/perl-install/common.pm b/perl-install/common.pm
index ab5c9419d..ab08ad4a1 100644
--- a/perl-install/common.pm
+++ b/perl-install/common.pm
@@ -568,6 +568,9 @@ sub bestMatchSentence2 {
foreach (@_) {
my $count = 0;
foreach my $e (@s) {
+ $count+= length ($e) if /^$e$/;
+ $count+= length ($e) if /^$e$/i;
+ $count+= length ($e) if /$e/;
$count+= length ($e) if /$e/i;
}
$best = $count, $bestSentence = $_ if $count > $best;