You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucenenet.apache.org by ni...@apache.org on 2017/03/30 18:00:00 UTC
[05/50] lucenenet git commit: Lucene.Net.Core.Search.PhraseQuery:
Replaced ValueList with EquatableList and changed SequenceEqual to
Equals on those lists.
Lucene.Net.Core.Search.PhraseQuery: Replaced ValueList<T> with EquatableList<T> and changed SequenceEqual to Equals on those lists.
Project: http://git-wip-us.apache.org/repos/asf/lucenenet/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucenenet/commit/aa3a11aa
Tree: http://git-wip-us.apache.org/repos/asf/lucenenet/tree/aa3a11aa
Diff: http://git-wip-us.apache.org/repos/asf/lucenenet/diff/aa3a11aa
Branch: refs/heads/api-work
Commit: aa3a11aaa6d43ac6f3fb3838b6dc9f71708c5c24
Parents: 71fab05e6
Author: Shad Storhaug <sh...@shadstorhaug.com>
Authored: Thu Mar 30 05:54:40 2017 +0700
Committer: Shad Storhaug <sh...@shadstorhaug.com>
Committed: Thu Mar 30 09:12:28 2017 +0700
----------------------------------------------------------------------
src/Lucene.Net.Core/Search/PhraseQuery.cs | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/aa3a11aa/src/Lucene.Net.Core/Search/PhraseQuery.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Core/Search/PhraseQuery.cs b/src/Lucene.Net.Core/Search/PhraseQuery.cs
index 9686b6a4..12ea55f 100644
--- a/src/Lucene.Net.Core/Search/PhraseQuery.cs
+++ b/src/Lucene.Net.Core/Search/PhraseQuery.cs
@@ -51,8 +51,8 @@ namespace Lucene.Net.Search
public class PhraseQuery : Query
{
private string field;
- private List<Term> terms = new ValueList<Term>(4);
- private List<int?> positions = new ValueList<int?>(4);
+ private IList<Term> terms = new EquatableList<Term>(4);
+ private IList<int?> positions = new EquatableList<int?>(4);
private int maxPosition = 0;
private int slop = 0;
@@ -502,8 +502,8 @@ namespace Lucene.Net.Search
PhraseQuery other = (PhraseQuery)o;
return (this.Boost == other.Boost)
&& (this.slop == other.slop)
- && this.terms.SequenceEqual(other.terms)
- && this.positions.SequenceEqual(other.positions);
+ && this.terms.Equals(other.terms)
+ && this.positions.Equals(other.positions);
}
/// <summary>