-
Notifications
You must be signed in to change notification settings - Fork 12.9k
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
Migrate rustc_lint
errors to SessionDiagnostic
#100776
Migrate rustc_lint
errors to SessionDiagnostic
#100776
Conversation
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @oli-obk (or someone else) soon. Please see the contribution instructions for more information. |
This comment has been minimized.
This comment has been minimized.
r? @davidtwco |
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 a great start! I've left a couple comments. Also, we have a "no merge policy" and prefer rebases, if you could fix that it would be great:
https://rustc-dev-guide.rust-lang.org/git.html?highlight=rebae#no-merge-policy
1c858d2
to
257cf03
Compare
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.
LGTM, r=me, but I'll give you a bit to see the comment about IntoDiagnosticArg
and to chose to address it or not.
rustc_lint
to SessionDiagnostic
rustc_lint
errors to SessionDiagnostic
cc @davidtwco, @compiler-errors, @JohnTitor, @estebank, @TaKO8Ki |
@bors r+ |
@bors rollup |
…mpiler-errors Rollup of 9 pull requests Successful merges: - rust-lang#100724 (Migrate ast lowering to session diagnostic) - rust-lang#100735 (Migrate `rustc_ty_utils` to `SessionDiagnostic`) - rust-lang#100738 (Diagnostics migr const eval) - rust-lang#100744 (Migrate rustc_mir_dataflow to diagnostic structs) - rust-lang#100776 (Migrate `rustc_lint` errors to `SessionDiagnostic`) - rust-lang#100817 (sugg: suggest the usage of boolean value when there is a typo in the keyword) - rust-lang#100836 (Migrate `rustc_attr` crate diagnostics) - rust-lang#100890 (Migrate rustc_driver to SessionDiagnostic) - rust-lang#100900 (on `region_errors.rs`) Failed merges: - rust-lang#100831 (Migrate `symbol_mangling` module to new diagnostics structs) r? `@ghost` `@rustbot` modify labels: rollup
…t-pt2, r=davidtwco Migrate `rustc_lint` lint diagnostics Part 2 of [Migrate `rustc_lint` errors to `SessionDiagnostic`](rust-lang#100776) r? `@davidtwco` # TODO - [x] Refactor some lints manually implementing `DecorateLint` to use `Option<Subdiagnostic>`. - [x] Add `#[rustc_lint_diagnostics]` to lint functions in `context.rs`. - [x] Migrate `hidden_unicode_codepoints.rs`. - [x] Migrate `UnsafeCode` in `builtin.rs`. - [x] Migrate the rest of `builtin.rs`.
…davidtwco Migrate `rustc_lint` lint diagnostics Part 2 of [Migrate `rustc_lint` errors to `SessionDiagnostic`](rust-lang/rust#100776) r? `@davidtwco` # TODO - [x] Refactor some lints manually implementing `DecorateLint` to use `Option<Subdiagnostic>`. - [x] Add `#[rustc_lint_diagnostics]` to lint functions in `context.rs`. - [x] Migrate `hidden_unicode_codepoints.rs`. - [x] Migrate `UnsafeCode` in `builtin.rs`. - [x] Migrate the rest of `builtin.rs`.
…davidtwco Migrate `rustc_lint` lint diagnostics Part 2 of [Migrate `rustc_lint` errors to `SessionDiagnostic`](rust-lang/rust#100776) r? `@davidtwco` # TODO - [x] Refactor some lints manually implementing `DecorateLint` to use `Option<Subdiagnostic>`. - [x] Add `#[rustc_lint_diagnostics]` to lint functions in `context.rs`. - [x] Migrate `hidden_unicode_codepoints.rs`. - [x] Migrate `UnsafeCode` in `builtin.rs`. - [x] Migrate the rest of `builtin.rs`.
…davidtwco Migrate `rustc_lint` lint diagnostics Part 2 of [Migrate `rustc_lint` errors to `SessionDiagnostic`](rust-lang/rust#100776) r? `@davidtwco` # TODO - [x] Refactor some lints manually implementing `DecorateLint` to use `Option<Subdiagnostic>`. - [x] Add `#[rustc_lint_diagnostics]` to lint functions in `context.rs`. - [x] Migrate `hidden_unicode_codepoints.rs`. - [x] Migrate `UnsafeCode` in `builtin.rs`. - [x] Migrate the rest of `builtin.rs`.
Draft PR for migrating
rustc_lint
toSessionDiagnostic
, as part of the recent blog post