-
-
Notifications
You must be signed in to change notification settings - Fork 14.3k
Remove old error emitter #150880
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
base: main
Are you sure you want to change the base?
Remove old error emitter #150880
Conversation
|
cc @Muscraft These commits modify the If this was unintentional then you should revert the changes before this PR is merged.
cc @davidtwco, @TaKO8Ki |
|
r? @nnethercote rustbot has assigned @nnethercote. Use |
This comment has been minimized.
This comment has been minimized.
2060332 to
1b27206
Compare
This comment has been minimized.
This comment has been minimized.
This completes the transition to annotate-snippets
1b27206 to
4f4df28
Compare
|
Some changes occurred in src/tools/rustfmt cc @rust-lang/rustfmt |
| ) -> Result<ParseSourceInfo, ()> { | ||
| use rustc_errors::DiagCtxt; | ||
| use rustc_errors::emitter::HumanEmitter; | ||
| use rustc_errors::annotate_snippet_emitter_writer::AnnotateSnippetEmitter; |
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.
This is an obnoxiously long module name. The _writer suffix seems entirely unnecessary, given that it defines a type named AnnotateSnipperEmitter.
(Pre-existing, so no need to do anything here, I'm just noticing it.)
|
The code changes look good, r=me on those. It's a big change but it's already covered by rust-lang/compiler-team#947, so we are good on that front. The only question is whether you want to merge it immediately or wait a bit, as per this comment. So I'll let you trigger the final merge, @bjorn3. |
|
What do you think @Muscraft? Do you think it is likely we might need to switch back temporarily in the near future? |
Given that there has only been one issue (that I am aware of), combined with the fact that a lot of the internals of |
|
How about we merge this PR right after beta forks? That way there is one version of rustc where the new emitter is used, but the old emitter still present in case we need to revert back to it on the beta branch. And it should give roughly six weeks to backport bugfixes to the new emitter on the beta branch if issues pop up immediately after the new emitter hits stable. |
This completes the transition to annotate-snippets and cuts 3600 lines of code.