Skip to content

Yet another diagnostic pr - #56641

Open
BillWagner wants to merge 7 commits into
dotnet:mainfrom
BillWagner:yet-another-diagnostic-pr
Open

BillWagner wants to merge 7 commits into
dotnet:mainfrom
BillWagner:yet-another-diagnostic-pr

Conversation

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

The replacement drops useful CS8070 diagnostic examples and leaves a longer sample outside snippet compilation with an undeclared number.

2 open issues
What changed in this PR

This PR addresses #56418 by adding focused nameof diagnostic guidance and consolidating jump-statement diagnostics into their shared reference article.

Changes:

  • Add coverage for four nameof diagnostics and remove seven stale catch-all entries.
  • Consolidate six standalone diagnostic articles into jump-statement-errors.md.
  • Update TOC entries, diagnostic metadata, and redirects for retired pages.
File Description
docs/​csharp/​misc/​sorry-we-don-t-have-specifics-on-this-csharp-error.md Remove seven diagnostics with specific article owners.
docs/​csharp/​misc/​cs0164.md Retire the unused-label warning article.
docs/​csharp/​misc/​cs0162.md Retire the unreachable-code warning article.
docs/​csharp/​misc/​cs0158.md Retire the label-shadowing error article.
docs/​csharp/​misc/​cs0157.md Retire the finally-block exit error article.
docs/​csharp/​misc/​cs0140.md Retire the duplicate-label error article.
docs/​csharp/​language-reference/​toc.yml Add nameof navigation and update consolidated diagnostic entries.
docs/​csharp/​language-reference/​compiler-messages/​nameof-errors.md Add diagnostic descriptions and remediation for nameof.
docs/​csharp/​language-reference/​compiler-messages/​jump-statement-errors.md Expand coverage and reorganize control-flow guidance.
docs/​csharp/​language-reference/​compiler-messages/​cs8070.md Retire the standalone final-switch-section error article.
.openpublishing.redirection.csharp.json Redirect six retired articles to the consolidated page.

Review effort: Balanced

@BillWagner
BillWagner requested a review from gewarren October 30, 2026 18:04
@BillWagner BillWagner closed this Oct 30, 2026
@BillWagner BillWagner reopened this Oct 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Document nameof diagnostics and consolidate C# 6 diagnostic ownership

3 participants