Skip to content

Commit

Permalink
[System.Private.CoreLib] Remove unused Array methods
Browse files Browse the repository at this point in the history
Commit migrated from mono/mono@965bead
  • Loading branch information
marek-safar committed Nov 6, 2019
1 parent 492c50c commit 35bac72
Showing 1 changed file with 0 additions and 25 deletions.
25 changes: 0 additions & 25 deletions src/mono/netcore/System.Private.CoreLib/src/System/Array.Mono.cs
Original file line number Diff line number Diff line change
Expand Up @@ -423,29 +423,6 @@ public void SetValue (object? value, int index1, int index2, int index3)
SetValue (value, ind);
}

static void SortImpl (Array keys, Array? items, int index, int length, IComparer comparer)
{
/* TODO: CoreCLR optimizes this case via an internal call
if (comparer == Comparer.Default)
{
bool r = TrySZSort(keys, items, index, index + length - 1);
if (r)
return;
}*/

object[]? objKeys = keys as object[];
object[]? objItems = null;
if (objKeys != null)
objItems = items as object[];
if (objKeys != null && (items == null || objItems != null)) {
SorterObjectArray sorter = new SorterObjectArray (objKeys, objItems, comparer);
sorter.Sort(index, length);
} else {
SorterGenericArray sorter = new SorterGenericArray (keys, items, comparer);
sorter.Sort(index, length);
}
}

static bool TrySZBinarySearch (Array sourceArray, int sourceIndex, int count, object? value, out int retVal)
{
retVal = default;
Expand All @@ -466,8 +443,6 @@ static bool TrySZLastIndexOf (Array sourceArray, int sourceIndex, int count, obj

static bool TrySZReverse (Array array, int index, int count) => false;

static bool TrySZSort (Array keys, Array? items, int left, int right) => false;

public int GetUpperBound (int dimension)
{
return GetLowerBound (dimension) + GetLength (dimension) - 1;
Expand Down

0 comments on commit 35bac72

Please sign in to comment.