Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

pedrobsaila
Copy link
Contributor

Fixes #96116

@ghost ghost added area-System.Collections community-contribution Indicates that the PR has been added by a community member labels Dec 21, 2023
@ghost
Copy link

ghost commented Dec 21, 2023

Tagging subscribers to this area: @dotnet/area-system-collections
See info in area-owners.md if you want to be subscribed.

Issue Details

Fixes #96116

Author: pedrobsaila
Assignees: -
Labels:

area-System.Collections

Milestone: -

@eiriktsarpalis
Copy link
Member

@pedrobsaila before we get this merged, has the new proxy type been tested? I believe we write unit tests for a few other collections types, for example this one:

https://github.com/dotnet/runtime/blob/c31a2173e5a8b2cdef94b986504cf23b9a6bb175/src/libraries/Common/tests/System/Collections/DebugView.Tests.cs

@pedrobsaila
Copy link
Contributor Author

Tested it only locally inside VS, did not make a unit test yet.

@eiriktsarpalis
Copy link
Member

Would you be ok adding a unit test in the mold of what I shared from collections?

@pedrobsaila
Copy link
Contributor Author

pedrobsaila commented Jan 9, 2024

Would you be ok adding a unit test in the mold of what I shared from collections?

yes for sure. I'll push the tests whithin a few hours

{
}

public Func<TValue, TKey> GetKeyForItemHandler { get; set; }
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: I think some of that indirection could be removed if you just made the derived type non-generic and inlined the GetKeyBehavior in the implementation.

Copy link
Member

@eiriktsarpalis eiriktsarpalis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. I left some feedback on a minor nitpick on the test, but it's up to you if you want to address it. Thanks!

@eiriktsarpalis eiriktsarpalis merged commit 525a6d7 into dotnet:main Jan 12, 2024
@pedrobsaila pedrobsaila deleted the 96116 branch January 12, 2024 15:24
tmds pushed a commit to tmds/runtime that referenced this pull request Jan 23, 2024
* KeyedCollection debug view doesn't work

* fix remarks 1

* fix remarks 2

* add tests
@github-actions github-actions bot locked and limited conversation to collaborators Feb 12, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-System.Collections community-contribution Indicates that the PR has been added by a community member
Projects
None yet
Development

Successfully merging this pull request may close these issues.

KeyedCollection debug view doesn't work
4 participants