Merged
Conversation
dotnet#52685 was merged while a review wasn't yet completed. Address those comments.
Contributor
There was a problem hiding this comment.
Pull request overview
This PR follows up on review feedback from #52685 by reorganizing and tightening the C# type documentation (classes, structs, and records), and adjusting related snippet files to match the revised narrative.
Changes:
- Moves “When to use …” guidance earlier in the structs and records articles, and adds brief lead-in sentences around snippet callouts.
- Simplifies the classes article by removing the standalone “Collection initializers” section and replacing it with a shorter reference.
- Tweaks/cleans up record-related snippet comments and adds a clarifying comment in the equality snippet.
Reviewed changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| docs/csharp/fundamentals/types/structs.md | Moves “When to use structs” earlier and adds snippet lead-in text. |
| docs/csharp/fundamentals/types/records.md | Moves “When to use records” earlier and adds record-struct clarifications and lead-ins. |
| docs/csharp/fundamentals/types/classes.md | Adds “When to use classes,” revises wording, and replaces the removed collection-initializers section with a brief reference (but introduces a couple issues). |
| docs/csharp/fundamentals/types/snippets/records/RecordStruct.cs | Minor comment formatting change in the record class vs struct snippet. |
| docs/csharp/fundamentals/types/snippets/records/FirstRecord.cs | Removes the “UsingRecord” snippet block (but now breaks compilation due to missing person). |
| docs/csharp/fundamentals/types/snippets/records/EqualityTest.cs | Adds a clarifying comment describing the record properties. |
| docs/csharp/fundamentals/types/snippets/classes/Program.cs | Removes the collection expressions demo snippet block. |
Co-authored-by: Copilot <[email protected]>
adegeo
approved these changes
Apr 7, 2026
Contributor
adegeo
left a comment
There was a problem hiding this comment.
LGTM! Approved with some small suggestions.
Co-authored-by: Andy (Steve) De George <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
#52685 was merged while a review wasn't yet completed. Address those comments.
Internal previews