about summary refs log tree commit diff
path: root/compiler/rustc_llvm/llvm-wrapper/CoverageMappingWrapper.cpp
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2023-06-09 12:44:23 +0000
committerbors <bors@rust-lang.org>2023-06-09 12:44:23 +0000
commitb356491a312ec4c8cbe5987a23e6a1c14f87dfdb (patch)
treeb958f7ab1824dd1f6efa70caa3f46854f2cf969f /compiler/rustc_llvm/llvm-wrapper/CoverageMappingWrapper.cpp
parent737cba0c374eb24c2294d6cc389e5a912f9730d9 (diff)
parentf47e9156a4cc6f4908beb8f2b3564de8c42a56cb (diff)
downloadrust-b356491a312ec4c8cbe5987a23e6a1c14f87dfdb.tar.gz
rust-b356491a312ec4c8cbe5987a23e6a1c14f87dfdb.zip
Auto merge of #111530 - Urgau:uplift_undropped_manually_drops, r=compiler-errors
Uplift `clippy::undropped_manually_drops` lint

This PR aims at uplifting the `clippy::undropped_manually_drops` lint.

## `undropped_manually_drops`

(warn-by-default)

The `undropped_manually_drops` lint check for calls to `std::mem::drop` with a value of `std::mem::ManuallyDrop` which doesn't drop.

### Example

```rust
struct S;
drop(std::mem::ManuallyDrop::new(S));
```

### Explanation

`ManuallyDrop` does not drop it's inner value so calling `std::mem::drop` will not drop the inner value of the `ManuallyDrop` either.

-----

Mostly followed the instructions for uplifting an clippy lint described here: https://github.com/rust-lang/rust/pull/99696#pullrequestreview-1134072751

`@rustbot` label: +I-lang-nominated
r? compiler

-----

For Clippy:

changelog: Moves: Uplifted `clippy::undropped_manually_drops` into rustc
Diffstat (limited to 'compiler/rustc_llvm/llvm-wrapper/CoverageMappingWrapper.cpp')
0 files changed, 0 insertions, 0 deletions