diff options
| author | Catherine <114838443+Centri3@users.noreply.github.com> | 2023-06-21 15:56:24 -0500 |
|---|---|---|
| committer | Catherine <114838443+Centri3@users.noreply.github.com> | 2023-06-21 15:56:24 -0500 |
| commit | b6f194b48c2b7b1cd6a19592a8376056a826d223 (patch) | |
| tree | ef8479095d303f901943df5fbdfad13724c7fc09 /tests | |
| parent | d8d59965f1e6ba0490533c0bbd1ce50a00606d36 (diff) | |
| download | rust-b6f194b48c2b7b1cd6a19592a8376056a826d223.tar.gz rust-b6f194b48c2b7b1cd6a19592a8376056a826d223.zip | |
move to `drop_forget_ref`
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/ui/mem_forget.stderr | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/tests/ui/mem_forget.stderr b/tests/ui/mem_forget.stderr index 50711120a15..6e3c31804d7 100644 --- a/tests/ui/mem_forget.stderr +++ b/tests/ui/mem_forget.stderr @@ -4,6 +4,11 @@ error: usage of `mem::forget` on `Drop` type LL | memstuff::forget(six); | ^^^^^^^^^^^^^^^^^^^^^ | +note: argument has type `std::sync::Arc<i32>` + --> $DIR/mem_forget.rs:14:22 + | +LL | memstuff::forget(six); + | ^^^ = note: `-D clippy::mem-forget` implied by `-D warnings` error: usage of `mem::forget` on `Drop` type @@ -11,18 +16,36 @@ error: usage of `mem::forget` on `Drop` type | LL | std::mem::forget(seven); | ^^^^^^^^^^^^^^^^^^^^^^^ + | +note: argument has type `std::rc::Rc<i32>` + --> $DIR/mem_forget.rs:17:22 + | +LL | std::mem::forget(seven); + | ^^^^^ error: usage of `mem::forget` on `Drop` type --> $DIR/mem_forget.rs:20:5 | LL | forgetSomething(eight); | ^^^^^^^^^^^^^^^^^^^^^^ + | +note: argument has type `std::vec::Vec<i32>` + --> $DIR/mem_forget.rs:20:21 + | +LL | forgetSomething(eight); + | ^^^^^ error: usage of `mem::forget` on type with `Drop` fields --> $DIR/mem_forget.rs:23:5 | LL | std::mem::forget(string); | ^^^^^^^^^^^^^^^^^^^^^^^^ + | +note: argument has type `std::string::String` + --> $DIR/mem_forget.rs:23:22 + | +LL | std::mem::forget(string); + | ^^^^^^ error: aborting due to 4 previous errors |
