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

Use pattern matching for multi-kind checks #64108

Merged
merged 29 commits into from
Sep 19, 2022

Conversation

CyrusNajmabadi
Copy link
Member

@CyrusNajmabadi CyrusNajmabadi commented Sep 17, 2022

These extensions existed prior to the language having pattern matching. Now that we have that lang facility there isn't a need for it and we can use the more idiomatic built in mechanism.

@CyrusNajmabadi CyrusNajmabadi marked this pull request as ready for review September 17, 2022 07:23
@CyrusNajmabadi CyrusNajmabadi requested a review from a team as a code owner September 17, 2022 07:23
Copy link
Member

@Youssef1313 Youssef1313 left a comment

Choose a reason for hiding this comment

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

Do the performance concerns still hold?

cc @sharwell

@CyrusNajmabadi
Copy link
Member Author

I have never once seen a single trace demonstrating that this matters in practice.

Regardless, these methods were not created for perf, they were created to make it more pleasant to do checks way back before we had basic language features for this.

@CyrusNajmabadi
Copy link
Member Author

ping @dotnet/roslyn-ide thanks!

@CyrusNajmabadi CyrusNajmabadi merged commit b1b8636 into dotnet:main Sep 19, 2022
@CyrusNajmabadi CyrusNajmabadi deleted the useKind branch September 19, 2022 17:33
@ghost ghost added this to the Next milestone Sep 19, 2022
@Cosifne Cosifne modified the milestones: Next, 17.4 P3 Sep 26, 2022
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.

4 participants