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

Cascade between position record parameters and properties. #59293

Merged
merged 1 commit into from
Feb 7, 2022

Conversation

CyrusNajmabadi
Copy link
Member

@CyrusNajmabadi CyrusNajmabadi commented Feb 4, 2022

Fixes #44559

@CyrusNajmabadi CyrusNajmabadi requested a review from a team as a code owner February 4, 2022 20:37
@RikkiGibson
Copy link
Contributor

Talking offline, we think it would be ideal for the compiler to expose public APIs which let the IDE do the right thing here for both source and metadata scenarios.

For example, if a record Rec is declared in a referenced assembly:

var rec = new Rec(param: 1); // find-all-refs on "param" here
_ = rec.param.M(); // should include 'param' in results

I'm going to take a stab at coming up with public API that would address the scenario and we can bring it to API review.

Copy link
Member

@davidwengier davidwengier left a comment

Choose a reason for hiding this comment

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

I think we'll still probably get complaints about this until the new API is available, but good to make at least some scenarios better in the meantime.

Does this also fix #50450? or even #44560 maybe?

@CyrusNajmabadi CyrusNajmabadi merged commit 4224320 into dotnet:main Feb 7, 2022
@CyrusNajmabadi CyrusNajmabadi deleted the positionalRecordCascade branch February 7, 2022 15:59
@ghost ghost added this to the Next milestone Feb 7, 2022
@CyrusNajmabadi
Copy link
Member Author

Does this also fix #50450? or even #44560 maybe?

Very likely. I'll check today!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

FindAllReferences should find usages of positional members
3 participants