Skip to content
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

Fix ConcurrentDictionary test by rooting members accessed via reflection #81957

Merged
merged 1 commit into from
Feb 10, 2023

Conversation

stephentoub
Copy link
Member

Fixes #81945

@ghost
Copy link

ghost commented Feb 10, 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 #81945

Author: stephentoub
Assignees: -
Labels:

area-System.Collections

Milestone: -

@stephentoub
Copy link
Member Author

/azp list

@azure-pipelines
Copy link

CI/CD Pipelines for this repository:

@stephentoub
Copy link
Member Author

/azp run runtime-extra-platforms

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@eiriktsarpalis
Copy link
Member

If CI is happy LGTM

@MichalStrehovsky
Copy link
Member

FWIW, this test would not require the RD.XML if the test replaced cd.GetType().GetField("_tables", BindingFlags.Instance | BindingFlags.NonPublic) and similar with typeof(ConcurrentDictionary<string, string>).GetField("_tables", BindingFlags.Instance | BindingFlags.NonPublic) (if they're equivalent - they might in this case?).

The reflection analysis only analyzes foo.GetType() if foo is sealed.

typeof(X).GetField("literal") works all the time.

@ghost ghost locked as resolved and limited conversation to collaborators Mar 15, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
3 participants