-
Notifications
You must be signed in to change notification settings - Fork 13k
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
Lint path statements to suggest using drop when the type needs drop #75056
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. If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes. Please see the contribution instructions for more information. |
@bors r+ Thanks! that was quite a long-standing issue |
📌 Commit 4eab8bce82cddfccc9a7392bec180b205110b79a has been approved by |
Just for completeness, should this also include a test for types that have drop glue but don't impl Drop themselves? An example being a single-element tuple that contains a Drop type. |
@bors r- That's a good idea |
4eab8bc
to
35d6a2e
Compare
Added the extra test case |
@bors r+ |
📌 Commit 35d6a2e has been approved by |
@bors rollup |
…-obk Lint path statements to suggest using drop when the type needs drop Fixes rust-lang#48852. With this change the current lint description doesn't really fit entirely anymore I think.
…-obk Lint path statements to suggest using drop when the type needs drop Fixes rust-lang#48852. With this change the current lint description doesn't really fit entirely anymore I think.
…-obk Lint path statements to suggest using drop when the type needs drop Fixes rust-lang#48852. With this change the current lint description doesn't really fit entirely anymore I think.
…-obk Lint path statements to suggest using drop when the type needs drop Fixes rust-lang#48852. With this change the current lint description doesn't really fit entirely anymore I think.
Rollup of 8 pull requests Successful merges: - rust-lang#74759 (add `unsigned_abs` to signed integers) - rust-lang#75043 (rustc_ast: `(Nested)MetaItem::check_name` -> `has_name`) - rust-lang#75056 (Lint path statements to suggest using drop when the type needs drop) - rust-lang#75081 (Fix logging for rustdoc) - rust-lang#75083 (Do not trigger `unused_braces` for `while let`) - rust-lang#75084 (Stabilize Ident::new_raw) - rust-lang#75103 (Disable building rust-analyzer on riscv64) - rust-lang#75106 (Enable docs on in the x86_64-unknown-linux-musl manifest) Failed merges: r? @ghost
Fixes #48852. With this change the current lint description doesn't really fit entirely anymore I think.