Skip to content
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

Renaming a tool lint to another tool lint does not apply the warning #83598

Closed
jyn514 opened this issue Mar 28, 2021 · 0 comments · Fixed by #81764
Closed

Renaming a tool lint to another tool lint does not apply the warning #83598

jyn514 opened this issue Mar 28, 2021 · 0 comments · Fixed by #81764
Assignees
Labels
A-lint Area: Lints (warnings about flaws in source code) such as unused_mut. C-bug Category: This is a bug. T-dev-tools Relevant to the dev-tools subteam, which will review and decide on the PR/issue.

Comments

@jyn514
Copy link
Member

jyn514 commented Mar 28, 2021

Similar to #82615, but the source lint is a tool lint this time.

I tried this code:

#![deny(rustdoc::non_autolinks)]
//! http://example.com

and renamed non_autolinks in a fork of rust-lang/rust.

I expected to see this happen: Rustdoc warns that the lint is renamed and still applies the lint.

Instead, this happened: Rustdoc warns that the lint is renamed, but does not apply the lint.

warning: lint `rustdoc::non_autolinks` has been renamed to `rustdoc::bare_urls`
  --> /home/joshua/rustc/src/test/rustdoc-ui/url-improvements.rs:1:9
   |
LL | #![deny(rustdoc::non_autolinks)]
   |         ^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `rustdoc::bare_urls`
   |
   = note: `#[warn(renamed_and_removed_lints)]` on by default
warning: this URL is not a hyperlink
  --> /home/joshua/rustc/src/test/rustdoc-ui/url-improvements.rs:2:5
   |
LL | /// https://example.com
   |     ^^^^^^^^^^^^^^^^^^^^^^^ help: use an automatic link instead: `<https://example.com>`

Meta

Version: 59d7295

@jyn514 jyn514 added A-lint Area: Lints (warnings about flaws in source code) such as unused_mut. T-dev-tools Relevant to the dev-tools subteam, which will review and decide on the PR/issue. C-bug Category: This is a bug. labels Mar 28, 2021
@jyn514 jyn514 self-assigned this Mar 28, 2021
@bors bors closed this as completed in 9aed9c1 Apr 8, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-lint Area: Lints (warnings about flaws in source code) such as unused_mut. C-bug Category: This is a bug. T-dev-tools Relevant to the dev-tools subteam, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant