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

Updated method invocation snippet to reverse arguments as described #44733

Merged
merged 1 commit into from
Feb 11, 2025

Conversation

Knar33
Copy link
Contributor

@Knar33 Knar33 commented Feb 10, 2025

Summary

https://learn.microsoft.com/en-us/dotnet/csharp/methods#method-invocation

In the third code snippet of this page it says "In this example, the named arguments are passed in the opposite order from the method's parameter list" but in the following example the parameters are in the same positional order. I switched the order to demonstrate putting arguments in a different order than the method parameter positional order.

Fixes #44732

@Knar33 Knar33 requested review from BillWagner and a team as code owners February 10, 2025 15:14
@dotnetrepoman dotnetrepoman bot added this to the February 2025 milestone Feb 10, 2025
@dotnet-policy-service dotnet-policy-service bot added dotnet-csharp/svc community-contribution Indicates PR is created by someone from the .NET community. labels Feb 10, 2025
Copy link
Member

@BillWagner BillWagner left a comment

Choose a reason for hiding this comment

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

Thanks @Knar33

This LGM, and I'll :shipit: now.

@BillWagner BillWagner enabled auto-merge (squash) February 11, 2025 14:31
@BillWagner BillWagner merged commit 5a19eb3 into dotnet:main Feb 11, 2025
11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
community-contribution Indicates PR is created by someone from the .NET community. dotnet-csharp/svc
Projects
None yet
Development

Successfully merging this pull request may close these issues.

example for method invocation says parameters are reversed, but they aren't reversed in the code snippet
2 participants