[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

[SCM] Debian package checker branch, master, updated. 2.2.12-15-g67f5991



The following commit has been merged in the master branch:
commit 67f5991033d5e15a2908891e44e181b8650f223c
Author: Russ Allbery <rra@debian.org>
Date:   Mon Jun 22 15:55:19 2009 -0700

    Only strip periods and similar from the ends of words for spellchecking
    
    * lib/Spelling.pm:
      + [RA] Only strip most punctuation from the end of each word, not from
        anywhere in the string.  We don't want to strip the period from
        res.size.  Thanks, Zack Weinberg.  (Closes: #534234)

diff --git a/debian/changelog b/debian/changelog
index 488296a..78ca5d1 100755
--- a/debian/changelog
+++ b/debian/changelog
@@ -33,6 +33,9 @@ lintian (2.2.13) UNRELEASED; urgency=low
   * lib/Spelling.pm:
     + [RA] Add changes misspelling.
     + [RA] Fix correction for endianness.  Thanks, Raphael Geissert.
+    + [RA] Only strip most punctuation from the end of each word, not from
+      anywhere in the string.  We don't want to strip the period from
+      res.size.  Thanks, Zack Weinberg.  (Closes: #534234)
   * lib/Tags.pm:
     + [RA] Replace all newlines in tag data with \n, not just the first.
       (Closes: #534141)
diff --git a/lib/Spelling.pm b/lib/Spelling.pm
index b33ffa8..ab046a5 100644
--- a/lib/Spelling.pm
+++ b/lib/Spelling.pm
@@ -575,9 +575,10 @@ sub spelling_check {
     return unless $text;
 
     $text = lc $text;
-    $text =~ s/[.,;:?!()[\]]//g;
+    $text =~ s/[()[\]]//g;
 
     for my $word (split(/\s+/, $text)) {
+        $word =~ s/[.,;:?!]+$//;
         if (exists $CORRECTIONS{$word}) {
             _tag($tag, $filename, $word, $CORRECTIONS{$word});
         }

-- 
Debian package checker


Reply to: