lucenenet-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From synhers...@apache.org
Subject [46/50] [abbrv] lucenenet git commit: Fixed math bugs in the Analysis.De.GermanStemmer class that were causing Analysis.De.TestGermanAnalyzer.TestGermanSpecials() and Analysis.De.TestGermanStemFilter.TestStemming() tests to fail
Date Tue, 23 Aug 2016 23:18:39 GMT
Fixed math bugs in the Analysis.De.GermanStemmer class that were causing Analysis.De.TestGermanAnalyzer.TestGermanSpecials()
and Analysis.De.TestGermanStemFilter.TestStemming() tests to fail


Project: http://git-wip-us.apache.org/repos/asf/lucenenet/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucenenet/commit/56cdc043
Tree: http://git-wip-us.apache.org/repos/asf/lucenenet/tree/56cdc043
Diff: http://git-wip-us.apache.org/repos/asf/lucenenet/diff/56cdc043

Branch: refs/heads/analysis-work
Commit: 56cdc043a040d556afccea931fa2e0d24ca24d94
Parents: b04aca6
Author: Shad Storhaug <shad@shadstorhaug.com>
Authored: Tue Aug 23 11:57:34 2016 +0700
Committer: Shad Storhaug <shad@shadstorhaug.com>
Committed: Tue Aug 23 11:57:34 2016 +0700

----------------------------------------------------------------------
 .../Analysis/De/GermanStemmer.cs                          | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucenenet/blob/56cdc043/src/Lucene.Net.Analysis.Common/Analysis/De/GermanStemmer.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Analysis.Common/Analysis/De/GermanStemmer.cs b/src/Lucene.Net.Analysis.Common/Analysis/De/GermanStemmer.cs
index 8b260be..2338085 100644
--- a/src/Lucene.Net.Analysis.Common/Analysis/De/GermanStemmer.cs
+++ b/src/Lucene.Net.Analysis.Common/Analysis/De/GermanStemmer.cs
@@ -100,15 +100,15 @@ namespace Lucene.Net.Analysis.De
             {
                 if ((buffer.Length + substCount > 5) && buffer.ToString(buffer.Length
- 2, buffer.Length - (buffer.Length - 2)).Equals("nd"))
                 {
-                    buffer.Remove(buffer.Length - 2, buffer.Length - buffer.Length - 2);
+                    buffer.Remove(buffer.Length - 2, buffer.Length - (buffer.Length - 2));
                 }
                 else if ((buffer.Length + substCount > 4) && buffer.ToString(buffer.Length
- 2, buffer.Length - (buffer.Length - 2)).Equals("em"))
                 {
-                    buffer.Remove(buffer.Length - 2, buffer.Length - buffer.Length - 2);
+                    buffer.Remove(buffer.Length - 2, buffer.Length - (buffer.Length - 2));
                 }
                 else if ((buffer.Length + substCount > 4) && buffer.ToString(buffer.Length
- 2, buffer.Length - (buffer.Length - 2)).Equals("er"))
                 {
-                    buffer.Remove(buffer.Length - 2, buffer.Length - buffer.Length - 2);
+                    buffer.Remove(buffer.Length - 2, buffer.Length - (buffer.Length - 2));
                 }
                 else if (buffer[buffer.Length - 1] == 'e')
                 {
@@ -165,7 +165,7 @@ namespace Lucene.Net.Analysis.De
                 {
                     if (buffer.ToString(c, 4).Equals("gege"))
                     {
-                        buffer.Remove(c, c + 2 - c);
+                        buffer.Remove(c, (c + 2) - c);
                         return;
                     }
                 }
@@ -219,7 +219,7 @@ namespace Lucene.Net.Analysis.De
                     if ((c < buffer.Length - 2) && buffer[c] == 's' &&
buffer[c + 1] == 'c' && buffer[c + 2] == 'h')
                     {
                         buffer[c] = '$';
-                        buffer.Remove(c + 1, c + 3 - c + 1);
+                        buffer.Remove(c + 1, (c + 3) - (c + 1));
                         substCount = +2;
                     }
                     else if (buffer[c] == 'c' && buffer[c + 1] == 'h')


Mime
View raw message