Skip to content

Add warning, that keys and items parameters must not refer to the same array. #3163

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
CeciAc opened this issue Sep 10, 2019 · 2 comments
Open
Labels
area-System.Runtime doc-enhancement Improve the current content dotnet-api/prod Pri2 Indicates issues/PRs that are medium priority
Milestone

Comments

@CeciAc
Copy link

CeciAc commented Sep 10, 2019

@NineBerry commented on Tue Sep 10 2019

When passing the same array as both keys and items parameter, in some situations you will get an ArgumentException stating that the "IComparer.Compare() method returns inconsistent results" and in some situations the sort order will just be wrong without getting any exception.

Add a remark in the documentation that this is not allowed.

Additionally, the framework code could actually be changed to check that both arguments don't refer to the same array object.


Dokumentdetails

Bearbeiten Sie diesen Abschnitt nicht. Er ist für die Verknüpfung von docs.microsoft.com zum GitHub-Artikel erforderlich.


@srvbpigh commented on Tue Sep 10 2019

Hello, @NineBerry

Thank you for your feedback.

We are actively reviewing your comments and will get back to you soon.

Kind regards,
Microsoft DOCS International Team

@dotnet-bot dotnet-bot added untriaged New issue has not been triaged by the area owner Source - Docs.ms labels Sep 10, 2019
@CeciAc
Copy link
Author

CeciAc commented Sep 10, 2019

Hi team,
I'm moving this here because the user is making a suggestion to the original documentation
best regards

@CeciAc CeciAc closed this as completed Sep 10, 2019
@CeciAc CeciAc reopened this Sep 10, 2019
@NineBerry
Copy link

NineBerry commented Sep 11, 2019

@mairaw mairaw added doc-enhancement Improve the current content and removed untriaged New issue has not been triaged by the area owner labels Oct 23, 2019
@mairaw mairaw added this to the Backlog milestone Oct 23, 2019
@PRMerger9 PRMerger9 added the Pri2 Indicates issues/PRs that are medium priority label Jan 16, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-System.Runtime doc-enhancement Improve the current content dotnet-api/prod Pri2 Indicates issues/PRs that are medium priority
Projects
None yet
Development

No branches or pull requests

8 participants