WIP: fix(cli): Use Shell::print_report for error chains#15922
Draft
epage wants to merge 3 commits intorust-lang:masterfrom
Draft
WIP: fix(cli): Use Shell::print_report for error chains#15922epage wants to merge 3 commits intorust-lang:masterfrom
epage wants to merge 3 commits intorust-lang:masterfrom
Conversation
Collaborator
|
r? @weihanglo rustbot has assigned @weihanglo. Use |
Contributor
Author
|
Unlike #15917 which can be touched up in the callers if we don't like it, this will need a more invasive change of creating a diagnostic-first error type if we're not satisfied with the results as-is, so looking to solicit feedback on the general idea and what all directions we may want to take this before going down those roads. |
github-merge-queue bot
pushed a commit
that referenced
this pull request
Sep 4, 2025
### What does this PR try to resolve? This is some cleanup that will help with #15922 ### How to test and review this PR?
This comment has been minimized.
This comment has been minimized.
This was referenced Sep 4, 2025
This comment has been minimized.
This comment has been minimized.
github-merge-queue bot
pushed a commit
that referenced
this pull request
Sep 8, 2025
### What does this PR try to resolve? Fixes #12740 This is also prep for #15917, #15922 Changes: - `note` changes from Cyan to Bright Green - `cargo info` had to be changed because the header and context colors became the same - Switch to Bright colors which is usually redundant with Bold but that is theme dependent - `warning` only changes to Bright on Windows which is to work around a shell issue on some Windows versions - except for `PLACEHOLDER` to tell it apart from `LITERAL` - the `:` in `note:` is no longer bolded to match rustc ### How to test and review this PR? ### Notes While annotate-snippets does not have a style for every one of our styles, I updated our manual styles to be similar to annotate snippets. For annotate snippets color definitions, see https://github.com/rust-lang/annotate-snippets-rs/blob/d38b08b81d7d574369ecfd30124195a970b37fd3/src/renderer/mod.rs#L41-L78
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Collaborator
|
☔ The latest upstream changes (possibly 8c4a25c) made this pull request unmergeable. Please resolve the merge conflicts. |
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.
What does this PR try to resolve?
This replaces
Shell::error, etc calls (see also #15917) withShell::print_reportwhen error chains are involved in an effort to render things more like rustcThis is part of #15944
Fixes #14924
How to test and review this PR?