-
Notifications
You must be signed in to change notification settings - Fork 5.1k
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
Pattern docs can be improved #6893
Comments
Hi @DickBaker There are several good suggestions here:
I like the
And a few that I'd prefer not be changed:
This is by design. The goal is for readers to load the starter project, follow along with the companion article, and then compare their results with the finished code. These changes would make that harder.
Nope. This is an important technique to demonstrate. The API declares that the argument should not be
Nope. The lowered code combined with the runtime JIT will optimize these. It's not going to be a measurable performance improvement. And finally, one "it depends"
I'm concerned with growing the sample in ways that obscures the core learning concepts. I can see room for more cases, but I don't want to lose the plot. |
2-4. OK I will have to back-pedal my changes to keep your folder structure before I PR [hope to alot time this w/e] |
Pattern docs at samples\csharp\tutorials\patterns can be improved ...
although better to have explicit ctors with initializer for all props [maybe derive from external source to enforce]
also "GrossWeightClass" -> "GrossWeight" since unit is lbs as int
in switch expression the null check should happen once [first] otherwise each "is" typecast would have to perform its own null guard compare
practical to accurately assess GrossWeightClass without an actual weighbridge stop ?
I am in process of crafting a PR to suggest how I think docs and sample code should look.
The text was updated successfully, but these errors were encountered: