Skip to content
This repository has been archived by the owner on Jan 23, 2023. It is now read-only.
/ corefx Public archive

Commit

Permalink
Fix bogus assert in ArraySortHelper (dotnet/corert#6018)
Browse files Browse the repository at this point in the history
Fixes #6016.
Resolves #6015.

Signed-off-by: dotnet-bot <[email protected]>
  • Loading branch information
MichalStrehovsky authored and stephentoub committed Jun 27, 2018
1 parent a74bf42 commit 5678fe6
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -654,10 +654,10 @@ public void Sort(TKey[] keys, TValue[] values, int index, int length, IComparer<
private static void SwapIfGreaterWithItems(TKey[] keys, TValue[] values, IComparer<TKey> comparer, int a, int b)
{
Debug.Assert(keys != null);
Debug.Assert(values != null && values.Length >= keys.Length);
Debug.Assert(values != null);
Debug.Assert(comparer != null);
Debug.Assert(0 <= a && a < keys.Length);
Debug.Assert(0 <= b && b < keys.Length);
Debug.Assert(0 <= a && a < keys.Length && a < values.Length);
Debug.Assert(0 <= b && b < keys.Length && b < values.Length);

if (a != b)
{
Expand Down

0 comments on commit 5678fe6

Please sign in to comment.