lucenenet-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From synhers...@apache.org
Subject [7/7] lucenenet git commit: Fixing compilation
Date Fri, 14 Nov 2014 11:06:55 GMT
Fixing compilation


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

Branch: refs/heads/master
Commit: 58ccdea29c3221ba931f0692a364f50d5857024a
Parents: f173e12
Author: Itamar Syn-Hershko <itamar@code972.com>
Authored: Fri Nov 14 13:05:32 2014 +0200
Committer: Itamar Syn-Hershko <itamar@code972.com>
Committed: Fri Nov 14 13:05:32 2014 +0200

----------------------------------------------------------------------
 src/Lucene.Net.Core/Document/Field.cs                          | 3 +--
 src/Lucene.Net.Core/Support/Number.cs                          | 5 -----
 .../Index/BaseStoredFieldsFormatTestCase.cs                    | 6 +++---
 3 files changed, 4 insertions(+), 10 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucenenet/blob/58ccdea2/src/Lucene.Net.Core/Document/Field.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Core/Document/Field.cs b/src/Lucene.Net.Core/Document/Field.cs
index d93f0f4..2c20987 100644
--- a/src/Lucene.Net.Core/Document/Field.cs
+++ b/src/Lucene.Net.Core/Document/Field.cs
@@ -582,7 +582,6 @@ namespace Lucene.Net.Documents
             {
                 return null;
             }
-            Number n = new Number();
             FieldType.NumericType? numericType = ((FieldType)FieldType()).NumericTypeValue;
             if (numericType != null)
             {
@@ -592,7 +591,7 @@ namespace Lucene.Net.Documents
                     // (attributes,...) if not needed (stored field loading)
                     InternalTokenStream = new NumericTokenStream(Type.NumericPrecisionStep);
                 }
-                NumericTokenStream nts = (NumericTokenStream)InternalTokenStream;
+                var nts = (NumericTokenStream)InternalTokenStream;
                 // initialize value in TokenStream
                 object val = FieldsData;
                 switch (numericType)

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/58ccdea2/src/Lucene.Net.Core/Support/Number.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Core/Support/Number.cs b/src/Lucene.Net.Core/Support/Number.cs
index e3f0744..7b689d9 100644
--- a/src/Lucene.Net.Core/Support/Number.cs
+++ b/src/Lucene.Net.Core/Support/Number.cs
@@ -497,10 +497,5 @@ namespace Lucene.Net.Support
                    || value is double
                    || value is decimal;
         }
-
-        public static long DoubleToRawLongBits(double d)
-        {
-            return BitConverter.DoubleToInt64Bits(d);
-        }
     }
 }
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/58ccdea2/src/Lucene.Net.TestFramework/Index/BaseStoredFieldsFormatTestCase.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.TestFramework/Index/BaseStoredFieldsFormatTestCase.cs b/src/Lucene.Net.TestFramework/Index/BaseStoredFieldsFormatTestCase.cs
index c885649..7e555ee 100644
--- a/src/Lucene.Net.TestFramework/Index/BaseStoredFieldsFormatTestCase.cs
+++ b/src/Lucene.Net.TestFramework/Index/BaseStoredFieldsFormatTestCase.cs
@@ -262,9 +262,9 @@ namespace Lucene.Net.Index
         public void TestNumericField()
         {
             Directory dir = NewDirectory();
-            RandomIndexWriter w = new RandomIndexWriter(Random(), dir);
-            int numDocs = AtLeast(500);
-            object[] answers = new Number[numDocs];
+            var w = new RandomIndexWriter(Random(), dir);
+            var numDocs = AtLeast(500);
+            var answers = new object[numDocs];
             FieldType.NumericType[] typeAnswers = new FieldType.NumericType[numDocs];
             for (int id = 0; id < numDocs; id++)
             {


Mime
View raw message