summaryrefslogtreecommitdiffstats
path: root/src/tools/clippy/src/docs/undropped_manually_drops.txt
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/tools/clippy/src/docs/undropped_manually_drops.txt22
1 files changed, 0 insertions, 22 deletions
diff --git a/src/tools/clippy/src/docs/undropped_manually_drops.txt b/src/tools/clippy/src/docs/undropped_manually_drops.txt
deleted file mode 100644
index 85e3ec566..000000000
--- a/src/tools/clippy/src/docs/undropped_manually_drops.txt
+++ /dev/null
@@ -1,22 +0,0 @@
-### What it does
-Prevents the safe `std::mem::drop` function from being called on `std::mem::ManuallyDrop`.
-
-### Why is this bad?
-The safe `drop` function does not drop the inner value of a `ManuallyDrop`.
-
-### Known problems
-Does not catch cases if the user binds `std::mem::drop`
-to a different name and calls it that way.
-
-### Example
-```
-struct S;
-drop(std::mem::ManuallyDrop::new(S));
-```
-Use instead:
-```
-struct S;
-unsafe {
- std::mem::ManuallyDrop::drop(&mut std::mem::ManuallyDrop::new(S));
-}
-``` \ No newline at end of file