diff --git a/src/main/net-core/Diff/DOMDifferenceEngine.cs b/src/main/net-core/Diff/DOMDifferenceEngine.cs index 6a1d90a..0931efb 100644 --- a/src/main/net-core/Diff/DOMDifferenceEngine.cs +++ b/src/main/net-core/Diff/DOMDifferenceEngine.cs @@ -468,13 +468,11 @@ private ComparisonState CompareNodeLists(IEnumerable allControlChildren IEnumerable> matches = NodeMatcher.Match(controlSeq, testSeq); - IList controlListForXpath = new List(allControlChildren); - IList testListForXpath = new List(allTestChildren); IList controlList = new List(controlSeq); IList testList = new List(testSeq); - IDictionary controlListForXpathIndex = Index(controlListForXpath); - IDictionary testListForXpathIndex = Index(testListForXpath); + IDictionary controlListForXpathIndex = Index(allControlChildren); + IDictionary testListForXpathIndex = Index(allTestChildren); IDictionary controlListIndex = Index(controlList); IDictionary testListIndex = Index(testList); @@ -743,7 +741,7 @@ private static XmlAttribute FindMatchingAttr(IList attrs, return null; } - private static IDictionary Index(IList nodes) { + private static IDictionary Index(IEnumerable nodes) { IDictionary indices = new Dictionary(); int idx = 0; foreach (XmlNode n in nodes) {