-
Notifications
You must be signed in to change notification settings - Fork 274
Update C# Coding Guidelines to v14 #298
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
Closed
Closed
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
f212724
Initial plan
Copilot 241a14a
Update guidelines for C# 14: version numbers, intro, and multiple rul…
Copilot bedf879
Fix code review issues: spread operator spacing and null check exampl…
Copilot 3c54c2c
Fix broken and outdated links across all markdown files
Copilot 26f71d9
Add General Guidelines section with AV0100, AV0105, AV0110
Copilot d20b723
Add new rules, address code review comments, move basic principles to…
Copilot 91ce79b
Add Testability Guidelines section (AV1600 series)
Copilot 034b6f3
Address review comments: rule updates and removals
Copilot 0c59ff9
AV1608: add cross-reference to AV1610
Copilot c7f2064
Add AV1002: Only pass things to a constructor that most or all member…
Copilot 5261ca6
Remove AV2201 and AV2221; add AV2225 for deconstruction guidelines
Copilot 138d0e5
Remove AV2307; add AV2308 (document intent); add Polysharp tip; updat…
Copilot File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,10 @@ | ||
| --- | ||
| title: General Guidelines | ||
| permalink: /general-guidelines/ | ||
| classes: wide | ||
| search: true | ||
| sidebar: | ||
| nav: "sidebar" | ||
| rule_category: general | ||
| layout: rule-category | ||
| --- |
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,10 @@ | ||
| --- | ||
| title: Testability Guidelines | ||
| permalink: /testability-guidelines/ | ||
| classes: wide | ||
| search: true | ||
| sidebar: | ||
| nav: "sidebar" | ||
| rule_category: testability | ||
| layout: rule-category | ||
| --- |
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
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add a bullet talking about how the open-source project Polysharp can help adopting newer C# versions in older .NET projects
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Added in commit
138d0e5— new bullet in §1.4: "If you need to use newer C# language features in projects targeting older .NET versions, consider PolySharp. It provides polyfills for many modern C# features, allowing you to write modern C# even when targeting older runtimes."