about summary refs log tree commit diff
diff options
context:
space:
mode:
authorCamille GILLOT <gillot.camille@gmail.com>2023-06-24 10:02:54 +0000
committerCamille GILLOT <gillot.camille@gmail.com>2023-09-23 13:47:30 +0000
commit211d2ed07bb5dff7683fb021341db751cec2ca1e (patch)
treec17d777a1beffa6edead6677afce1c5789bc8fa8
parent286502c9ed77e49aea5bb89cf18c5eda3a8fce92 (diff)
downloadrust-211d2ed07bb5dff7683fb021341db751cec2ca1e.tar.gz
rust-211d2ed07bb5dff7683fb021341db751cec2ca1e.zip
Bless tests.
-rw-r--r--tests/ui/async-await/async-await-let-else.stderr48
-rw-r--r--tests/ui/async-await/async-error-span.rs2
-rw-r--r--tests/ui/async-await/async-error-span.stderr13
-rw-r--r--tests/ui/async-await/async-fn-nonsend.rs2
-rw-r--r--tests/ui/async-await/async-fn-nonsend.stderr6
-rw-r--r--tests/ui/async-await/async-is-unwindsafe.stderr14
-rw-r--r--tests/ui/async-await/await-sequence.rs1
-rw-r--r--tests/ui/async-await/default-struct-update.rs1
-rw-r--r--tests/ui/async-await/drop-and-assign.rs1
-rw-r--r--tests/ui/async-await/drop-track-bad-field-in-fru.rs1
-rw-r--r--tests/ui/async-await/drop-track-bad-field-in-fru.stderr4
-rw-r--r--tests/ui/async-await/drop-track-field-assign-nonsend.rs1
-rw-r--r--tests/ui/async-await/drop-track-field-assign-nonsend.stderr8
-rw-r--r--tests/ui/async-await/drop-track-field-assign.rs1
-rw-r--r--tests/ui/async-await/drop-tracking-unresolved-typeck-results.rs3
-rw-r--r--tests/ui/async-await/drop-tracking-unresolved-typeck-results.stderr40
-rw-r--r--tests/ui/async-await/field-assign-nonsend.stderr2
-rw-r--r--tests/ui/async-await/in-trait/indirect-recursion-issue-112047.rs2
-rw-r--r--tests/ui/async-await/in-trait/indirect-recursion-issue-112047.stderr9
-rw-r--r--tests/ui/async-await/issue-64130-1-sync.rs1
-rw-r--r--tests/ui/async-await/issue-64130-1-sync.stderr4
-rw-r--r--tests/ui/async-await/issue-64130-2-send.rs1
-rw-r--r--tests/ui/async-await/issue-64130-2-send.stderr4
-rw-r--r--tests/ui/async-await/issue-64130-3-other.rs1
-rw-r--r--tests/ui/async-await/issue-64130-3-other.stderr4
-rw-r--r--tests/ui/async-await/issue-64130-4-async-move.rs1
-rw-r--r--tests/ui/async-await/issue-64130-non-send-future-diags.stderr2
-rw-r--r--tests/ui/async-await/issue-67252-unnamed-future.rs3
-rw-r--r--tests/ui/async-await/issue-67252-unnamed-future.stderr20
-rw-r--r--tests/ui/async-await/issue-68112.rs2
-rw-r--r--tests/ui/async-await/issue-68112.stderr16
-rw-r--r--tests/ui/async-await/issue-70935-complex-spans.rs2
-rw-r--r--tests/ui/async-await/issue-70935-complex-spans.stderr40
-rw-r--r--tests/ui/async-await/issue-71137.stderr3
-rw-r--r--tests/ui/async-await/issue-93197.rs1
-rw-r--r--tests/ui/async-await/issue-93648.rs1
-rw-r--r--tests/ui/async-await/issues/auxiliary/issue_67893.rs4
-rw-r--r--tests/ui/async-await/issues/issue-107280.rs5
-rw-r--r--tests/ui/async-await/issues/issue-107280.stderr67
-rw-r--r--tests/ui/async-await/issues/issue-65436-raw-ptr-not-send.rs1
-rw-r--r--tests/ui/async-await/issues/issue-67893.rs2
-rw-r--r--tests/ui/async-await/issues/issue-67893.stderr28
-rw-r--r--tests/ui/async-await/non-trivial-drop.rs1
-rw-r--r--tests/ui/async-await/partial-drop-partial-reinit.stderr2
-rw-r--r--tests/ui/async-await/return-type-notation/issue-110963-early.current.stderr25
-rw-r--r--tests/ui/async-await/return-type-notation/issue-110963-early.next.stderr25
-rw-r--r--tests/ui/async-await/return-type-notation/issue-110963-early.stderr25
-rw-r--r--tests/ui/async-await/unresolved_type_param.rs14
-rw-r--r--tests/ui/async-await/unresolved_type_param.stderr41
-rw-r--r--tests/ui/borrowck/async-reference-generality.rs3
-rw-r--r--tests/ui/borrowck/async-reference-generality.stderr27
-rw-r--r--tests/ui/borrowck/erase-error-in-mir-drop-tracking.rs23
-rw-r--r--tests/ui/borrowck/erase-error-in-mir-drop-tracking.stderr24
-rw-r--r--tests/ui/codegen/subtyping-enforces-type-equality.stderr1
-rw-r--r--tests/ui/generator/borrowing.stderr20
-rw-r--r--tests/ui/generator/clone-impl.stderr30
-rw-r--r--tests/ui/generator/derived-drop-parent-expr.rs1
-rw-r--r--tests/ui/generator/drop-control-flow.rs1
-rw-r--r--tests/ui/generator/drop-track-addassign-yield.rs1
-rw-r--r--tests/ui/generator/drop-tracking-error-body.rs18
-rw-r--r--tests/ui/generator/drop-tracking-error-body.stderr17
-rw-r--r--tests/ui/generator/drop-tracking-parent-expression.rs1
-rw-r--r--tests/ui/generator/drop-tracking-parent-expression.stderr36
-rw-r--r--tests/ui/generator/drop-tracking-yielding-in-match-guards.rs1
-rw-r--r--tests/ui/generator/drop-yield-twice.stderr15
-rw-r--r--tests/ui/generator/issue-102645.rs2
-rw-r--r--tests/ui/generator/issue-102645.stderr2
-rw-r--r--tests/ui/generator/issue-105084.rs2
-rw-r--r--tests/ui/generator/issue-105084.stderr18
-rw-r--r--tests/ui/generator/issue-110929-generator-conflict-error-ice.rs1
-rw-r--r--tests/ui/generator/issue-110929-generator-conflict-error-ice.stderr2
-rw-r--r--tests/ui/generator/issue-57017.rs1
-rw-r--r--tests/ui/generator/issue-57478.rs1
-rw-r--r--tests/ui/generator/issue-68112.rs5
-rw-r--r--tests/ui/generator/issue-68112.stderr15
-rw-r--r--tests/ui/generator/issue-93161.rs1
-rw-r--r--tests/ui/generator/not-send-sync.rs16
-rw-r--r--tests/ui/generator/not-send-sync.stderr74
-rw-r--r--tests/ui/generator/parent-expression.rs2
-rw-r--r--tests/ui/generator/parent-expression.stderr36
-rw-r--r--tests/ui/generator/partial-drop.rs14
-rw-r--r--tests/ui/generator/partial-drop.stderr92
-rw-r--r--tests/ui/generator/print/generator-print-verbose-1.rs2
-rw-r--r--tests/ui/generator/print/generator-print-verbose-1.stderr14
-rw-r--r--tests/ui/generator/print/generator-print-verbose-2.rs16
-rw-r--r--tests/ui/generator/print/generator-print-verbose-2.stderr74
-rw-r--r--tests/ui/generator/retain-resume-ref.stderr7
-rw-r--r--tests/ui/generator/unresolved-ct-var.rs5
-rw-r--r--tests/ui/generator/unresolved-ct-var.stderr65
-rw-r--r--tests/ui/generator/unsized-capture-across-yield.rs (renamed from tests/ui/generator/unsized-across-yield.rs)12
-rw-r--r--tests/ui/generator/unsized-capture-across-yield.stderr (renamed from tests/ui/generator/unsized-across-yield.stderr)15
-rw-r--r--tests/ui/generator/unsized-local-across-yield.rs21
-rw-r--r--tests/ui/generator/unsized-local-across-yield.stderr21
-rw-r--r--tests/ui/generic-associated-types/bugs/issue-100013.stderr30
-rw-r--r--tests/ui/impl-trait/issue-55872-2.rs1
-rw-r--r--tests/ui/impl-trait/issue-55872-2.stderr8
-rw-r--r--tests/ui/impl-trait/recursive-generator.rs1
-rw-r--r--tests/ui/impl-trait/recursive-generator.stderr15
-rw-r--r--tests/ui/impl-trait/recursive-impl-trait-type-indirect.stderr15
-rw-r--r--tests/ui/lint/must_not_suspend/dedup.rs5
-rw-r--r--tests/ui/lint/must_not_suspend/dedup.stderr15
-rw-r--r--tests/ui/lint/must_not_suspend/ref.stderr14
-rw-r--r--tests/ui/lint/must_not_suspend/unit.rs1
-rw-r--r--tests/ui/lint/must_not_suspend/warn.rs3
-rw-r--r--tests/ui/lint/must_not_suspend/warn.stderr12
-rw-r--r--tests/ui/traits/new-solver/auto-with-drop_tracking_mir.rs2
-rw-r--r--tests/ui/traits/unsend-future.rs1
-rw-r--r--tests/ui/traits/unsend-future.stderr4
-rw-r--r--tests/ui/type-alias-impl-trait/indirect-recursion-issue-112047.rs2
-rw-r--r--tests/ui/type-alias-impl-trait/indirect-recursion-issue-112047.stderr15
110 files changed, 486 insertions, 918 deletions
diff --git a/tests/ui/async-await/async-await-let-else.stderr b/tests/ui/async-await/async-await-let-else.stderr
index b47201502f6..9a1c1782233 100644
--- a/tests/ui/async-await/async-await-let-else.stderr
+++ b/tests/ui/async-await/async-await-let-else.stderr
@@ -12,30 +12,43 @@ LL |         let r = Rc::new(());
    |             - has type `Rc<()>` which is not `Send`
 LL |         bar().await
    |               ^^^^^ await occurs here, with `r` maybe used later
-LL |     };
-   |     - `r` is later dropped here
 note: required by a bound in `is_send`
   --> $DIR/async-await-let-else.rs:16:15
    |
 LL | fn is_send<T: Send>(_: T) {}
    |               ^^^^ required by this bound in `is_send`
 
-error: future cannot be sent between threads safely
+error[E0277]: `Rc<()>` cannot be sent between threads safely
   --> $DIR/async-await-let-else.rs:47:13
    |
+LL | async fn foo2(x: Option<bool>) {
+   |                                - within this `impl Future<Output = ()>`
+...
 LL |     is_send(foo2(Some(true)));
-   |             ^^^^^^^^^^^^^^^^ future returned by `foo2` is not `Send`
+   |     ------- ^^^^^^^^^^^^^^^^ `Rc<()>` cannot be sent between threads safely
+   |     |
+   |     required by a bound introduced by this call
    |
    = help: within `impl Future<Output = ()>`, the trait `Send` is not implemented for `Rc<()>`
-note: future is not `Send` as this value is used across an await
-  --> $DIR/async-await-let-else.rs:20:27
-   |
-LL |         bar2(Rc::new(())).await
-   |              -----------  ^^^^^ await occurs here, with `Rc::new(())` maybe used later
-   |              |
-   |              has type `Rc<()>` which is not `Send`
-LL |     };
-   |     - `Rc::new(())` is later dropped here
+note: required because it's used within this `async fn` body
+  --> $DIR/async-await-let-else.rs:24:29
+   |
+LL |   async fn bar2<T>(_: T) -> ! {
+   |  _____________________________^
+LL | |     panic!()
+LL | | }
+   | |_^
+   = note: required because it captures the following types: `impl Future<Output = !>`
+note: required because it's used within this `async fn` body
+  --> $DIR/async-await-let-else.rs:18:32
+   |
+LL |   async fn foo2(x: Option<bool>) {
+   |  ________________________________^
+LL | |     let Some(_) = x else {
+LL | |         bar2(Rc::new(())).await
+LL | |     };
+LL | | }
+   | |_^
 note: required by a bound in `is_send`
   --> $DIR/async-await-let-else.rs:16:15
    |
@@ -53,9 +66,8 @@ note: future is not `Send` as this value is used across an await
   --> $DIR/async-await-let-else.rs:30:29
    |
 LL |         (Rc::new(()), bar().await);
-   |          -----------        ^^^^^ - `Rc::new(())` is later dropped here
-   |          |                  |
-   |          |                  await occurs here, with `Rc::new(())` maybe used later
+   |          -----------        ^^^^^ await occurs here, with `Rc::new(())` maybe used later
+   |          |
    |          has type `Rc<()>` which is not `Send`
 note: required by a bound in `is_send`
   --> $DIR/async-await-let-else.rs:16:15
@@ -77,9 +89,6 @@ LL |         let r = Rc::new(());
    |             - has type `Rc<()>` which is not `Send`
 LL |         bar().await;
    |               ^^^^^ await occurs here, with `r` maybe used later
-...
-LL |     };
-   |     - `r` is later dropped here
 note: required by a bound in `is_send`
   --> $DIR/async-await-let-else.rs:16:15
    |
@@ -88,3 +97,4 @@ LL | fn is_send<T: Send>(_: T) {}
 
 error: aborting due to 4 previous errors
 
+For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/async-await/async-error-span.rs b/tests/ui/async-await/async-error-span.rs
index 86d459bf084..c8127df625e 100644
--- a/tests/ui/async-await/async-error-span.rs
+++ b/tests/ui/async-await/async-error-span.rs
@@ -10,7 +10,7 @@ fn get_future() -> impl Future<Output = ()> {
 }
 
 async fn foo() {
-    let a; //~ ERROR type inside `async fn` body must be known in this context
+    let a; //~ ERROR type annotations needed
     get_future().await;
 }
 
diff --git a/tests/ui/async-await/async-error-span.stderr b/tests/ui/async-await/async-error-span.stderr
index 68fb385718e..2ec968ffc03 100644
--- a/tests/ui/async-await/async-error-span.stderr
+++ b/tests/ui/async-await/async-error-span.stderr
@@ -7,19 +7,18 @@ LL | fn get_future() -> impl Future<Output = ()> {
    = help: the trait `Future` is not implemented for `()`
    = note: () must be a future or must implement `IntoFuture` to be awaited
 
-error[E0698]: type inside `async fn` body must be known in this context
+error[E0282]: type annotations needed
   --> $DIR/async-error-span.rs:13:9
    |
 LL |     let a;
-   |         ^ cannot infer type
+   |         ^
    |
-note: the type is part of the `async fn` body because of this `await`
-  --> $DIR/async-error-span.rs:14:18
+help: consider giving `a` an explicit type
    |
-LL |     get_future().await;
-   |                  ^^^^^
+LL |     let a: /* Type */;
+   |          ++++++++++++
 
 error: aborting due to 2 previous errors
 
-Some errors have detailed explanations: E0277, E0698.
+Some errors have detailed explanations: E0277, E0282.
 For more information about an error, try `rustc --explain E0277`.
diff --git a/tests/ui/async-await/async-fn-nonsend.rs b/tests/ui/async-await/async-fn-nonsend.rs
index d7f8d7ac546..c5453b67ef5 100644
--- a/tests/ui/async-await/async-fn-nonsend.rs
+++ b/tests/ui/async-await/async-fn-nonsend.rs
@@ -1,5 +1,5 @@
 // edition:2018
-// compile-flags: --crate-type lib -Zdrop-tracking
+// compile-flags: --crate-type lib
 
 use std::{cell::RefCell, fmt::Debug, rc::Rc};
 
diff --git a/tests/ui/async-await/async-fn-nonsend.stderr b/tests/ui/async-await/async-fn-nonsend.stderr
index 0d00fc072e1..0ced6c36f47 100644
--- a/tests/ui/async-await/async-fn-nonsend.stderr
+++ b/tests/ui/async-await/async-fn-nonsend.stderr
@@ -12,9 +12,6 @@ LL |     match Some(non_send()) {
    |           ---------------- has type `Option<impl Debug>` which is not `Send`
 LL |         Some(_) => fut().await,
    |                          ^^^^^ await occurs here, with `Some(non_send())` maybe used later
-...
-LL | }
-   | - `Some(non_send())` is later dropped here
 note: required by a bound in `assert_send`
   --> $DIR/async-fn-nonsend.rs:64:24
    |
@@ -36,9 +33,6 @@ LL |     let f: &mut std::fmt::Formatter = &mut get_formatter();
 ...
 LL |         fut().await;
    |               ^^^^^ await occurs here, with `get_formatter()` maybe used later
-LL |     }
-LL | }
-   | - `get_formatter()` is later dropped here
 note: required by a bound in `assert_send`
   --> $DIR/async-fn-nonsend.rs:64:24
    |
diff --git a/tests/ui/async-await/async-is-unwindsafe.stderr b/tests/ui/async-await/async-is-unwindsafe.stderr
index c21f8cfa51f..eaa45538050 100644
--- a/tests/ui/async-await/async-is-unwindsafe.stderr
+++ b/tests/ui/async-await/async-is-unwindsafe.stderr
@@ -1,18 +1,17 @@
 error[E0277]: the type `&mut Context<'_>` may not be safely transferred across an unwind boundary
-  --> $DIR/async-is-unwindsafe.rs:12:19
+  --> $DIR/async-is-unwindsafe.rs:12:5
    |
 LL |       is_unwindsafe(async {
-   |  ___________________^
+   |  _____^^^^^^^^^^^^^_-
+   | |     |
+   | |     `&mut Context<'_>` may not be safely transferred across an unwind boundary
 LL | |
 LL | |         use std::ptr::null;
 LL | |         use std::task::{Context, RawWaker, RawWakerVTable, Waker};
 ...  |
 LL | |         drop(cx_ref);
 LL | |     });
-   | |     ^
-   | |     |
-   | |_____`&mut Context<'_>` may not be safely transferred across an unwind boundary
-   |       within this `{async block@$DIR/async-is-unwindsafe.rs:12:19: 29:6}`
+   | |_____- within this `{async block@$DIR/async-is-unwindsafe.rs:12:19: 29:6}`
    |
    = help: within `{async block@$DIR/async-is-unwindsafe.rs:12:19: 29:6}`, the trait `UnwindSafe` is not implemented for `&mut Context<'_>`
    = note: `UnwindSafe` is implemented for `&Context<'_>`, but not for `&mut Context<'_>`
@@ -24,9 +23,6 @@ LL |         let cx_ref = &mut cx;
 LL |
 LL |         async {}.await; // this needs an inner await point
    |                  ^^^^^ await occurs here, with `cx_ref` maybe used later
-...
-LL |     });
-   |     - `cx_ref` is later dropped here
 note: required by a bound in `is_unwindsafe`
   --> $DIR/async-is-unwindsafe.rs:3:26
    |
diff --git a/tests/ui/async-await/await-sequence.rs b/tests/ui/async-await/await-sequence.rs
index 726c4284ec1..79f68dd606c 100644
--- a/tests/ui/async-await/await-sequence.rs
+++ b/tests/ui/async-await/await-sequence.rs
@@ -1,5 +1,4 @@
 // edition:2021
-// compile-flags: -Z drop-tracking
 // build-pass
 
 use std::collections::HashMap;
diff --git a/tests/ui/async-await/default-struct-update.rs b/tests/ui/async-await/default-struct-update.rs
index 64fb6280dd7..f4757e7cbae 100644
--- a/tests/ui/async-await/default-struct-update.rs
+++ b/tests/ui/async-await/default-struct-update.rs
@@ -1,6 +1,5 @@
 // build-pass
 // edition:2018
-// compile-flags: -Zdrop-tracking=y
 
 fn main() {
     let _ = foo();
diff --git a/tests/ui/async-await/drop-and-assign.rs b/tests/ui/async-await/drop-and-assign.rs
index fa3f3303677..ef39033a9d4 100644
--- a/tests/ui/async-await/drop-and-assign.rs
+++ b/tests/ui/async-await/drop-and-assign.rs
@@ -1,5 +1,4 @@
 // edition:2021
-// compile-flags: -Zdrop-tracking
 // build-pass
 
 struct A;
diff --git a/tests/ui/async-await/drop-track-bad-field-in-fru.rs b/tests/ui/async-await/drop-track-bad-field-in-fru.rs
index 28ad7767583..667b288e676 100644
--- a/tests/ui/async-await/drop-track-bad-field-in-fru.rs
+++ b/tests/ui/async-await/drop-track-bad-field-in-fru.rs
@@ -1,4 +1,3 @@
-// compile-flags: -Zdrop-tracking
 // edition: 2021
 
 fn main() {}
diff --git a/tests/ui/async-await/drop-track-bad-field-in-fru.stderr b/tests/ui/async-await/drop-track-bad-field-in-fru.stderr
index b49b15db64c..721e0106293 100644
--- a/tests/ui/async-await/drop-track-bad-field-in-fru.stderr
+++ b/tests/ui/async-await/drop-track-bad-field-in-fru.stderr
@@ -1,5 +1,5 @@
 error[E0559]: variant `Option<_>::None` has no field named `value`
-  --> $DIR/drop-track-bad-field-in-fru.rs:7:12
+  --> $DIR/drop-track-bad-field-in-fru.rs:6:12
    |
 LL |     None { value: (), ..Default::default() }.await;
    |            ^^^^^ `Option<_>::None` does not have this field
@@ -7,7 +7,7 @@ LL |     None { value: (), ..Default::default() }.await;
    = note: all struct fields are already assigned
 
 error[E0277]: `Option<_>` is not a future
-  --> $DIR/drop-track-bad-field-in-fru.rs:7:46
+  --> $DIR/drop-track-bad-field-in-fru.rs:6:46
    |
 LL |     None { value: (), ..Default::default() }.await;
    |                                             -^^^^^
diff --git a/tests/ui/async-await/drop-track-field-assign-nonsend.rs b/tests/ui/async-await/drop-track-field-assign-nonsend.rs
index b6c0fda1521..19315ef19f9 100644
--- a/tests/ui/async-await/drop-track-field-assign-nonsend.rs
+++ b/tests/ui/async-await/drop-track-field-assign-nonsend.rs
@@ -1,6 +1,5 @@
 // Derived from an ICE found in tokio-xmpp during a crater run.
 // edition:2021
-// compile-flags: -Zdrop-tracking
 
 #![allow(dead_code)]
 
diff --git a/tests/ui/async-await/drop-track-field-assign-nonsend.stderr b/tests/ui/async-await/drop-track-field-assign-nonsend.stderr
index f36207b38a1..6c235916d64 100644
--- a/tests/ui/async-await/drop-track-field-assign-nonsend.stderr
+++ b/tests/ui/async-await/drop-track-field-assign-nonsend.stderr
@@ -1,22 +1,20 @@
 error: future cannot be sent between threads safely
-  --> $DIR/drop-track-field-assign-nonsend.rs:43:17
+  --> $DIR/drop-track-field-assign-nonsend.rs:42:17
    |
 LL |     assert_send(agent.handle());
    |                 ^^^^^^^^^^^^^^ future returned by `handle` is not `Send`
    |
    = help: within `impl Future<Output = ()>`, the trait `Send` is not implemented for `Rc<String>`
 note: future is not `Send` as this value is used across an await
-  --> $DIR/drop-track-field-assign-nonsend.rs:21:39
+  --> $DIR/drop-track-field-assign-nonsend.rs:20:39
    |
 LL |         let mut info = self.info_result.clone();
    |             -------- has type `InfoResult` which is not `Send`
 ...
 LL |         let _ = send_element(element).await;
    |                                       ^^^^^ await occurs here, with `mut info` maybe used later
-LL |     }
-   |     - `mut info` is later dropped here
 note: required by a bound in `assert_send`
-  --> $DIR/drop-track-field-assign-nonsend.rs:38:19
+  --> $DIR/drop-track-field-assign-nonsend.rs:37:19
    |
 LL | fn assert_send<T: Send>(_: T) {}
    |                   ^^^^ required by this bound in `assert_send`
diff --git a/tests/ui/async-await/drop-track-field-assign.rs b/tests/ui/async-await/drop-track-field-assign.rs
index cfea7db2a10..4887eff7efa 100644
--- a/tests/ui/async-await/drop-track-field-assign.rs
+++ b/tests/ui/async-await/drop-track-field-assign.rs
@@ -1,6 +1,5 @@
 // Derived from an ICE found in tokio-xmpp during a crater run.
 // edition:2021
-// compile-flags: -Zdrop-tracking
 // build-pass
 
 #![allow(dead_code)]
diff --git a/tests/ui/async-await/drop-tracking-unresolved-typeck-results.rs b/tests/ui/async-await/drop-tracking-unresolved-typeck-results.rs
index 7f729429581..9f80b9c6e9f 100644
--- a/tests/ui/async-await/drop-tracking-unresolved-typeck-results.rs
+++ b/tests/ui/async-await/drop-tracking-unresolved-typeck-results.rs
@@ -1,4 +1,3 @@
-// compile-flags: -Zdrop-tracking
 // incremental
 // edition: 2021
 
@@ -99,8 +98,6 @@ fn main() {
     send(async {
         //~^ ERROR implementation of `FnOnce` is not general enough
         //~| ERROR implementation of `FnOnce` is not general enough
-        //~| ERROR implementation of `FnOnce` is not general enough
-        //~| ERROR implementation of `FnOnce` is not general enough
         Next(&Buffered(Map(Empty(PhantomData), ready::<&()>), FuturesOrdered(PhantomData), 0)).await
     });
 }
diff --git a/tests/ui/async-await/drop-tracking-unresolved-typeck-results.stderr b/tests/ui/async-await/drop-tracking-unresolved-typeck-results.stderr
index aa9a22e9e72..cfb0ebe38b6 100644
--- a/tests/ui/async-await/drop-tracking-unresolved-typeck-results.stderr
+++ b/tests/ui/async-await/drop-tracking-unresolved-typeck-results.stderr
@@ -1,26 +1,9 @@
 error: implementation of `FnOnce` is not general enough
-  --> $DIR/drop-tracking-unresolved-typeck-results.rs:99:5
+  --> $DIR/drop-tracking-unresolved-typeck-results.rs:98:5
    |
 LL | /     send(async {
 LL | |
 LL | |
-LL | |
-LL | |
-LL | |         Next(&Buffered(Map(Empty(PhantomData), ready::<&()>), FuturesOrdered(PhantomData), 0)).await
-LL | |     });
-   | |______^ implementation of `FnOnce` is not general enough
-   |
-   = note: `fn(&'0 ()) -> std::future::Ready<&'0 ()> {std::future::ready::<&'0 ()>}` must implement `FnOnce<(&'1 (),)>`, for any two lifetimes `'0` and `'1`...
-   = note: ...but it actually implements `FnOnce<(&(),)>`
-
-error: implementation of `FnOnce` is not general enough
-  --> $DIR/drop-tracking-unresolved-typeck-results.rs:99:5
-   |
-LL | /     send(async {
-LL | |
-LL | |
-LL | |
-LL | |
 LL | |         Next(&Buffered(Map(Empty(PhantomData), ready::<&()>), FuturesOrdered(PhantomData), 0)).await
 LL | |     });
    | |______^ implementation of `FnOnce` is not general enough
@@ -29,28 +12,11 @@ LL | |     });
    = note: ...but it actually implements `FnOnce<(&(),)>`
 
 error: implementation of `FnOnce` is not general enough
-  --> $DIR/drop-tracking-unresolved-typeck-results.rs:99:5
+  --> $DIR/drop-tracking-unresolved-typeck-results.rs:98:5
    |
 LL | /     send(async {
 LL | |
 LL | |
-LL | |
-LL | |
-LL | |         Next(&Buffered(Map(Empty(PhantomData), ready::<&()>), FuturesOrdered(PhantomData), 0)).await
-LL | |     });
-   | |______^ implementation of `FnOnce` is not general enough
-   |
-   = note: `fn(&'0 ()) -> std::future::Ready<&'0 ()> {std::future::ready::<&'0 ()>}` must implement `FnOnce<(&'1 (),)>`, for any two lifetimes `'0` and `'1`...
-   = note: ...but it actually implements `FnOnce<(&(),)>`
-
-error: implementation of `FnOnce` is not general enough
-  --> $DIR/drop-tracking-unresolved-typeck-results.rs:99:5
-   |
-LL | /     send(async {
-LL | |
-LL | |
-LL | |
-LL | |
 LL | |         Next(&Buffered(Map(Empty(PhantomData), ready::<&()>), FuturesOrdered(PhantomData), 0)).await
 LL | |     });
    | |______^ implementation of `FnOnce` is not general enough
@@ -58,5 +24,5 @@ LL | |     });
    = note: `fn(&'0 ()) -> std::future::Ready<&'0 ()> {std::future::ready::<&'0 ()>}` must implement `FnOnce<(&'1 (),)>`, for any two lifetimes `'0` and `'1`...
    = note: ...but it actually implements `FnOnce<(&(),)>`
 
-error: aborting due to 4 previous errors
+error: aborting due to 2 previous errors
 
diff --git a/tests/ui/async-await/field-assign-nonsend.stderr b/tests/ui/async-await/field-assign-nonsend.stderr
index 481b236bbdb..3037d702447 100644
--- a/tests/ui/async-await/field-assign-nonsend.stderr
+++ b/tests/ui/async-await/field-assign-nonsend.stderr
@@ -13,8 +13,6 @@ LL |         let mut info = self.info_result.clone();
 ...
 LL |         let _ = send_element(element).await;
    |                                       ^^^^^ await occurs here, with `mut info` maybe used later
-LL |     }
-   |     - `mut info` is later dropped here
 note: required by a bound in `assert_send`
   --> $DIR/field-assign-nonsend.rs:37:19
    |
diff --git a/tests/ui/async-await/in-trait/indirect-recursion-issue-112047.rs b/tests/ui/async-await/in-trait/indirect-recursion-issue-112047.rs
index 85d17ddff94..2fe6b473df6 100644
--- a/tests/ui/async-await/in-trait/indirect-recursion-issue-112047.rs
+++ b/tests/ui/async-await/in-trait/indirect-recursion-issue-112047.rs
@@ -1,6 +1,6 @@
 // edition: 2021
 // build-fail
-//~^^ ERROR overflow evaluating the requirement `<A as Second>::{opaque#0} == _`
+//~^^ ERROR cycle detected when computing layout of
 
 #![feature(async_fn_in_trait)]
 
diff --git a/tests/ui/async-await/in-trait/indirect-recursion-issue-112047.stderr b/tests/ui/async-await/in-trait/indirect-recursion-issue-112047.stderr
index 3f487a6e5fe..e0c1acfedfc 100644
--- a/tests/ui/async-await/in-trait/indirect-recursion-issue-112047.stderr
+++ b/tests/ui/async-await/in-trait/indirect-recursion-issue-112047.stderr
@@ -1,5 +1,10 @@
-error[E0275]: overflow evaluating the requirement `<A as Second>::{opaque#0} == _`
+error[E0391]: cycle detected when computing layout of `{async fn body@$DIR/indirect-recursion-issue-112047.rs:35:27: 37:6}`
+   |
+   = note: ...which requires computing layout of `<<A as First>::Second as Second>::{opaque#0}`...
+   = note: ...which again requires computing layout of `{async fn body@$DIR/indirect-recursion-issue-112047.rs:35:27: 37:6}`, completing the cycle
+   = note: cycle used when computing layout of `<impl at $DIR/indirect-recursion-issue-112047.rs:31:1: 31:21>::second::{opaque#0}`
+   = note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
 
 error: aborting due to previous error
 
-For more information about this error, try `rustc --explain E0275`.
+For more information about this error, try `rustc --explain E0391`.
diff --git a/tests/ui/async-await/issue-64130-1-sync.rs b/tests/ui/async-await/issue-64130-1-sync.rs
index 1714cec5221..7769085a0db 100644
--- a/tests/ui/async-await/issue-64130-1-sync.rs
+++ b/tests/ui/async-await/issue-64130-1-sync.rs
@@ -13,6 +13,7 @@ fn is_sync<T: Sync>(t: T) { }
 async fn bar() {
     let x = Foo;
     baz().await;
+    drop(x);
 }
 
 async fn baz() { }
diff --git a/tests/ui/async-await/issue-64130-1-sync.stderr b/tests/ui/async-await/issue-64130-1-sync.stderr
index 06d26ea73dc..207e085d273 100644
--- a/tests/ui/async-await/issue-64130-1-sync.stderr
+++ b/tests/ui/async-await/issue-64130-1-sync.stderr
@@ -1,5 +1,5 @@
 error: future cannot be shared between threads safely
-  --> $DIR/issue-64130-1-sync.rs:21:13
+  --> $DIR/issue-64130-1-sync.rs:22:13
    |
 LL |     is_sync(bar());
    |             ^^^^^ future returned by `bar` is not `Sync`
@@ -12,8 +12,6 @@ LL |     let x = Foo;
    |         - has type `Foo` which is not `Sync`
 LL |     baz().await;
    |           ^^^^^ await occurs here, with `x` maybe used later
-LL | }
-   | - `x` is later dropped here
 note: required by a bound in `is_sync`
   --> $DIR/issue-64130-1-sync.rs:11:15
    |
diff --git a/tests/ui/async-await/issue-64130-2-send.rs b/tests/ui/async-await/issue-64130-2-send.rs
index 7a6e5952cb9..0195afe6b39 100644
--- a/tests/ui/async-await/issue-64130-2-send.rs
+++ b/tests/ui/async-await/issue-64130-2-send.rs
@@ -13,6 +13,7 @@ fn is_send<T: Send>(t: T) { }
 async fn bar() {
     let x = Foo;
     baz().await;
+    drop(x);
 }
 
 async fn baz() { }
diff --git a/tests/ui/async-await/issue-64130-2-send.stderr b/tests/ui/async-await/issue-64130-2-send.stderr
index e71c78d6800..a433c76ae70 100644
--- a/tests/ui/async-await/issue-64130-2-send.stderr
+++ b/tests/ui/async-await/issue-64130-2-send.stderr
@@ -1,5 +1,5 @@
 error: future cannot be sent between threads safely
-  --> $DIR/issue-64130-2-send.rs:21:13
+  --> $DIR/issue-64130-2-send.rs:22:13
    |
 LL |     is_send(bar());
    |             ^^^^^ future returned by `bar` is not `Send`
@@ -12,8 +12,6 @@ LL |     let x = Foo;
    |         - has type `Foo` which is not `Send`
 LL |     baz().await;
    |           ^^^^^ await occurs here, with `x` maybe used later
-LL | }
-   | - `x` is later dropped here
 note: required by a bound in `is_send`
   --> $DIR/issue-64130-2-send.rs:11:15
    |
diff --git a/tests/ui/async-await/issue-64130-3-other.rs b/tests/ui/async-await/issue-64130-3-other.rs
index 630fb2c41cd..074d67aa3fb 100644
--- a/tests/ui/async-await/issue-64130-3-other.rs
+++ b/tests/ui/async-await/issue-64130-3-other.rs
@@ -16,6 +16,7 @@ fn is_qux<T: Qux>(t: T) {}
 async fn bar() {
     let x = Foo;
     baz().await;
+    drop(x);
 }
 
 async fn baz() {}
diff --git a/tests/ui/async-await/issue-64130-3-other.stderr b/tests/ui/async-await/issue-64130-3-other.stderr
index 4107784395f..573da1034c5 100644
--- a/tests/ui/async-await/issue-64130-3-other.stderr
+++ b/tests/ui/async-await/issue-64130-3-other.stderr
@@ -1,5 +1,5 @@
 error[E0277]: the trait bound `Foo: Qux` is not satisfied in `impl Future<Output = ()>`
-  --> $DIR/issue-64130-3-other.rs:24:12
+  --> $DIR/issue-64130-3-other.rs:25:12
    |
 LL | async fn bar() {
    |                - within this `impl Future<Output = ()>`
@@ -14,8 +14,6 @@ LL |     let x = Foo;
    |         - has type `Foo` which does not implement `Qux`
 LL |     baz().await;
    |           ^^^^^ await occurs here, with `x` maybe used later
-LL | }
-   | - `x` is later dropped here
 note: required by a bound in `is_qux`
   --> $DIR/issue-64130-3-other.rs:14:14
    |
diff --git a/tests/ui/async-await/issue-64130-4-async-move.rs b/tests/ui/async-await/issue-64130-4-async-move.rs
index c333e160ef3..359813f6379 100644
--- a/tests/ui/async-await/issue-64130-4-async-move.rs
+++ b/tests/ui/async-await/issue-64130-4-async-move.rs
@@ -1,6 +1,5 @@
 // edition:2018
 // check-pass
-// compile-flags: -Zdrop-tracking=yes
 
 use std::any::Any;
 use std::future::Future;
diff --git a/tests/ui/async-await/issue-64130-non-send-future-diags.stderr b/tests/ui/async-await/issue-64130-non-send-future-diags.stderr
index e044e2ca011..cb02fcf5ce7 100644
--- a/tests/ui/async-await/issue-64130-non-send-future-diags.stderr
+++ b/tests/ui/async-await/issue-64130-non-send-future-diags.stderr
@@ -12,8 +12,6 @@ LL |     let g = x.lock().unwrap();
    |         - has type `MutexGuard<'_, u32>` which is not `Send`
 LL |     baz().await;
    |           ^^^^^ await occurs here, with `g` maybe used later
-LL | }
-   | - `g` is later dropped here
 note: required by a bound in `is_send`
   --> $DIR/issue-64130-non-send-future-diags.rs:9:15
    |
diff --git a/tests/ui/async-await/issue-67252-unnamed-future.rs b/tests/ui/async-await/issue-67252-unnamed-future.rs
index 1a7ff613341..60717d99346 100644
--- a/tests/ui/async-await/issue-67252-unnamed-future.rs
+++ b/tests/ui/async-await/issue-67252-unnamed-future.rs
@@ -16,8 +16,9 @@ impl Future for AFuture{
 
 async fn foo() {
     spawn(async { //~ ERROR future cannot be sent between threads safely
-        let _a = std::ptr::null_mut::<()>(); // `*mut ()` is not `Send`
+        let a = std::ptr::null_mut::<()>(); // `*mut ()` is not `Send`
         AFuture.await;
+        let _a = a;
     });
 }
 
diff --git a/tests/ui/async-await/issue-67252-unnamed-future.stderr b/tests/ui/async-await/issue-67252-unnamed-future.stderr
index 6aef35de0ca..069befa9121 100644
--- a/tests/ui/async-await/issue-67252-unnamed-future.stderr
+++ b/tests/ui/async-await/issue-67252-unnamed-future.stderr
@@ -1,23 +1,17 @@
 error: future cannot be sent between threads safely
-  --> $DIR/issue-67252-unnamed-future.rs:18:11
+  --> $DIR/issue-67252-unnamed-future.rs:18:5
    |
-LL |       spawn(async {
-   |  ___________^
-LL | |         let _a = std::ptr::null_mut::<()>(); // `*mut ()` is not `Send`
-LL | |         AFuture.await;
-LL | |     });
-   | |_____^ future created by async block is not `Send`
+LL |     spawn(async {
+   |     ^^^^^ future created by async block is not `Send`
    |
-   = help: within `{async block@$DIR/issue-67252-unnamed-future.rs:18:11: 21:6}`, the trait `Send` is not implemented for `*mut ()`
+   = help: within `{async block@$DIR/issue-67252-unnamed-future.rs:18:11: 22:6}`, the trait `Send` is not implemented for `*mut ()`
 note: future is not `Send` as this value is used across an await
   --> $DIR/issue-67252-unnamed-future.rs:20:17
    |
-LL |         let _a = std::ptr::null_mut::<()>(); // `*mut ()` is not `Send`
-   |             -- has type `*mut ()` which is not `Send`
+LL |         let a = std::ptr::null_mut::<()>(); // `*mut ()` is not `Send`
+   |             - has type `*mut ()` which is not `Send`
 LL |         AFuture.await;
-   |                 ^^^^^ await occurs here, with `_a` maybe used later
-LL |     });
-   |     - `_a` is later dropped here
+   |                 ^^^^^ await occurs here, with `a` maybe used later
 note: required by a bound in `spawn`
   --> $DIR/issue-67252-unnamed-future.rs:6:13
    |
diff --git a/tests/ui/async-await/issue-68112.rs b/tests/ui/async-await/issue-68112.rs
index 0005b90efc2..fd6089e0c03 100644
--- a/tests/ui/async-await/issue-68112.rs
+++ b/tests/ui/async-await/issue-68112.rs
@@ -11,7 +11,7 @@ use std::{
 fn require_send(_: impl Send) {}
 
 struct Ready<T>(Option<T>);
-impl<T> Future for Ready<T> {
+impl<T: Unpin> Future for Ready<T> {
     type Output = T;
     fn poll(mut self: Pin<&mut Self>, _cx: &mut Context<'_>) -> Poll<T> {
         Poll::Ready(self.0.take().unwrap())
diff --git a/tests/ui/async-await/issue-68112.stderr b/tests/ui/async-await/issue-68112.stderr
index aec2541c9e6..17b619ebee3 100644
--- a/tests/ui/async-await/issue-68112.stderr
+++ b/tests/ui/async-await/issue-68112.stderr
@@ -1,8 +1,8 @@
 error: future cannot be sent between threads safely
-  --> $DIR/issue-68112.rs:34:18
+  --> $DIR/issue-68112.rs:34:5
    |
 LL |     require_send(send_fut);
-   |                  ^^^^^^^^ future created by async block is not `Send`
+   |     ^^^^^^^^^^^^ future created by async block is not `Send`
    |
    = help: the trait `Sync` is not implemented for `RefCell<i32>`
    = note: if you want to do aliasing and mutation between multiple threads, use `std::sync::RwLock` instead
@@ -18,10 +18,10 @@ LL | fn require_send(_: impl Send) {}
    |                         ^^^^ required by this bound in `require_send`
 
 error: future cannot be sent between threads safely
-  --> $DIR/issue-68112.rs:43:18
+  --> $DIR/issue-68112.rs:43:5
    |
 LL |     require_send(send_fut);
-   |                  ^^^^^^^^ future created by async block is not `Send`
+   |     ^^^^^^^^^^^^ future created by async block is not `Send`
    |
    = help: the trait `Sync` is not implemented for `RefCell<i32>`
    = note: if you want to do aliasing and mutation between multiple threads, use `std::sync::RwLock` instead
@@ -37,12 +37,10 @@ LL | fn require_send(_: impl Send) {}
    |                         ^^^^ required by this bound in `require_send`
 
 error[E0277]: `RefCell<i32>` cannot be shared between threads safely
-  --> $DIR/issue-68112.rs:62:18
+  --> $DIR/issue-68112.rs:62:5
    |
 LL |     require_send(send_fut);
-   |     ------------ ^^^^^^^^ `RefCell<i32>` cannot be shared between threads safely
-   |     |
-   |     required by a bound introduced by this call
+   |     ^^^^^^^^^^^^ `RefCell<i32>` cannot be shared between threads safely
    |
    = help: the trait `Sync` is not implemented for `RefCell<i32>`
    = note: if you want to do aliasing and mutation between multiple threads, use `std::sync::RwLock` instead
@@ -60,7 +58,7 @@ note: required because it appears within the type `impl Future<Output = Arc<RefC
    |
 LL | fn make_non_send_future2() -> impl Future<Output = Arc<RefCell<i32>>> {
    |                               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   = note: required because it captures the following types: `ResumeTy`, `impl Future<Output = Arc<RefCell<i32>>>`, `()`, `i32`, `Ready<i32>`
+   = note: required because it captures the following types: `impl Future<Output = Arc<RefCell<i32>>>`, `Ready<i32>`
 note: required because it's used within this `async` block
   --> $DIR/issue-68112.rs:57:20
    |
diff --git a/tests/ui/async-await/issue-70935-complex-spans.rs b/tests/ui/async-await/issue-70935-complex-spans.rs
index 33aa89c5a5d..4af73739584 100644
--- a/tests/ui/async-await/issue-70935-complex-spans.rs
+++ b/tests/ui/async-await/issue-70935-complex-spans.rs
@@ -13,7 +13,7 @@ async fn baz<T>(_c: impl FnMut() -> T) where T: Future<Output=()> {
 }
 
 fn foo(x: NotSync) -> impl Future + Send {
-    //~^ ERROR future cannot be sent between threads safely
+    //~^ ERROR `*mut ()` cannot be shared between threads safely
     async move {
         baz(|| async {
             foo(x.clone());
diff --git a/tests/ui/async-await/issue-70935-complex-spans.stderr b/tests/ui/async-await/issue-70935-complex-spans.stderr
index 5d8ef77616a..ab834daa85d 100644
--- a/tests/ui/async-await/issue-70935-complex-spans.stderr
+++ b/tests/ui/async-await/issue-70935-complex-spans.stderr
@@ -1,21 +1,41 @@
-error: future cannot be sent between threads safely
+error[E0277]: `*mut ()` cannot be shared between threads safely
   --> $DIR/issue-70935-complex-spans.rs:15:23
    |
 LL | fn foo(x: NotSync) -> impl Future + Send {
-   |                       ^^^^^^^^^^^^^^^^^^ future created by async block is not `Send`
+   |                       ^^^^^^^^^^^^^^^^^^ `*mut ()` cannot be shared between threads safely
    |
    = help: within `NotSync`, the trait `Sync` is not implemented for `*mut ()`
-note: future is not `Send` as this value is used across an await
-  --> $DIR/issue-70935-complex-spans.rs:20:12
+note: required because it appears within the type `PhantomData<*mut ()>`
+  --> $SRC_DIR/core/src/marker.rs:LL:COL
+note: required because it appears within the type `NotSync`
+  --> $DIR/issue-70935-complex-spans.rs:9:8
    |
-LL |           baz(|| async {
-   |  _____________-
+LL | struct NotSync(PhantomData<*mut ()>);
+   |        ^^^^^^^
+   = note: required for `&NotSync` to implement `Send`
+note: required because it's used within this closure
+  --> $DIR/issue-70935-complex-spans.rs:18:13
+   |
+LL |         baz(|| async {
+   |             ^^
+note: required because it's used within this `async fn` body
+  --> $DIR/issue-70935-complex-spans.rs:12:67
+   |
+LL |   async fn baz<T>(_c: impl FnMut() -> T) where T: Future<Output=()> {
+   |  ___________________________________________________________________^
+LL | | }
+   | |_^
+   = note: required because it captures the following types: `impl Future<Output = ()>`
+note: required because it's used within this `async` block
+  --> $DIR/issue-70935-complex-spans.rs:17:5
+   |
+LL | /     async move {
+LL | |         baz(|| async {
 LL | |             foo(x.clone());
 LL | |         }).await;
-   | |         -  ^^^^^- the value is later dropped here
-   | |         |  |
-   | |_________|  await occurs here, with the value maybe used later
-   |           has type `{closure@$DIR/issue-70935-complex-spans.rs:18:13: 18:15}` which is not `Send`
+LL | |     }
+   | |_____^
 
 error: aborting due to previous error
 
+For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/async-await/issue-71137.stderr b/tests/ui/async-await/issue-71137.stderr
index a344246d6bf..443af010c4a 100644
--- a/tests/ui/async-await/issue-71137.stderr
+++ b/tests/ui/async-await/issue-71137.stderr
@@ -12,9 +12,6 @@ LL |     let mut guard = m.lock().unwrap();
    |         --------- has type `MutexGuard<'_, i32>` which is not `Send`
 LL |     (async { "right"; }).await;
    |                          ^^^^^ await occurs here, with `mut guard` maybe used later
-LL |     *guard += 1;
-LL |   }
-   |   - `mut guard` is later dropped here
 note: required by a bound in `fake_spawn`
   --> $DIR/issue-71137.rs:8:27
    |
diff --git a/tests/ui/async-await/issue-93197.rs b/tests/ui/async-await/issue-93197.rs
index c627fe17afb..05ec013d0af 100644
--- a/tests/ui/async-await/issue-93197.rs
+++ b/tests/ui/async-await/issue-93197.rs
@@ -1,7 +1,6 @@
 // Regression test for #93197
 // check-pass
 // edition:2021
-// compile-flags: -Zdrop-tracking
 
 #![feature(try_blocks)]
 
diff --git a/tests/ui/async-await/issue-93648.rs b/tests/ui/async-await/issue-93648.rs
index 4ce3ac1e874..b27a79a428b 100644
--- a/tests/ui/async-await/issue-93648.rs
+++ b/tests/ui/async-await/issue-93648.rs
@@ -1,6 +1,5 @@
 // edition:2021
 // build-pass
-// compile-flags: -Zdrop-tracking
 
 fn main() {
     let _ = async {
diff --git a/tests/ui/async-await/issues/auxiliary/issue_67893.rs b/tests/ui/async-await/issues/auxiliary/issue_67893.rs
index 387966a5064..efde4d2864d 100644
--- a/tests/ui/async-await/issues/auxiliary/issue_67893.rs
+++ b/tests/ui/async-await/issues/auxiliary/issue_67893.rs
@@ -2,9 +2,11 @@
 
 use std::sync::{Arc, Mutex};
 
+fn make_arc() -> Arc<Mutex<()>> { unimplemented!() }
+
 pub async fn f(_: ()) {}
 
 pub async fn run() {
-    let x: Arc<Mutex<()>> = unimplemented!();
+    let x: Arc<Mutex<()>> = make_arc();
     f(*x.lock().unwrap()).await;
 }
diff --git a/tests/ui/async-await/issues/issue-107280.rs b/tests/ui/async-await/issues/issue-107280.rs
index 85fce87403a..81ae9553cf0 100644
--- a/tests/ui/async-await/issues/issue-107280.rs
+++ b/tests/ui/async-await/issues/issue-107280.rs
@@ -3,11 +3,6 @@
 async fn foo() {
     inner::<false>().await
     //~^ ERROR: function takes 2 generic arguments but 1 generic argument was supplied
-    //~| ERROR: type inside `async fn` body must be known in this context
-    //~| ERROR: type inside `async fn` body must be known in this context
-    //~| ERROR: type inside `async fn` body must be known in this context
-    //~| ERROR: type inside `async fn` body must be known in this context
-    //~| ERROR: type inside `async fn` body must be known in this context
 }
 
 async fn inner<T, const PING: bool>() {}
diff --git a/tests/ui/async-await/issues/issue-107280.stderr b/tests/ui/async-await/issues/issue-107280.stderr
index 2e69862a0e0..c5fd5c5bf0a 100644
--- a/tests/ui/async-await/issues/issue-107280.stderr
+++ b/tests/ui/async-await/issues/issue-107280.stderr
@@ -7,7 +7,7 @@ LL |     inner::<false>().await
    |     expected 2 generic arguments
    |
 note: function defined here, with 2 generic parameters: `T`, `PING`
-  --> $DIR/issue-107280.rs:13:10
+  --> $DIR/issue-107280.rs:8:10
    |
 LL | async fn inner<T, const PING: bool>() {}
    |          ^^^^^ -  ----------------
@@ -16,67 +16,6 @@ help: add missing generic argument
 LL |     inner::<false, PING>().await
    |                  ++++++
 
-error[E0698]: type inside `async fn` body must be known in this context
-  --> $DIR/issue-107280.rs:4:5
-   |
-LL |     inner::<false>().await
-   |     ^^^^^^^^^^^^^^ cannot infer the value of const parameter `PING` declared on the function `inner`
-   |
-note: the type is part of the `async fn` body because of this `await`
-  --> $DIR/issue-107280.rs:4:22
-   |
-LL |     inner::<false>().await
-   |                      ^^^^^
-
-error[E0698]: type inside `async fn` body must be known in this context
-  --> $DIR/issue-107280.rs:4:5
-   |
-LL |     inner::<false>().await
-   |     ^^^^^^^^^^^^^^ cannot infer the value of const parameter `PING` declared on the function `inner`
-   |
-note: the type is part of the `async fn` body because of this `await`
-  --> $DIR/issue-107280.rs:4:22
-   |
-LL |     inner::<false>().await
-   |                      ^^^^^
-
-error[E0698]: type inside `async fn` body must be known in this context
-  --> $DIR/issue-107280.rs:4:5
-   |
-LL |     inner::<false>().await
-   |     ^^^^^^^^^^^^^^ cannot infer the value of const parameter `PING` declared on the function `inner`
-   |
-note: the type is part of the `async fn` body because of this `await`
-  --> $DIR/issue-107280.rs:4:22
-   |
-LL |     inner::<false>().await
-   |                      ^^^^^
-
-error[E0698]: type inside `async fn` body must be known in this context
-  --> $DIR/issue-107280.rs:4:5
-   |
-LL |     inner::<false>().await
-   |     ^^^^^^^^^^^^^^ cannot infer the value of const parameter `PING` declared on the function `inner`
-   |
-note: the type is part of the `async fn` body because of this `await`
-  --> $DIR/issue-107280.rs:4:22
-   |
-LL |     inner::<false>().await
-   |                      ^^^^^
-
-error[E0698]: type inside `async fn` body must be known in this context
-  --> $DIR/issue-107280.rs:4:5
-   |
-LL |     inner::<false>().await
-   |     ^^^^^^^^^^^^^^ cannot infer the value of const parameter `PING` declared on the function `inner`
-   |
-note: the type is part of the `async fn` body because of this `await`
-  --> $DIR/issue-107280.rs:4:22
-   |
-LL |     inner::<false>().await
-   |                      ^^^^^
-
-error: aborting due to 6 previous errors
+error: aborting due to previous error
 
-Some errors have detailed explanations: E0107, E0698.
-For more information about an error, try `rustc --explain E0107`.
+For more information about this error, try `rustc --explain E0107`.
diff --git a/tests/ui/async-await/issues/issue-65436-raw-ptr-not-send.rs b/tests/ui/async-await/issues/issue-65436-raw-ptr-not-send.rs
index a6a45bea897..ef6f105f34a 100644
--- a/tests/ui/async-await/issues/issue-65436-raw-ptr-not-send.rs
+++ b/tests/ui/async-await/issues/issue-65436-raw-ptr-not-send.rs
@@ -1,6 +1,5 @@
 // edition:2018
 // check-pass
-// compile-flags: -Zdrop-tracking=yes
 
 struct Foo(*const u8);
 
diff --git a/tests/ui/async-await/issues/issue-67893.rs b/tests/ui/async-await/issues/issue-67893.rs
index d73772e5fa0..359c75f170c 100644
--- a/tests/ui/async-await/issues/issue-67893.rs
+++ b/tests/ui/async-await/issues/issue-67893.rs
@@ -7,5 +7,5 @@ fn g(_: impl Send) {}
 
 fn main() {
     g(issue_67893::run())
-    //~^ ERROR future cannot be sent between threads safely
+    //~^ ERROR `MutexGuard<'_, ()>` cannot be sent between threads safely
 }
diff --git a/tests/ui/async-await/issues/issue-67893.stderr b/tests/ui/async-await/issues/issue-67893.stderr
index e1bea29e923..f36269e8f36 100644
--- a/tests/ui/async-await/issues/issue-67893.stderr
+++ b/tests/ui/async-await/issues/issue-67893.stderr
@@ -1,18 +1,27 @@
-error: future cannot be sent between threads safely
+error[E0277]: `MutexGuard<'_, ()>` cannot be sent between threads safely
   --> $DIR/issue-67893.rs:9:7
    |
 LL |     g(issue_67893::run())
-   |       ^^^^^^^^^^^^^^^^^^ future is not `Send`
+   |     - ^^^^^^^^^^^^^^^^^^ `MutexGuard<'_, ()>` cannot be sent between threads safely
+   |     |
+   |     required by a bound introduced by this call
+   |
+  ::: $DIR/auxiliary/issue_67893.rs:9:20
+   |
+LL | pub async fn run() {
+   |                    - within this `impl Future<Output = ()>`
    |
    = help: within `impl Future<Output = ()>`, the trait `Send` is not implemented for `MutexGuard<'_, ()>`
-note: future is not `Send` as this value is used across an await
-  --> $DIR/auxiliary/issue_67893.rs:9:27
+   = note: required because it captures the following types: `Arc<Mutex<()>>`, `MutexGuard<'_, ()>`, `impl Future<Output = ()>`
+note: required because it's used within this `async fn` body
+  --> $DIR/auxiliary/issue_67893.rs:9:20
    |
-LL |     f(*x.lock().unwrap()).await;
-   |        -----------------  ^^^^^- `x.lock().unwrap()` is later dropped here
-   |        |                  |
-   |        |                  await occurs here, with `x.lock().unwrap()` maybe used later
-   |        has type `MutexGuard<'_, ()>` which is not `Send`
+LL |   pub async fn run() {
+   |  ____________________^
+LL | |     let x: Arc<Mutex<()>> = make_arc();
+LL | |     f(*x.lock().unwrap()).await;
+LL | | }
+   | |_^
 note: required by a bound in `g`
   --> $DIR/issue-67893.rs:6:14
    |
@@ -21,3 +30,4 @@ LL | fn g(_: impl Send) {}
 
 error: aborting due to previous error
 
+For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/async-await/non-trivial-drop.rs b/tests/ui/async-await/non-trivial-drop.rs
index 214e345783b..3fed7c972a1 100644
--- a/tests/ui/async-await/non-trivial-drop.rs
+++ b/tests/ui/async-await/non-trivial-drop.rs
@@ -1,6 +1,5 @@
 // build-pass
 // edition:2018
-// compile-flags: -Zdrop-tracking=y
 
 #![feature(generators)]
 
diff --git a/tests/ui/async-await/partial-drop-partial-reinit.stderr b/tests/ui/async-await/partial-drop-partial-reinit.stderr
index 05f5358340a..85e1830c78e 100644
--- a/tests/ui/async-await/partial-drop-partial-reinit.stderr
+++ b/tests/ui/async-await/partial-drop-partial-reinit.stderr
@@ -11,7 +11,7 @@ LL | async fn foo() {
    |
    = help: within `impl Future<Output = ()>`, the trait `Send` is not implemented for `NotSend`
    = note: required because it appears within the type `(NotSend,)`
-   = note: required because it captures the following types: `ResumeTy`, `(NotSend,)`, `impl Future<Output = ()>`, `()`
+   = note: required because it captures the following types: `(NotSend,)`, `impl Future<Output = ()>`
 note: required because it's used within this `async fn` body
   --> $DIR/partial-drop-partial-reinit.rs:28:16
    |
diff --git a/tests/ui/async-await/return-type-notation/issue-110963-early.current.stderr b/tests/ui/async-await/return-type-notation/issue-110963-early.current.stderr
index 1b847b59eb5..77385e966ce 100644
--- a/tests/ui/async-await/return-type-notation/issue-110963-early.current.stderr
+++ b/tests/ui/async-await/return-type-notation/issue-110963-early.current.stderr
@@ -7,7 +7,7 @@ LL | #![feature(return_type_notation)]
    = note: see issue #109417 <https://github.com/rust-lang/rust/issues/109417> for more information
    = note: `#[warn(incomplete_features)]` on by default
 
-error: higher-ranked lifetime error
+error[E0308]: mismatched types
   --> $DIR/issue-110963-early.rs:17:5
    |
 LL | /     spawn(async move {
@@ -16,11 +16,17 @@ LL | |         if !hc.check().await {
 LL | |             log_health_check_failure().await;
 LL | |         }
 LL | |     });
-   | |______^
+   | |______^ one type is more general than the other
    |
-   = note: could not prove `[async block@$DIR/issue-110963-early.rs:17:11: 22:6]: Send`
+   = note: expected trait `Send`
+              found trait `for<'a> Send`
+note: the lifetime requirement is introduced here
+  --> $DIR/issue-110963-early.rs:37:17
+   |
+LL |     F: Future + Send + 'static,
+   |                 ^^^^
 
-error: higher-ranked lifetime error
+error[E0308]: mismatched types
   --> $DIR/issue-110963-early.rs:17:5
    |
 LL | /     spawn(async move {
@@ -29,9 +35,16 @@ LL | |         if !hc.check().await {
 LL | |             log_health_check_failure().await;
 LL | |         }
 LL | |     });
-   | |______^
+   | |______^ one type is more general than the other
+   |
+   = note: expected trait `Send`
+              found trait `for<'a> Send`
+note: the lifetime requirement is introduced here
+  --> $DIR/issue-110963-early.rs:37:17
    |
-   = note: could not prove `[async block@$DIR/issue-110963-early.rs:17:11: 22:6]: Send`
+LL |     F: Future + Send + 'static,
+   |                 ^^^^
 
 error: aborting due to 2 previous errors; 1 warning emitted
 
+For more information about this error, try `rustc --explain E0308`.
diff --git a/tests/ui/async-await/return-type-notation/issue-110963-early.next.stderr b/tests/ui/async-await/return-type-notation/issue-110963-early.next.stderr
index 1b847b59eb5..77385e966ce 100644
--- a/tests/ui/async-await/return-type-notation/issue-110963-early.next.stderr
+++ b/tests/ui/async-await/return-type-notation/issue-110963-early.next.stderr
@@ -7,7 +7,7 @@ LL | #![feature(return_type_notation)]
    = note: see issue #109417 <https://github.com/rust-lang/rust/issues/109417> for more information
    = note: `#[warn(incomplete_features)]` on by default
 
-error: higher-ranked lifetime error
+error[E0308]: mismatched types
   --> $DIR/issue-110963-early.rs:17:5
    |
 LL | /     spawn(async move {
@@ -16,11 +16,17 @@ LL | |         if !hc.check().await {
 LL | |             log_health_check_failure().await;
 LL | |         }
 LL | |     });
-   | |______^
+   | |______^ one type is more general than the other
    |
-   = note: could not prove `[async block@$DIR/issue-110963-early.rs:17:11: 22:6]: Send`
+   = note: expected trait `Send`
+              found trait `for<'a> Send`
+note: the lifetime requirement is introduced here
+  --> $DIR/issue-110963-early.rs:37:17
+   |
+LL |     F: Future + Send + 'static,
+   |                 ^^^^
 
-error: higher-ranked lifetime error
+error[E0308]: mismatched types
   --> $DIR/issue-110963-early.rs:17:5
    |
 LL | /     spawn(async move {
@@ -29,9 +35,16 @@ LL | |         if !hc.check().await {
 LL | |             log_health_check_failure().await;
 LL | |         }
 LL | |     });
-   | |______^
+   | |______^ one type is more general than the other
+   |
+   = note: expected trait `Send`
+              found trait `for<'a> Send`
+note: the lifetime requirement is introduced here
+  --> $DIR/issue-110963-early.rs:37:17
    |
-   = note: could not prove `[async block@$DIR/issue-110963-early.rs:17:11: 22:6]: Send`
+LL |     F: Future + Send + 'static,
+   |                 ^^^^
 
 error: aborting due to 2 previous errors; 1 warning emitted
 
+For more information about this error, try `rustc --explain E0308`.
diff --git a/tests/ui/async-await/return-type-notation/issue-110963-early.stderr b/tests/ui/async-await/return-type-notation/issue-110963-early.stderr
index 4ca5519c438..969094a2c58 100644
--- a/tests/ui/async-await/return-type-notation/issue-110963-early.stderr
+++ b/tests/ui/async-await/return-type-notation/issue-110963-early.stderr
@@ -7,7 +7,7 @@ LL | #![feature(return_type_notation)]
    = note: see issue #109417 <https://github.com/rust-lang/rust/issues/109417> for more information
    = note: `#[warn(incomplete_features)]` on by default
 
-error: higher-ranked lifetime error
+error[E0308]: mismatched types
   --> $DIR/issue-110963-early.rs:15:5
    |
 LL | /     spawn(async move {
@@ -16,11 +16,17 @@ LL | |         if !hc.check().await {
 LL | |             log_health_check_failure().await;
 LL | |         }
 LL | |     });
-   | |______^
+   | |______^ one type is more general than the other
    |
-   = note: could not prove `{async block@$DIR/issue-110963-early.rs:15:11: 20:6}: Send`
+   = note: expected trait `Send`
+              found trait `for<'a> Send`
+note: the lifetime requirement is introduced here
+  --> $DIR/issue-110963-early.rs:35:17
+   |
+LL |     F: Future + Send + 'static,
+   |                 ^^^^
 
-error: higher-ranked lifetime error
+error[E0308]: mismatched types
   --> $DIR/issue-110963-early.rs:15:5
    |
 LL | /     spawn(async move {
@@ -29,9 +35,16 @@ LL | |         if !hc.check().await {
 LL | |             log_health_check_failure().await;
 LL | |         }
 LL | |     });
-   | |______^
+   | |______^ one type is more general than the other
+   |
+   = note: expected trait `Send`
+              found trait `for<'a> Send`
+note: the lifetime requirement is introduced here
+  --> $DIR/issue-110963-early.rs:35:17
    |
-   = note: could not prove `{async block@$DIR/issue-110963-early.rs:15:11: 20:6}: Send`
+LL |     F: Future + Send + 'static,
+   |                 ^^^^
 
 error: aborting due to 2 previous errors; 1 warning emitted
 
+For more information about this error, try `rustc --explain E0308`.
diff --git a/tests/ui/async-await/unresolved_type_param.rs b/tests/ui/async-await/unresolved_type_param.rs
index 6d6d8061491..dd5aa0dd077 100644
--- a/tests/ui/async-await/unresolved_type_param.rs
+++ b/tests/ui/async-await/unresolved_type_param.rs
@@ -2,23 +2,11 @@
 // Error message should pinpoint the type parameter T as needing to be bound
 // (rather than give a general error message)
 // edition:2018
-// compile-flags: -Zdrop-tracking
 
 async fn bar<T>() -> () {}
 
 async fn foo() {
     bar().await;
-    //~^ ERROR type inside `async fn` body must be known in this context
-    //~| ERROR type inside `async fn` body must be known in this context
-    //~| ERROR type inside `async fn` body must be known in this context
-    //~| NOTE cannot infer type for type parameter `T`
-    //~| NOTE cannot infer type for type parameter `T`
-    //~| NOTE cannot infer type for type parameter `T`
-    //~| NOTE the type is part of the `async fn` body because of this `await`
-    //~| NOTE the type is part of the `async fn` body because of this `await`
-    //~| NOTE the type is part of the `async fn` body because of this `await`
-    //~| NOTE in this expansion of desugaring of `await`
-    //~| NOTE in this expansion of desugaring of `await`
-    //~| NOTE in this expansion of desugaring of `await`
+    //~^ ERROR type annotations needed
 }
 fn main() {}
diff --git a/tests/ui/async-await/unresolved_type_param.stderr b/tests/ui/async-await/unresolved_type_param.stderr
index ea78c2818c7..45aa766065e 100644
--- a/tests/ui/async-await/unresolved_type_param.stderr
+++ b/tests/ui/async-await/unresolved_type_param.stderr
@@ -1,39 +1,14 @@
-error[E0698]: type inside `async fn` body must be known in this context
-  --> $DIR/unresolved_type_param.rs:10:5
+error[E0282]: type annotations needed
+  --> $DIR/unresolved_type_param.rs:9:5
    |
 LL |     bar().await;
-   |     ^^^ cannot infer type for type parameter `T` declared on the function `bar`
+   |     ^^^ cannot infer type of the type parameter `T` declared on the function `bar`
    |
-note: the type is part of the `async fn` body because of this `await`
-  --> $DIR/unresolved_type_param.rs:10:11
+help: consider specifying the generic argument
    |
-LL |     bar().await;
-   |           ^^^^^
-
-error[E0698]: type inside `async fn` body must be known in this context
-  --> $DIR/unresolved_type_param.rs:10:5
-   |
-LL |     bar().await;
-   |     ^^^ cannot infer type for type parameter `T` declared on the function `bar`
-   |
-note: the type is part of the `async fn` body because of this `await`
-  --> $DIR/unresolved_type_param.rs:10:11
-   |
-LL |     bar().await;
-   |           ^^^^^
-
-error[E0698]: type inside `async fn` body must be known in this context
-  --> $DIR/unresolved_type_param.rs:10:5
-   |
-LL |     bar().await;
-   |     ^^^ cannot infer type for type parameter `T` declared on the function `bar`
-   |
-note: the type is part of the `async fn` body because of this `await`
-  --> $DIR/unresolved_type_param.rs:10:11
-   |
-LL |     bar().await;
-   |           ^^^^^
+LL |     bar::<T>().await;
+   |        +++++
 
-error: aborting due to 3 previous errors
+error: aborting due to previous error
 
-For more information about this error, try `rustc --explain E0698`.
+For more information about this error, try `rustc --explain E0282`.
diff --git a/tests/ui/borrowck/async-reference-generality.rs b/tests/ui/borrowck/async-reference-generality.rs
index 487d1ac81bf..668df9ea710 100644
--- a/tests/ui/borrowck/async-reference-generality.rs
+++ b/tests/ui/borrowck/async-reference-generality.rs
@@ -1,5 +1,4 @@
-// check-fail
-// known-bug: #99492
+// check-pass
 // edition: 2021
 
 use std::marker::PhantomData;
diff --git a/tests/ui/borrowck/async-reference-generality.stderr b/tests/ui/borrowck/async-reference-generality.stderr
deleted file mode 100644
index af720ad2931..00000000000
--- a/tests/ui/borrowck/async-reference-generality.stderr
+++ /dev/null
@@ -1,27 +0,0 @@
-error[E0308]: mismatched types
-  --> $DIR/async-reference-generality.rs:23:5
-   |
-LL | /     async {
-LL | |         let _x = Struct::<Empty<&'static ()>, _>(PhantomData);
-LL | |         async {}.await;
-LL | |     }
-   | |_____^ one type is more general than the other
-   |
-   = note: expected reference `&()`
-              found reference `&()`
-
-error[E0308]: mismatched types
-  --> $DIR/async-reference-generality.rs:23:5
-   |
-LL | /     async {
-LL | |         let _x = Struct::<Empty<&'static ()>, _>(PhantomData);
-LL | |         async {}.await;
-LL | |     }
-   | |_____^ one type is more general than the other
-   |
-   = note: expected reference `&()`
-              found reference `&()`
-
-error: aborting due to 2 previous errors
-
-For more information about this error, try `rustc --explain E0308`.
diff --git a/tests/ui/borrowck/erase-error-in-mir-drop-tracking.rs b/tests/ui/borrowck/erase-error-in-mir-drop-tracking.rs
deleted file mode 100644
index addbe5d658a..00000000000
--- a/tests/ui/borrowck/erase-error-in-mir-drop-tracking.rs
+++ /dev/null
@@ -1,23 +0,0 @@
-// compile-flags: -Zdrop-tracking-mir
-// edition:2021
-
-use std::future::Future;
-
-trait Client {
-    type Connecting<'a>: Future + Send
-    where
-        Self: 'a;
-
-    fn connect(&'_ self) -> Self::Connecting<'a>;
-    //~^ ERROR use of undeclared lifetime name `'a`
-}
-
-fn call_connect<C>(c: &'_ C) -> impl '_ + Future + Send
-where
-    C: Client + Send + Sync,
-{
-    async move { c.connect().await }
-    //~^ ERROR `C` does not live long enough
-}
-
-fn main() {}
diff --git a/tests/ui/borrowck/erase-error-in-mir-drop-tracking.stderr b/tests/ui/borrowck/erase-error-in-mir-drop-tracking.stderr
deleted file mode 100644
index 53abe3dc952..00000000000
--- a/tests/ui/borrowck/erase-error-in-mir-drop-tracking.stderr
+++ /dev/null
@@ -1,24 +0,0 @@
-error[E0261]: use of undeclared lifetime name `'a`
-  --> $DIR/erase-error-in-mir-drop-tracking.rs:11:46
-   |
-LL |     fn connect(&'_ self) -> Self::Connecting<'a>;
-   |                                              ^^ undeclared lifetime
-   |
-help: consider introducing lifetime `'a` here
-   |
-LL |     fn connect<'a>(&'_ self) -> Self::Connecting<'a>;
-   |               ++++
-help: consider introducing lifetime `'a` here
-   |
-LL | trait Client<'a> {
-   |             ++++
-
-error: `C` does not live long enough
-  --> $DIR/erase-error-in-mir-drop-tracking.rs:19:5
-   |
-LL |     async move { c.connect().await }
-   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-
-error: aborting due to 2 previous errors
-
-For more information about this error, try `rustc --explain E0261`.
diff --git a/tests/ui/codegen/subtyping-enforces-type-equality.stderr b/tests/ui/codegen/subtyping-enforces-type-equality.stderr
deleted file mode 100644
index 870ca0f839f..00000000000
--- a/tests/ui/codegen/subtyping-enforces-type-equality.stderr
+++ /dev/null
@@ -1 +0,0 @@
-WARN rustc_codegen_ssa::mir::locals Unexpected initial operand type. See the issues/114858
diff --git a/tests/ui/generator/borrowing.stderr b/tests/ui/generator/borrowing.stderr
index 38e1ace8c4e..03a69fe3623 100644
--- a/tests/ui/generator/borrowing.stderr
+++ b/tests/ui/generator/borrowing.stderr
@@ -1,16 +1,24 @@
 error[E0597]: `a` does not live long enough
   --> $DIR/borrowing.rs:9:33
    |
-LL |     let _b = {
-   |         -- borrow later stored here
-LL |         let a = 3;
 LL |         Pin::new(&mut || yield &a).resume(())
-   |                       --        ^ borrowed value does not live long enough
-   |                       |
+   |                       ----------^
+   |                       |         |
+   |                       |         borrowed value does not live long enough
    |                       value captured here by generator
+   |                       a temporary with access to the borrow is created here ...
 LL |
 LL |     };
-   |     - `a` dropped here while still borrowed
+   |     -- ... and the borrow might be used here, when that temporary is dropped and runs the destructor for generator
+   |     |
+   |     `a` dropped here while still borrowed
+   |
+   = note: the temporary is part of an expression at the end of a block;
+           consider forcing this temporary to be dropped sooner, before the block's local variables are dropped
+help: for example, you could save the expression's value in a new local variable `x` and then make `x` be the expression at the end of the block
+   |
+LL |         let x = Pin::new(&mut || yield &a).resume(()); x
+   |         +++++++                                      +++
 
 error[E0597]: `a` does not live long enough
   --> $DIR/borrowing.rs:16:20
diff --git a/tests/ui/generator/clone-impl.stderr b/tests/ui/generator/clone-impl.stderr
index edd3eb7e3da..870216398b1 100644
--- a/tests/ui/generator/clone-impl.stderr
+++ b/tests/ui/generator/clone-impl.stderr
@@ -1,11 +1,11 @@
 error[E0277]: the trait bound `Vec<u32>: Copy` is not satisfied in `{generator@$DIR/clone-impl.rs:36:23: 36:30}`
-  --> $DIR/clone-impl.rs:42:16
+  --> $DIR/clone-impl.rs:42:5
    |
 LL |     let gen_clone_0 = move || {
    |                       ------- within this `{generator@$DIR/clone-impl.rs:36:23: 36:30}`
 ...
 LL |     check_copy(&gen_clone_0);
-   |                ^^^^^^^^^^^^ within `{generator@$DIR/clone-impl.rs:36:23: 36:30}`, the trait `Copy` is not implemented for `Vec<u32>`
+   |     ^^^^^^^^^^ within `{generator@$DIR/clone-impl.rs:36:23: 36:30}`, the trait `Copy` is not implemented for `Vec<u32>`
    |
 note: captured value does not implement `Copy`
   --> $DIR/clone-impl.rs:40:14
@@ -19,13 +19,13 @@ LL | fn check_copy<T: Copy>(_x: &T) {}
    |                  ^^^^ required by this bound in `check_copy`
 
 error[E0277]: the trait bound `Vec<char>: Copy` is not satisfied in `{generator@$DIR/clone-impl.rs:36:23: 36:30}`
-  --> $DIR/clone-impl.rs:42:16
+  --> $DIR/clone-impl.rs:42:5
    |
 LL |     let gen_clone_0 = move || {
    |                       ------- within this `{generator@$DIR/clone-impl.rs:36:23: 36:30}`
 ...
 LL |     check_copy(&gen_clone_0);
-   |                ^^^^^^^^^^^^ within `{generator@$DIR/clone-impl.rs:36:23: 36:30}`, the trait `Copy` is not implemented for `Vec<char>`
+   |     ^^^^^^^^^^ within `{generator@$DIR/clone-impl.rs:36:23: 36:30}`, the trait `Copy` is not implemented for `Vec<char>`
    |
 note: generator does not implement `Copy` as this value is used across a yield
   --> $DIR/clone-impl.rs:38:9
@@ -34,9 +34,6 @@ LL |         let v = vec!['a'];
    |             - has type `Vec<char>` which does not implement `Copy`
 LL |         yield;
    |         ^^^^^ yield occurs here, with `v` maybe used later
-...
-LL |     };
-   |     - `v` is later dropped here
 note: required by a bound in `check_copy`
   --> $DIR/clone-impl.rs:72:18
    |
@@ -44,13 +41,13 @@ LL | fn check_copy<T: Copy>(_x: &T) {}
    |                  ^^^^ required by this bound in `check_copy`
 
 error[E0277]: the trait bound `Vec<u32>: Copy` is not satisfied in `{generator@$DIR/clone-impl.rs:46:23: 46:30}`
-  --> $DIR/clone-impl.rs:58:16
+  --> $DIR/clone-impl.rs:58:5
    |
 LL |     let gen_clone_1 = move || {
    |                       ------- within this `{generator@$DIR/clone-impl.rs:46:23: 46:30}`
 ...
 LL |     check_copy(&gen_clone_1);
-   |                ^^^^^^^^^^^^ within `{generator@$DIR/clone-impl.rs:46:23: 46:30}`, the trait `Copy` is not implemented for `Vec<u32>`
+   |     ^^^^^^^^^^ within `{generator@$DIR/clone-impl.rs:46:23: 46:30}`, the trait `Copy` is not implemented for `Vec<u32>`
    |
 note: captured value does not implement `Copy`
   --> $DIR/clone-impl.rs:56:14
@@ -64,13 +61,13 @@ LL | fn check_copy<T: Copy>(_x: &T) {}
    |                  ^^^^ required by this bound in `check_copy`
 
 error[E0277]: the trait bound `Vec<char>: Copy` is not satisfied in `{generator@$DIR/clone-impl.rs:46:23: 46:30}`
-  --> $DIR/clone-impl.rs:58:16
+  --> $DIR/clone-impl.rs:58:5
    |
 LL |     let gen_clone_1 = move || {
    |                       ------- within this `{generator@$DIR/clone-impl.rs:46:23: 46:30}`
 ...
 LL |     check_copy(&gen_clone_1);
-   |                ^^^^^^^^^^^^ within `{generator@$DIR/clone-impl.rs:46:23: 46:30}`, the trait `Copy` is not implemented for `Vec<char>`
+   |     ^^^^^^^^^^ within `{generator@$DIR/clone-impl.rs:46:23: 46:30}`, the trait `Copy` is not implemented for `Vec<char>`
    |
 note: generator does not implement `Copy` as this value is used across a yield
   --> $DIR/clone-impl.rs:52:9
@@ -80,9 +77,6 @@ LL |         let v = vec!['a'];
 ...
 LL |         yield;
    |         ^^^^^ yield occurs here, with `v` maybe used later
-...
-LL |     };
-   |     - `v` is later dropped here
 note: required by a bound in `check_copy`
   --> $DIR/clone-impl.rs:72:18
    |
@@ -90,13 +84,13 @@ LL | fn check_copy<T: Copy>(_x: &T) {}
    |                  ^^^^ required by this bound in `check_copy`
 
 error[E0277]: the trait bound `NonClone: Copy` is not satisfied in `{generator@$DIR/clone-impl.rs:62:25: 62:32}`
-  --> $DIR/clone-impl.rs:66:16
+  --> $DIR/clone-impl.rs:66:5
    |
 LL |     let gen_non_clone = move || {
    |                         ------- within this `{generator@$DIR/clone-impl.rs:62:25: 62:32}`
 ...
 LL |     check_copy(&gen_non_clone);
-   |                ^^^^^^^^^^^^^^ within `{generator@$DIR/clone-impl.rs:62:25: 62:32}`, the trait `Copy` is not implemented for `NonClone`
+   |     ^^^^^^^^^^ within `{generator@$DIR/clone-impl.rs:62:25: 62:32}`, the trait `Copy` is not implemented for `NonClone`
    |
 note: captured value does not implement `Copy`
   --> $DIR/clone-impl.rs:64:14
@@ -115,13 +109,13 @@ LL | struct NonClone;
    |
 
 error[E0277]: the trait bound `NonClone: Clone` is not satisfied in `{generator@$DIR/clone-impl.rs:62:25: 62:32}`
-  --> $DIR/clone-impl.rs:68:17
+  --> $DIR/clone-impl.rs:68:5
    |
 LL |     let gen_non_clone = move || {
    |                         ------- within this `{generator@$DIR/clone-impl.rs:62:25: 62:32}`
 ...
 LL |     check_clone(&gen_non_clone);
-   |                 ^^^^^^^^^^^^^^ within `{generator@$DIR/clone-impl.rs:62:25: 62:32}`, the trait `Clone` is not implemented for `NonClone`
+   |     ^^^^^^^^^^^ within `{generator@$DIR/clone-impl.rs:62:25: 62:32}`, the trait `Clone` is not implemented for `NonClone`
    |
 note: captured value does not implement `Clone`
   --> $DIR/clone-impl.rs:64:14
diff --git a/tests/ui/generator/derived-drop-parent-expr.rs b/tests/ui/generator/derived-drop-parent-expr.rs
index 4bd34346a18..e381924517d 100644
--- a/tests/ui/generator/derived-drop-parent-expr.rs
+++ b/tests/ui/generator/derived-drop-parent-expr.rs
@@ -1,5 +1,4 @@
 // build-pass
-// compile-flags:-Zdrop-tracking
 
 //! Like drop-tracking-parent-expression, but also tests that this doesn't ICE when building MIR
 #![feature(generators)]
diff --git a/tests/ui/generator/drop-control-flow.rs b/tests/ui/generator/drop-control-flow.rs
index c6efda9541f..1c25c06ba4c 100644
--- a/tests/ui/generator/drop-control-flow.rs
+++ b/tests/ui/generator/drop-control-flow.rs
@@ -1,5 +1,4 @@
 // build-pass
-// compile-flags: -Zdrop-tracking
 
 // A test to ensure generators capture values that were conditionally dropped,
 // and also that values that are dropped along all paths to a yield do not get
diff --git a/tests/ui/generator/drop-track-addassign-yield.rs b/tests/ui/generator/drop-track-addassign-yield.rs
index 71cfb170bf6..1e64f1d2ec7 100644
--- a/tests/ui/generator/drop-track-addassign-yield.rs
+++ b/tests/ui/generator/drop-track-addassign-yield.rs
@@ -1,5 +1,4 @@
 // run-pass
-// compile-flags: -Zdrop-tracking
 
 // Based on addassign-yield.rs, but with drop tracking enabled. Originally we did not implement
 // the fake_read callback on ExprUseVisitor which caused this case to break.
diff --git a/tests/ui/generator/drop-tracking-error-body.rs b/tests/ui/generator/drop-tracking-error-body.rs
deleted file mode 100644
index f99d9ab6bf8..00000000000
--- a/tests/ui/generator/drop-tracking-error-body.rs
+++ /dev/null
@@ -1,18 +0,0 @@
-// compile-flags: -Zdrop-tracking-mir --edition=2021
-
-#![feature(generators)]
-
-pub async fn async_bad_body() {
-    match true {} //~ ERROR non-exhaustive patterns: type `bool` is non-empty
-}
-
-pub fn generator_bad_body() {
-    || {
-        // 'non-exhaustive pattern' only seems to be reported once, so this annotation doesn't work
-        // keep the function around so we can make sure it doesn't ICE
-        match true {}; // ERROR non-exhaustive patterns: type `bool` is non-empty
-        yield ();
-    };
-}
-
-fn main() {}
diff --git a/tests/ui/generator/drop-tracking-error-body.stderr b/tests/ui/generator/drop-tracking-error-body.stderr
deleted file mode 100644
index 28a6892336f..00000000000
--- a/tests/ui/generator/drop-tracking-error-body.stderr
+++ /dev/null
@@ -1,17 +0,0 @@
-error[E0004]: non-exhaustive patterns: type `bool` is non-empty
-  --> $DIR/drop-tracking-error-body.rs:6:11
-   |
-LL |     match true {}
-   |           ^^^^
-   |
-   = note: the matched value is of type `bool`
-help: ensure that all possible cases are being handled by adding a match arm with a wildcard pattern as shown
-   |
-LL ~     match true {
-LL +         _ => todo!(),
-LL ~     }
-   |
-
-error: aborting due to previous error
-
-For more information about this error, try `rustc --explain E0004`.
diff --git a/tests/ui/generator/drop-tracking-parent-expression.rs b/tests/ui/generator/drop-tracking-parent-expression.rs
index d40f1b8f64d..198b14528aa 100644
--- a/tests/ui/generator/drop-tracking-parent-expression.rs
+++ b/tests/ui/generator/drop-tracking-parent-expression.rs
@@ -1,4 +1,3 @@
-// compile-flags: -Zdrop-tracking
 #![feature(generators, negative_impls, rustc_attrs)]
 
 macro_rules! type_combinations {
diff --git a/tests/ui/generator/drop-tracking-parent-expression.stderr b/tests/ui/generator/drop-tracking-parent-expression.stderr
index 6119f689731..e85bb1347a7 100644
--- a/tests/ui/generator/drop-tracking-parent-expression.stderr
+++ b/tests/ui/generator/drop-tracking-parent-expression.stderr
@@ -1,8 +1,8 @@
 error: generator cannot be sent between threads safely
-  --> $DIR/drop-tracking-parent-expression.rs:24:25
+  --> $DIR/drop-tracking-parent-expression.rs:23:13
    |
 LL |               assert_send(g);
-   |                           ^ generator is not `Send`
+   |               ^^^^^^^^^^^ generator is not `Send`
 ...
 LL | /     type_combinations!(
 LL | |         // OK
@@ -13,17 +13,15 @@ LL | |         };
 LL | |     );
    | |_____- in this macro invocation
    |
-   = help: within `{generator@$DIR/drop-tracking-parent-expression.rs:18:21: 18:28}`, the trait `Send` is not implemented for `derived_drop::Client`
+   = help: within `{generator@$DIR/drop-tracking-parent-expression.rs:17:21: 17:28}`, the trait `Send` is not implemented for `derived_drop::Client`
 note: generator is not `Send` as this value is used across a yield
-  --> $DIR/drop-tracking-parent-expression.rs:22:22
+  --> $DIR/drop-tracking-parent-expression.rs:21:22
    |
 LL |               let g = move || match drop($name::Client { ..$name::Client::default() }) {
    |                                                            ------------------------ has type `derived_drop::Client` which is not `Send`
 ...
 LL |                   _ => yield,
    |                        ^^^^^ yield occurs here, with `$name::Client::default()` maybe used later
-LL |               };
-   |               - `$name::Client::default()` is later dropped here
 ...
 LL | /     type_combinations!(
 LL | |         // OK
@@ -34,17 +32,17 @@ LL | |         };
 LL | |     );
    | |_____- in this macro invocation
 note: required by a bound in `assert_send`
-  --> $DIR/drop-tracking-parent-expression.rs:41:19
+  --> $DIR/drop-tracking-parent-expression.rs:40:19
    |
 LL | fn assert_send<T: Send>(_thing: T) {}
    |                   ^^^^ required by this bound in `assert_send`
    = note: this error originates in the macro `type_combinations` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: generator cannot be sent between threads safely
-  --> $DIR/drop-tracking-parent-expression.rs:24:25
+  --> $DIR/drop-tracking-parent-expression.rs:23:13
    |
 LL |               assert_send(g);
-   |                           ^ generator is not `Send`
+   |               ^^^^^^^^^^^ generator is not `Send`
 ...
 LL | /     type_combinations!(
 LL | |         // OK
@@ -55,17 +53,15 @@ LL | |         };
 LL | |     );
    | |_____- in this macro invocation
    |
-   = help: within `{generator@$DIR/drop-tracking-parent-expression.rs:18:21: 18:28}`, the trait `Send` is not implemented for `significant_drop::Client`
+   = help: within `{generator@$DIR/drop-tracking-parent-expression.rs:17:21: 17:28}`, the trait `Send` is not implemented for `significant_drop::Client`
 note: generator is not `Send` as this value is used across a yield
-  --> $DIR/drop-tracking-parent-expression.rs:22:22
+  --> $DIR/drop-tracking-parent-expression.rs:21:22
    |
 LL |               let g = move || match drop($name::Client { ..$name::Client::default() }) {
    |                                                            ------------------------ has type `significant_drop::Client` which is not `Send`
 ...
 LL |                   _ => yield,
    |                        ^^^^^ yield occurs here, with `$name::Client::default()` maybe used later
-LL |               };
-   |               - `$name::Client::default()` is later dropped here
 ...
 LL | /     type_combinations!(
 LL | |         // OK
@@ -76,17 +72,17 @@ LL | |         };
 LL | |     );
    | |_____- in this macro invocation
 note: required by a bound in `assert_send`
-  --> $DIR/drop-tracking-parent-expression.rs:41:19
+  --> $DIR/drop-tracking-parent-expression.rs:40:19
    |
 LL | fn assert_send<T: Send>(_thing: T) {}
    |                   ^^^^ required by this bound in `assert_send`
    = note: this error originates in the macro `type_combinations` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: generator cannot be sent between threads safely
-  --> $DIR/drop-tracking-parent-expression.rs:24:25
+  --> $DIR/drop-tracking-parent-expression.rs:23:13
    |
 LL |               assert_send(g);
-   |                           ^ generator is not `Send`
+   |               ^^^^^^^^^^^ generator is not `Send`
 ...
 LL | /     type_combinations!(
 LL | |         // OK
@@ -97,17 +93,15 @@ LL | |         };
 LL | |     );
    | |_____- in this macro invocation
    |
-   = help: within `{generator@$DIR/drop-tracking-parent-expression.rs:18:21: 18:28}`, the trait `Send` is not implemented for `insignificant_dtor::Client`
+   = help: within `{generator@$DIR/drop-tracking-parent-expression.rs:17:21: 17:28}`, the trait `Send` is not implemented for `insignificant_dtor::Client`
 note: generator is not `Send` as this value is used across a yield
-  --> $DIR/drop-tracking-parent-expression.rs:22:22
+  --> $DIR/drop-tracking-parent-expression.rs:21:22
    |
 LL |               let g = move || match drop($name::Client { ..$name::Client::default() }) {
    |                                                            ------------------------ has type `insignificant_dtor::Client` which is not `Send`
 ...
 LL |                   _ => yield,
    |                        ^^^^^ yield occurs here, with `$name::Client::default()` maybe used later
-LL |               };
-   |               - `$name::Client::default()` is later dropped here
 ...
 LL | /     type_combinations!(
 LL | |         // OK
@@ -118,7 +112,7 @@ LL | |         };
 LL | |     );
    | |_____- in this macro invocation
 note: required by a bound in `assert_send`
-  --> $DIR/drop-tracking-parent-expression.rs:41:19
+  --> $DIR/drop-tracking-parent-expression.rs:40:19
    |
 LL | fn assert_send<T: Send>(_thing: T) {}
    |                   ^^^^ required by this bound in `assert_send`
diff --git a/tests/ui/generator/drop-tracking-yielding-in-match-guards.rs b/tests/ui/generator/drop-tracking-yielding-in-match-guards.rs
index 646365e4359..92e0136d51b 100644
--- a/tests/ui/generator/drop-tracking-yielding-in-match-guards.rs
+++ b/tests/ui/generator/drop-tracking-yielding-in-match-guards.rs
@@ -1,6 +1,5 @@
 // build-pass
 // edition:2018
-// compile-flags: -Zdrop-tracking
 
 #![feature(generators)]
 
diff --git a/tests/ui/generator/drop-yield-twice.stderr b/tests/ui/generator/drop-yield-twice.stderr
index 6a28e463189..39a906f0bf4 100644
--- a/tests/ui/generator/drop-yield-twice.stderr
+++ b/tests/ui/generator/drop-yield-twice.stderr
@@ -1,14 +1,8 @@
 error: generator cannot be sent between threads safely
-  --> $DIR/drop-yield-twice.rs:7:17
+  --> $DIR/drop-yield-twice.rs:7:5
    |
-LL |       assert_send(|| {
-   |  _________________^
-LL | |         let guard = Foo(42);
-LL | |         yield;
-LL | |         drop(guard);
-LL | |         yield;
-LL | |     })
-   | |_____^ generator is not `Send`
+LL |     assert_send(|| {
+   |     ^^^^^^^^^^^ generator is not `Send`
    |
    = help: within `{generator@$DIR/drop-yield-twice.rs:7:17: 7:19}`, the trait `Send` is not implemented for `Foo`
 note: generator is not `Send` as this value is used across a yield
@@ -18,9 +12,6 @@ LL |         let guard = Foo(42);
    |             ----- has type `Foo` which is not `Send`
 LL |         yield;
    |         ^^^^^ yield occurs here, with `guard` maybe used later
-...
-LL |     })
-   |     - `guard` is later dropped here
 note: required by a bound in `assert_send`
   --> $DIR/drop-yield-twice.rs:15:19
    |
diff --git a/tests/ui/generator/issue-102645.rs b/tests/ui/generator/issue-102645.rs
index 35acd5cd727..677cc69d3f2 100644
--- a/tests/ui/generator/issue-102645.rs
+++ b/tests/ui/generator/issue-102645.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Zdrop-tracking
-
 #![feature(generators, generator_trait)]
 
 use std::ops::Generator;
diff --git a/tests/ui/generator/issue-102645.stderr b/tests/ui/generator/issue-102645.stderr
index 3f9a4c2f3c5..5d28dfc45b3 100644
--- a/tests/ui/generator/issue-102645.stderr
+++ b/tests/ui/generator/issue-102645.stderr
@@ -1,5 +1,5 @@
 error[E0061]: this method takes 1 argument but 0 arguments were supplied
-  --> $DIR/issue-102645.rs:16:22
+  --> $DIR/issue-102645.rs:14:22
    |
 LL |     Pin::new(&mut b).resume();
    |                      ^^^^^^-- an argument of type `()` is missing
diff --git a/tests/ui/generator/issue-105084.rs b/tests/ui/generator/issue-105084.rs
index 9fdeb4fd2fc..50b5da6e6ad 100644
--- a/tests/ui/generator/issue-105084.rs
+++ b/tests/ui/generator/issue-105084.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Zdrop-tracking-mir
-
 #![feature(generators)]
 #![feature(generator_clone)]
 #![feature(generator_trait)]
diff --git a/tests/ui/generator/issue-105084.stderr b/tests/ui/generator/issue-105084.stderr
index 3f1f11918f5..573c31f1134 100644
--- a/tests/ui/generator/issue-105084.stderr
+++ b/tests/ui/generator/issue-105084.stderr
@@ -1,8 +1,8 @@
 error[E0382]: borrow of moved value: `g`
-  --> $DIR/issue-105084.rs:39:14
+  --> $DIR/issue-105084.rs:37:14
    |
 LL |     let mut g = || {
-   |         ----- move occurs because `g` has type `{generator@$DIR/issue-105084.rs:16:17: 16:19}`, which does not implement the `Copy` trait
+   |         ----- move occurs because `g` has type `{generator@$DIR/issue-105084.rs:14:17: 14:19}`, which does not implement the `Copy` trait
 ...
 LL |     let mut h = copy(g);
    |                      - value moved here
@@ -11,7 +11,7 @@ LL |     Pin::new(&mut g).resume(());
    |              ^^^^^^ value borrowed here after move
    |
 note: consider changing this parameter type in function `copy` to borrow instead if owning the value isn't necessary
-  --> $DIR/issue-105084.rs:11:21
+  --> $DIR/issue-105084.rs:9:21
    |
 LL | fn copy<T: Copy>(x: T) -> T {
    |    ----             ^ this parameter takes ownership of the value
@@ -22,17 +22,17 @@ help: consider cloning the value if the performance cost is acceptable
 LL |     let mut h = copy(g.clone());
    |                       ++++++++
 
-error[E0277]: the trait bound `Box<(i32, ())>: Copy` is not satisfied in `{generator@$DIR/issue-105084.rs:16:17: 16:19}`
-  --> $DIR/issue-105084.rs:33:17
+error[E0277]: the trait bound `Box<(i32, ())>: Copy` is not satisfied in `{generator@$DIR/issue-105084.rs:14:17: 14:19}`
+  --> $DIR/issue-105084.rs:31:17
    |
 LL |     let mut g = || {
-   |                 -- within this `{generator@$DIR/issue-105084.rs:16:17: 16:19}`
+   |                 -- within this `{generator@$DIR/issue-105084.rs:14:17: 14:19}`
 ...
 LL |     let mut h = copy(g);
-   |                 ^^^^ within `{generator@$DIR/issue-105084.rs:16:17: 16:19}`, the trait `Copy` is not implemented for `Box<(i32, ())>`
+   |                 ^^^^ within `{generator@$DIR/issue-105084.rs:14:17: 14:19}`, the trait `Copy` is not implemented for `Box<(i32, ())>`
    |
 note: generator does not implement `Copy` as this value is used across a yield
-  --> $DIR/issue-105084.rs:23:22
+  --> $DIR/issue-105084.rs:21:22
    |
 LL |         Box::new((5, yield));
    |         -------------^^^^^--
@@ -40,7 +40,7 @@ LL |         Box::new((5, yield));
    |         |            yield occurs here, with `Box::new((5, yield))` maybe used later
    |         has type `Box<(i32, ())>` which does not implement `Copy`
 note: required by a bound in `copy`
-  --> $DIR/issue-105084.rs:11:12
+  --> $DIR/issue-105084.rs:9:12
    |
 LL | fn copy<T: Copy>(x: T) -> T {
    |            ^^^^ required by this bound in `copy`
diff --git a/tests/ui/generator/issue-110929-generator-conflict-error-ice.rs b/tests/ui/generator/issue-110929-generator-conflict-error-ice.rs
index 9408acc15f9..a45479e5300 100644
--- a/tests/ui/generator/issue-110929-generator-conflict-error-ice.rs
+++ b/tests/ui/generator/issue-110929-generator-conflict-error-ice.rs
@@ -1,5 +1,4 @@
 // edition:2021
-// compile-flags: -Zdrop-tracking-mir=yes
 #![feature(generators)]
 
 fn main() {
diff --git a/tests/ui/generator/issue-110929-generator-conflict-error-ice.stderr b/tests/ui/generator/issue-110929-generator-conflict-error-ice.stderr
index 4d72ebe79eb..66f0e3d94bd 100644
--- a/tests/ui/generator/issue-110929-generator-conflict-error-ice.stderr
+++ b/tests/ui/generator/issue-110929-generator-conflict-error-ice.stderr
@@ -1,5 +1,5 @@
 error[E0499]: cannot borrow `*x` as mutable more than once at a time
-  --> $DIR/issue-110929-generator-conflict-error-ice.rs:9:9
+  --> $DIR/issue-110929-generator-conflict-error-ice.rs:8:9
    |
 LL |         let _c = || yield *&mut *x;
    |                  --             -- first borrow occurs due to use of `*x` in generator
diff --git a/tests/ui/generator/issue-57017.rs b/tests/ui/generator/issue-57017.rs
index 6cb742b7ffe..bb2d6679b67 100644
--- a/tests/ui/generator/issue-57017.rs
+++ b/tests/ui/generator/issue-57017.rs
@@ -1,5 +1,4 @@
 // build-pass
-// compile-flags: -Zdrop-tracking
 #![feature(generators, negative_impls)]
 #![allow(dropping_references, dropping_copy_types)]
 
diff --git a/tests/ui/generator/issue-57478.rs b/tests/ui/generator/issue-57478.rs
index 91407ea1844..39710febdb9 100644
--- a/tests/ui/generator/issue-57478.rs
+++ b/tests/ui/generator/issue-57478.rs
@@ -1,5 +1,4 @@
 // check-pass
-// compile-flags: -Zdrop-tracking
 
 #![feature(negative_impls, generators)]
 
diff --git a/tests/ui/generator/issue-68112.rs b/tests/ui/generator/issue-68112.rs
index 9def544e3d2..9dd68726f92 100644
--- a/tests/ui/generator/issue-68112.rs
+++ b/tests/ui/generator/issue-68112.rs
@@ -8,7 +8,7 @@ use std::{
 };
 
 pub struct Ready<T>(Option<T>);
-impl<T> Generator<()> for Ready<T> {
+impl<T: Unpin> Generator<()> for Ready<T> {
     type Return = T;
     type Yield = ();
     fn resume(mut self: Pin<&mut Self>, _args: ()) -> GeneratorState<(), T> {
@@ -36,7 +36,7 @@ fn test1() {
         yield;
         //~^ NOTE yield occurs here
         //~| NOTE value is used across a yield
-    }; //~ NOTE later dropped here
+    };
     require_send(send_gen);
     //~^ ERROR generator cannot be sent between threads
     //~| NOTE not `Send`
@@ -65,7 +65,6 @@ fn test2() {
     //~^ ERROR `RefCell<i32>` cannot be shared between threads safely
     //~| NOTE `RefCell<i32>` cannot be shared between threads safely
     //~| NOTE required for
-    //~| NOTE required by a bound introduced by this call
     //~| NOTE captures the following types
     //~| NOTE use `std::sync::RwLock` instead
 }
diff --git a/tests/ui/generator/issue-68112.stderr b/tests/ui/generator/issue-68112.stderr
index b42bc93d01f..8080048222f 100644
--- a/tests/ui/generator/issue-68112.stderr
+++ b/tests/ui/generator/issue-68112.stderr
@@ -1,8 +1,8 @@
 error: generator cannot be sent between threads safely
-  --> $DIR/issue-68112.rs:40:18
+  --> $DIR/issue-68112.rs:40:5
    |
 LL |     require_send(send_gen);
-   |                  ^^^^^^^^ generator is not `Send`
+   |     ^^^^^^^^^^^^ generator is not `Send`
    |
    = help: the trait `Sync` is not implemented for `RefCell<i32>`
    = note: if you want to do aliasing and mutation between multiple threads, use `std::sync::RwLock` instead
@@ -14,9 +14,6 @@ LL |         let _non_send_gen = make_non_send_generator();
 LL |
 LL |         yield;
    |         ^^^^^ yield occurs here, with `_non_send_gen` maybe used later
-...
-LL |     };
-   |     - `_non_send_gen` is later dropped here
 note: required by a bound in `require_send`
   --> $DIR/issue-68112.rs:22:25
    |
@@ -24,12 +21,10 @@ LL | fn require_send(_: impl Send) {}
    |                         ^^^^ required by this bound in `require_send`
 
 error[E0277]: `RefCell<i32>` cannot be shared between threads safely
-  --> $DIR/issue-68112.rs:64:18
+  --> $DIR/issue-68112.rs:64:5
    |
 LL |     require_send(send_gen);
-   |     ------------ ^^^^^^^^ `RefCell<i32>` cannot be shared between threads safely
-   |     |
-   |     required by a bound introduced by this call
+   |     ^^^^^^^^^^^^ `RefCell<i32>` cannot be shared between threads safely
    |
    = help: the trait `Sync` is not implemented for `RefCell<i32>`
    = note: if you want to do aliasing and mutation between multiple threads, use `std::sync::RwLock` instead
@@ -49,7 +44,7 @@ note: required because it appears within the type `impl Generator<Return = Arc<R
    |
 LL | fn make_non_send_generator2() -> impl Generator<Return = Arc<RefCell<i32>>> {
    |                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   = note: required because it captures the following types: `impl Generator<Return = Arc<RefCell<i32>>>`, `()`
+   = note: required because it captures the following types: `impl Generator<Return = Arc<RefCell<i32>>>`
 note: required because it's used within this generator
   --> $DIR/issue-68112.rs:60:20
    |
diff --git a/tests/ui/generator/issue-93161.rs b/tests/ui/generator/issue-93161.rs
index 92305609c83..ae8603b7c09 100644
--- a/tests/ui/generator/issue-93161.rs
+++ b/tests/ui/generator/issue-93161.rs
@@ -1,6 +1,5 @@
 // edition:2021
 // run-pass
-// compile-flags: -Zdrop-tracking
 
 #![feature(never_type)]
 
diff --git a/tests/ui/generator/not-send-sync.rs b/tests/ui/generator/not-send-sync.rs
index 8ca5565fb2a..16c8cd47629 100644
--- a/tests/ui/generator/not-send-sync.rs
+++ b/tests/ui/generator/not-send-sync.rs
@@ -1,6 +1,11 @@
 #![feature(generators)]
+#![feature(negative_impls)]
 
-use std::cell::Cell;
+struct NotSend;
+struct NotSync;
+
+impl !Send for NotSend {}
+impl !Sync for NotSync {}
 
 fn main() {
     fn assert_sync<T: Sync>(_: T) {}
@@ -8,14 +13,15 @@ fn main() {
 
     assert_sync(|| {
         //~^ ERROR: generator cannot be shared between threads safely
-        let a = Cell::new(2);
+        let a = NotSync;
         yield;
+        drop(a);
     });
 
-    let a = Cell::new(2);
     assert_send(|| {
-        //~^ ERROR: E0277
-        drop(&a);
+        //~^ ERROR: generator cannot be sent between threads safely
+        let a = NotSend;
         yield;
+        drop(a);
     });
 }
diff --git a/tests/ui/generator/not-send-sync.stderr b/tests/ui/generator/not-send-sync.stderr
index 6e0269026b5..13ce687e0bb 100644
--- a/tests/ui/generator/not-send-sync.stderr
+++ b/tests/ui/generator/not-send-sync.stderr
@@ -1,58 +1,42 @@
-error[E0277]: `Cell<i32>` cannot be shared between threads safely
-  --> $DIR/not-send-sync.rs:16:17
-   |
-LL |       assert_send(|| {
-   |  _____-----------_^
-   | |     |
-   | |     required by a bound introduced by this call
-LL | |
-LL | |         drop(&a);
-LL | |         yield;
-LL | |     });
-   | |_____^ `Cell<i32>` cannot be shared between threads safely
-   |
-   = help: the trait `Sync` is not implemented for `Cell<i32>`
-   = note: if you want to do aliasing and mutation between multiple threads, use `std::sync::RwLock` or `std::sync::atomic::AtomicI32` instead
-   = note: required for `&Cell<i32>` to implement `Send`
-note: required because it's used within this generator
-  --> $DIR/not-send-sync.rs:16:17
+error: generator cannot be shared between threads safely
+  --> $DIR/not-send-sync.rs:14:5
    |
-LL |     assert_send(|| {
-   |                 ^^
-note: required by a bound in `assert_send`
-  --> $DIR/not-send-sync.rs:7:23
+LL |     assert_sync(|| {
+   |     ^^^^^^^^^^^ generator is not `Sync`
    |
-LL |     fn assert_send<T: Send>(_: T) {}
-   |                       ^^^^ required by this bound in `assert_send`
-
-error: generator cannot be shared between threads safely
-  --> $DIR/not-send-sync.rs:9:17
-   |
-LL |       assert_sync(|| {
-   |  _________________^
-LL | |
-LL | |         let a = Cell::new(2);
-LL | |         yield;
-LL | |     });
-   | |_____^ generator is not `Sync`
-   |
-   = help: within `{generator@$DIR/not-send-sync.rs:9:17: 9:19}`, the trait `Sync` is not implemented for `Cell<i32>`
-   = note: if you want to do aliasing and mutation between multiple threads, use `std::sync::RwLock` or `std::sync::atomic::AtomicI32` instead
+   = help: within `{generator@$DIR/not-send-sync.rs:14:17: 14:19}`, the trait `Sync` is not implemented for `NotSync`
 note: generator is not `Sync` as this value is used across a yield
-  --> $DIR/not-send-sync.rs:12:9
+  --> $DIR/not-send-sync.rs:17:9
    |
-LL |         let a = Cell::new(2);
-   |             - has type `Cell<i32>` which is not `Sync`
+LL |         let a = NotSync;
+   |             - has type `NotSync` which is not `Sync`
 LL |         yield;
    |         ^^^^^ yield occurs here, with `a` maybe used later
-LL |     });
-   |     - `a` is later dropped here
 note: required by a bound in `assert_sync`
-  --> $DIR/not-send-sync.rs:6:23
+  --> $DIR/not-send-sync.rs:11:23
    |
 LL |     fn assert_sync<T: Sync>(_: T) {}
    |                       ^^^^ required by this bound in `assert_sync`
 
+error: generator cannot be sent between threads safely
+  --> $DIR/not-send-sync.rs:21:5
+   |
+LL |     assert_send(|| {
+   |     ^^^^^^^^^^^ generator is not `Send`
+   |
+   = help: within `{generator@$DIR/not-send-sync.rs:21:17: 21:19}`, the trait `Send` is not implemented for `NotSend`
+note: generator is not `Send` as this value is used across a yield
+  --> $DIR/not-send-sync.rs:24:9
+   |
+LL |         let a = NotSend;
+   |             - has type `NotSend` which is not `Send`
+LL |         yield;
+   |         ^^^^^ yield occurs here, with `a` maybe used later
+note: required by a bound in `assert_send`
+  --> $DIR/not-send-sync.rs:12:23
+   |
+LL |     fn assert_send<T: Send>(_: T) {}
+   |                       ^^^^ required by this bound in `assert_send`
+
 error: aborting due to 2 previous errors
 
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/generator/parent-expression.rs b/tests/ui/generator/parent-expression.rs
index 47a179c14ad..198b14528aa 100644
--- a/tests/ui/generator/parent-expression.rs
+++ b/tests/ui/generator/parent-expression.rs
@@ -1,5 +1,3 @@
-// compile-flags: -Zdrop-tracking
-
 #![feature(generators, negative_impls, rustc_attrs)]
 
 macro_rules! type_combinations {
diff --git a/tests/ui/generator/parent-expression.stderr b/tests/ui/generator/parent-expression.stderr
index 5fb54abeb2d..25a3b051b1f 100644
--- a/tests/ui/generator/parent-expression.stderr
+++ b/tests/ui/generator/parent-expression.stderr
@@ -1,8 +1,8 @@
 error: generator cannot be sent between threads safely
-  --> $DIR/parent-expression.rs:25:25
+  --> $DIR/parent-expression.rs:23:13
    |
 LL |               assert_send(g);
-   |                           ^ generator is not `Send`
+   |               ^^^^^^^^^^^ generator is not `Send`
 ...
 LL | /     type_combinations!(
 LL | |         // OK
@@ -13,17 +13,15 @@ LL | |         };
 LL | |     );
    | |_____- in this macro invocation
    |
-   = help: within `{generator@$DIR/parent-expression.rs:19:21: 19:28}`, the trait `Send` is not implemented for `derived_drop::Client`
+   = help: within `{generator@$DIR/parent-expression.rs:17:21: 17:28}`, the trait `Send` is not implemented for `derived_drop::Client`
 note: generator is not `Send` as this value is used across a yield
-  --> $DIR/parent-expression.rs:23:22
+  --> $DIR/parent-expression.rs:21:22
    |
 LL |               let g = move || match drop($name::Client { ..$name::Client::default() }) {
    |                                                            ------------------------ has type `derived_drop::Client` which is not `Send`
 ...
 LL |                   _ => yield,
    |                        ^^^^^ yield occurs here, with `$name::Client::default()` maybe used later
-LL |               };
-   |               - `$name::Client::default()` is later dropped here
 ...
 LL | /     type_combinations!(
 LL | |         // OK
@@ -34,17 +32,17 @@ LL | |         };
 LL | |     );
    | |_____- in this macro invocation
 note: required by a bound in `assert_send`
-  --> $DIR/parent-expression.rs:42:19
+  --> $DIR/parent-expression.rs:40:19
    |
 LL | fn assert_send<T: Send>(_thing: T) {}
    |                   ^^^^ required by this bound in `assert_send`
    = note: this error originates in the macro `type_combinations` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: generator cannot be sent between threads safely
-  --> $DIR/parent-expression.rs:25:25
+  --> $DIR/parent-expression.rs:23:13
    |
 LL |               assert_send(g);
-   |                           ^ generator is not `Send`
+   |               ^^^^^^^^^^^ generator is not `Send`
 ...
 LL | /     type_combinations!(
 LL | |         // OK
@@ -55,17 +53,15 @@ LL | |         };
 LL | |     );
    | |_____- in this macro invocation
    |
-   = help: within `{generator@$DIR/parent-expression.rs:19:21: 19:28}`, the trait `Send` is not implemented for `significant_drop::Client`
+   = help: within `{generator@$DIR/parent-expression.rs:17:21: 17:28}`, the trait `Send` is not implemented for `significant_drop::Client`
 note: generator is not `Send` as this value is used across a yield
-  --> $DIR/parent-expression.rs:23:22
+  --> $DIR/parent-expression.rs:21:22
    |
 LL |               let g = move || match drop($name::Client { ..$name::Client::default() }) {
    |                                                            ------------------------ has type `significant_drop::Client` which is not `Send`
 ...
 LL |                   _ => yield,
    |                        ^^^^^ yield occurs here, with `$name::Client::default()` maybe used later
-LL |               };
-   |               - `$name::Client::default()` is later dropped here
 ...
 LL | /     type_combinations!(
 LL | |         // OK
@@ -76,17 +72,17 @@ LL | |         };
 LL | |     );
    | |_____- in this macro invocation
 note: required by a bound in `assert_send`
-  --> $DIR/parent-expression.rs:42:19
+  --> $DIR/parent-expression.rs:40:19
    |
 LL | fn assert_send<T: Send>(_thing: T) {}
    |                   ^^^^ required by this bound in `assert_send`
    = note: this error originates in the macro `type_combinations` (in Nightly builds, run with -Z macro-backtrace for more info)
 
 error: generator cannot be sent between threads safely
-  --> $DIR/parent-expression.rs:25:25
+  --> $DIR/parent-expression.rs:23:13
    |
 LL |               assert_send(g);
-   |                           ^ generator is not `Send`
+   |               ^^^^^^^^^^^ generator is not `Send`
 ...
 LL | /     type_combinations!(
 LL | |         // OK
@@ -97,17 +93,15 @@ LL | |         };
 LL | |     );
    | |_____- in this macro invocation
    |
-   = help: within `{generator@$DIR/parent-expression.rs:19:21: 19:28}`, the trait `Send` is not implemented for `insignificant_dtor::Client`
+   = help: within `{generator@$DIR/parent-expression.rs:17:21: 17:28}`, the trait `Send` is not implemented for `insignificant_dtor::Client`
 note: generator is not `Send` as this value is used across a yield
-  --> $DIR/parent-expression.rs:23:22
+  --> $DIR/parent-expression.rs:21:22
    |
 LL |               let g = move || match drop($name::Client { ..$name::Client::default() }) {
    |                                                            ------------------------ has type `insignificant_dtor::Client` which is not `Send`
 ...
 LL |                   _ => yield,
    |                        ^^^^^ yield occurs here, with `$name::Client::default()` maybe used later
-LL |               };
-   |               - `$name::Client::default()` is later dropped here
 ...
 LL | /     type_combinations!(
 LL | |         // OK
@@ -118,7 +112,7 @@ LL | |         };
 LL | |     );
    | |_____- in this macro invocation
 note: required by a bound in `assert_send`
-  --> $DIR/parent-expression.rs:42:19
+  --> $DIR/parent-expression.rs:40:19
    |
 LL | fn assert_send<T: Send>(_thing: T) {}
    |                   ^^^^ required by this bound in `assert_send`
diff --git a/tests/ui/generator/partial-drop.rs b/tests/ui/generator/partial-drop.rs
index c872fb7f3e6..868f36adce2 100644
--- a/tests/ui/generator/partial-drop.rs
+++ b/tests/ui/generator/partial-drop.rs
@@ -1,5 +1,4 @@
-// compile-flags: -Zdrop-tracking
-
+// check-pass
 #![feature(negative_impls, generators)]
 
 struct Foo;
@@ -12,26 +11,19 @@ struct Bar {
 
 fn main() {
     assert_send(|| {
-        //~^ ERROR generator cannot be sent between threads safely
-        // FIXME: it would be nice to make this work.
         let guard = Bar { foo: Foo, x: 42 };
         drop(guard.foo);
         yield;
     });
 
     assert_send(|| {
-        //~^ ERROR generator cannot be sent between threads safely
-        // FIXME: it would be nice to make this work.
-        let guard = Bar { foo: Foo, x: 42 };
+        let mut guard = Bar { foo: Foo, x: 42 };
         drop(guard);
-        guard.foo = Foo;
-        guard.x = 23;
+        guard = Bar { foo: Foo, x: 23 };
         yield;
     });
 
     assert_send(|| {
-        //~^ ERROR generator cannot be sent between threads safely
-        // FIXME: it would be nice to make this work.
         let guard = Bar { foo: Foo, x: 42 };
         let Bar { foo, x } = guard;
         drop(foo);
diff --git a/tests/ui/generator/partial-drop.stderr b/tests/ui/generator/partial-drop.stderr
deleted file mode 100644
index f374b549df3..00000000000
--- a/tests/ui/generator/partial-drop.stderr
+++ /dev/null
@@ -1,92 +0,0 @@
-error: generator cannot be sent between threads safely
-  --> $DIR/partial-drop.rs:14:17
-   |
-LL |       assert_send(|| {
-   |  _________________^
-LL | |
-LL | |         // FIXME: it would be nice to make this work.
-LL | |         let guard = Bar { foo: Foo, x: 42 };
-LL | |         drop(guard.foo);
-LL | |         yield;
-LL | |     });
-   | |_____^ generator is not `Send`
-   |
-   = help: within `{generator@$DIR/partial-drop.rs:14:17: 14:19}`, the trait `Send` is not implemented for `Foo`
-note: generator is not `Send` as this value is used across a yield
-  --> $DIR/partial-drop.rs:19:9
-   |
-LL |         let guard = Bar { foo: Foo, x: 42 };
-   |             ----- has type `Bar` which is not `Send`
-LL |         drop(guard.foo);
-LL |         yield;
-   |         ^^^^^ yield occurs here, with `guard` maybe used later
-LL |     });
-   |     - `guard` is later dropped here
-note: required by a bound in `assert_send`
-  --> $DIR/partial-drop.rs:42:19
-   |
-LL | fn assert_send<T: Send>(_: T) {}
-   |                   ^^^^ required by this bound in `assert_send`
-
-error: generator cannot be sent between threads safely
-  --> $DIR/partial-drop.rs:22:17
-   |
-LL |       assert_send(|| {
-   |  _________________^
-LL | |
-LL | |         // FIXME: it would be nice to make this work.
-LL | |         let guard = Bar { foo: Foo, x: 42 };
-...  |
-LL | |         yield;
-LL | |     });
-   | |_____^ generator is not `Send`
-   |
-   = help: within `{generator@$DIR/partial-drop.rs:22:17: 22:19}`, the trait `Send` is not implemented for `Foo`
-note: generator is not `Send` as this value is used across a yield
-  --> $DIR/partial-drop.rs:29:9
-   |
-LL |         let guard = Bar { foo: Foo, x: 42 };
-   |             ----- has type `Bar` which is not `Send`
-...
-LL |         yield;
-   |         ^^^^^ yield occurs here, with `guard` maybe used later
-LL |     });
-   |     - `guard` is later dropped here
-note: required by a bound in `assert_send`
-  --> $DIR/partial-drop.rs:42:19
-   |
-LL | fn assert_send<T: Send>(_: T) {}
-   |                   ^^^^ required by this bound in `assert_send`
-
-error: generator cannot be sent between threads safely
-  --> $DIR/partial-drop.rs:32:17
-   |
-LL |       assert_send(|| {
-   |  _________________^
-LL | |
-LL | |         // FIXME: it would be nice to make this work.
-LL | |         let guard = Bar { foo: Foo, x: 42 };
-...  |
-LL | |         yield;
-LL | |     });
-   | |_____^ generator is not `Send`
-   |
-   = help: within `{generator@$DIR/partial-drop.rs:32:17: 32:19}`, the trait `Send` is not implemented for `Foo`
-note: generator is not `Send` as this value is used across a yield
-  --> $DIR/partial-drop.rs:38:9
-   |
-LL |         let guard = Bar { foo: Foo, x: 42 };
-   |             ----- has type `Bar` which is not `Send`
-...
-LL |         yield;
-   |         ^^^^^ yield occurs here, with `guard` maybe used later
-LL |     });
-   |     - `guard` is later dropped here
-note: required by a bound in `assert_send`
-  --> $DIR/partial-drop.rs:42:19
-   |
-LL | fn assert_send<T: Send>(_: T) {}
-   |                   ^^^^ required by this bound in `assert_send`
-
-error: aborting due to 3 previous errors
-
diff --git a/tests/ui/generator/print/generator-print-verbose-1.rs b/tests/ui/generator/print/generator-print-verbose-1.rs
index 89124ad7289..e52234c08a3 100644
--- a/tests/ui/generator/print/generator-print-verbose-1.rs
+++ b/tests/ui/generator/print/generator-print-verbose-1.rs
@@ -12,7 +12,7 @@ use std::{
 };
 
 pub struct Ready<T>(Option<T>);
-impl<T> Generator<()> for Ready<T> {
+impl<T: Unpin> Generator<()> for Ready<T> {
     type Return = T;
     type Yield = ();
     fn resume(mut self: Pin<&mut Self>, _args: ()) -> GeneratorState<(), T> {
diff --git a/tests/ui/generator/print/generator-print-verbose-1.stderr b/tests/ui/generator/print/generator-print-verbose-1.stderr
index 1e409534c75..d949543de41 100644
--- a/tests/ui/generator/print/generator-print-verbose-1.stderr
+++ b/tests/ui/generator/print/generator-print-verbose-1.stderr
@@ -1,8 +1,8 @@
 error: generator cannot be sent between threads safely
-  --> $DIR/generator-print-verbose-1.rs:37:18
+  --> $DIR/generator-print-verbose-1.rs:37:5
    |
 LL |     require_send(send_gen);
-   |                  ^^^^^^^^ generator is not `Send`
+   |     ^^^^^^^^^^^^ generator is not `Send`
    |
    = help: the trait `Sync` is not implemented for `RefCell<i32>`
    = note: if you want to do aliasing and mutation between multiple threads, use `std::sync::RwLock` instead
@@ -13,8 +13,6 @@ LL |         let _non_send_gen = make_non_send_generator();
    |             ------------- has type `Opaque(DefId(0:34 ~ generator_print_verbose_1[7d1d]::make_non_send_generator::{opaque#0}), [])` which is not `Send`
 LL |         yield;
    |         ^^^^^ yield occurs here, with `_non_send_gen` maybe used later
-LL |     };
-   |     - `_non_send_gen` is later dropped here
 note: required by a bound in `require_send`
   --> $DIR/generator-print-verbose-1.rs:26:25
    |
@@ -22,12 +20,10 @@ LL | fn require_send(_: impl Send) {}
    |                         ^^^^ required by this bound in `require_send`
 
 error[E0277]: `RefCell<i32>` cannot be shared between threads safely
-  --> $DIR/generator-print-verbose-1.rs:56:18
+  --> $DIR/generator-print-verbose-1.rs:56:5
    |
 LL |     require_send(send_gen);
-   |     ------------ ^^^^^^^^ `RefCell<i32>` cannot be shared between threads safely
-   |     |
-   |     required by a bound introduced by this call
+   |     ^^^^^^^^^^^^ `RefCell<i32>` cannot be shared between threads safely
    |
    = help: the trait `Sync` is not implemented for `RefCell<i32>`
    = note: if you want to do aliasing and mutation between multiple threads, use `std::sync::RwLock` instead
@@ -47,7 +43,7 @@ note: required because it appears within the type `Opaque(DefId(0:36 ~ generator
    |
 LL | fn make_non_send_generator2() -> impl Generator<Return = Arc<RefCell<i32>>> {
    |                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
-   = note: required because it captures the following types: `Opaque(DefId(0:36 ~ generator_print_verbose_1[7d1d]::make_non_send_generator2::{opaque#0}), [])`, `()`
+   = note: required because it captures the following types: `Opaque(DefId(0:36 ~ generator_print_verbose_1[7d1d]::make_non_send_generator2::{opaque#0}), [])`
 note: required because it's used within this generator
   --> $DIR/generator-print-verbose-1.rs:52:20
    |
diff --git a/tests/ui/generator/print/generator-print-verbose-2.rs b/tests/ui/generator/print/generator-print-verbose-2.rs
index d914719cb36..e53a7ef8cc1 100644
--- a/tests/ui/generator/print/generator-print-verbose-2.rs
+++ b/tests/ui/generator/print/generator-print-verbose-2.rs
@@ -2,8 +2,13 @@
 
 // Same as test/ui/generator/not-send-sync.rs
 #![feature(generators)]
+#![feature(negative_impls)]
 
-use std::cell::Cell;
+struct NotSend;
+struct NotSync;
+
+impl !Send for NotSend {}
+impl !Sync for NotSync {}
 
 fn main() {
     fn assert_sync<T: Sync>(_: T) {}
@@ -11,14 +16,15 @@ fn main() {
 
     assert_sync(|| {
         //~^ ERROR: generator cannot be shared between threads safely
-        let a = Cell::new(2);
+        let a = NotSync;
         yield;
+        drop(a);
     });
 
-    let a = Cell::new(2);
     assert_send(|| {
-        //~^ ERROR: E0277
-        drop(&a);
+        //~^ ERROR: generator cannot be sent between threads safely
+        let a = NotSend;
         yield;
+        drop(a);
     });
 }
diff --git a/tests/ui/generator/print/generator-print-verbose-2.stderr b/tests/ui/generator/print/generator-print-verbose-2.stderr
index 4e88e73f1d6..8ff7557619f 100644
--- a/tests/ui/generator/print/generator-print-verbose-2.stderr
+++ b/tests/ui/generator/print/generator-print-verbose-2.stderr
@@ -1,58 +1,42 @@
-error[E0277]: `Cell<i32>` cannot be shared between threads safely
-  --> $DIR/generator-print-verbose-2.rs:19:17
-   |
-LL |       assert_send(|| {
-   |  _____-----------_^
-   | |     |
-   | |     required by a bound introduced by this call
-LL | |
-LL | |         drop(&a);
-LL | |         yield;
-LL | |     });
-   | |_____^ `Cell<i32>` cannot be shared between threads safely
-   |
-   = help: the trait `Sync` is not implemented for `Cell<i32>`
-   = note: if you want to do aliasing and mutation between multiple threads, use `std::sync::RwLock` or `std::sync::atomic::AtomicI32` instead
-   = note: required for `&'?4 Cell<i32>` to implement `Send`
-note: required because it's used within this generator
-  --> $DIR/generator-print-verbose-2.rs:19:17
+error: generator cannot be shared between threads safely
+  --> $DIR/generator-print-verbose-2.rs:17:5
    |
-LL |     assert_send(|| {
-   |                 ^^
-note: required by a bound in `assert_send`
-  --> $DIR/generator-print-verbose-2.rs:10:23
+LL |     assert_sync(|| {
+   |     ^^^^^^^^^^^ generator is not `Sync`
    |
-LL |     fn assert_send<T: Send>(_: T) {}
-   |                       ^^^^ required by this bound in `assert_send`
-
-error: generator cannot be shared between threads safely
-  --> $DIR/generator-print-verbose-2.rs:12:17
-   |
-LL |       assert_sync(|| {
-   |  _________________^
-LL | |
-LL | |         let a = Cell::new(2);
-LL | |         yield;
-LL | |     });
-   | |_____^ generator is not `Sync`
-   |
-   = help: within `{main::{closure#0} upvar_tys=() {Cell<i32>, ()}}`, the trait `Sync` is not implemented for `Cell<i32>`
-   = note: if you want to do aliasing and mutation between multiple threads, use `std::sync::RwLock` or `std::sync::atomic::AtomicI32` instead
+   = help: within `{main::{closure#0} upvar_tys=() {main::{closure#0}}}`, the trait `Sync` is not implemented for `NotSync`
 note: generator is not `Sync` as this value is used across a yield
-  --> $DIR/generator-print-verbose-2.rs:15:9
+  --> $DIR/generator-print-verbose-2.rs:20:9
    |
-LL |         let a = Cell::new(2);
-   |             - has type `Cell<i32>` which is not `Sync`
+LL |         let a = NotSync;
+   |             - has type `NotSync` which is not `Sync`
 LL |         yield;
    |         ^^^^^ yield occurs here, with `a` maybe used later
-LL |     });
-   |     - `a` is later dropped here
 note: required by a bound in `assert_sync`
-  --> $DIR/generator-print-verbose-2.rs:9:23
+  --> $DIR/generator-print-verbose-2.rs:14:23
    |
 LL |     fn assert_sync<T: Sync>(_: T) {}
    |                       ^^^^ required by this bound in `assert_sync`
 
+error: generator cannot be sent between threads safely
+  --> $DIR/generator-print-verbose-2.rs:24:5
+   |
+LL |     assert_send(|| {
+   |     ^^^^^^^^^^^ generator is not `Send`
+   |
+   = help: within `{main::{closure#1} upvar_tys=() {main::{closure#1}}}`, the trait `Send` is not implemented for `NotSend`
+note: generator is not `Send` as this value is used across a yield
+  --> $DIR/generator-print-verbose-2.rs:27:9
+   |
+LL |         let a = NotSend;
+   |             - has type `NotSend` which is not `Send`
+LL |         yield;
+   |         ^^^^^ yield occurs here, with `a` maybe used later
+note: required by a bound in `assert_send`
+  --> $DIR/generator-print-verbose-2.rs:15:23
+   |
+LL |     fn assert_send<T: Send>(_: T) {}
+   |                       ^^^^ required by this bound in `assert_send`
+
 error: aborting due to 2 previous errors
 
-For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/generator/retain-resume-ref.stderr b/tests/ui/generator/retain-resume-ref.stderr
index e33310d12d9..bc715c7030e 100644
--- a/tests/ui/generator/retain-resume-ref.stderr
+++ b/tests/ui/generator/retain-resume-ref.stderr
@@ -4,9 +4,10 @@ error[E0499]: cannot borrow `thing` as mutable more than once at a time
 LL |     gen.as_mut().resume(&mut thing);
    |                         ---------- first mutable borrow occurs here
 LL |     gen.as_mut().resume(&mut thing);
-   |                  ------ ^^^^^^^^^^ second mutable borrow occurs here
-   |                  |
-   |                  first borrow later used by call
+   |                         ^^^^^^^^^^ second mutable borrow occurs here
+LL |
+LL | }
+   | - first borrow might be used here, when `gen` is dropped and runs the destructor for generator
 
 error: aborting due to previous error
 
diff --git a/tests/ui/generator/unresolved-ct-var.rs b/tests/ui/generator/unresolved-ct-var.rs
index 0a1570fc239..0316385fba9 100644
--- a/tests/ui/generator/unresolved-ct-var.rs
+++ b/tests/ui/generator/unresolved-ct-var.rs
@@ -5,10 +5,5 @@ fn main() {
     let _ = async {
         let s = std::array::from_fn(|_| ()).await;
         //~^ ERROR `[(); _]` is not a future
-        //~| ERROR type inside `async` block must be known in this context
-        //~| ERROR type inside `async` block must be known in this context
-        //~| ERROR type inside `async` block must be known in this context
-        //~| ERROR type inside `async` block must be known in this context
-        //~| ERROR type inside `async` block must be known in this context
     };
 }
diff --git a/tests/ui/generator/unresolved-ct-var.stderr b/tests/ui/generator/unresolved-ct-var.stderr
index ace254178b7..9badc1dc291 100644
--- a/tests/ui/generator/unresolved-ct-var.stderr
+++ b/tests/ui/generator/unresolved-ct-var.stderr
@@ -12,67 +12,6 @@ LL |         let s = std::array::from_fn(|_| ()).await;
    = note: [(); _] must be a future or must implement `IntoFuture` to be awaited
    = note: required for `[(); _]` to implement `IntoFuture`
 
-error[E0698]: type inside `async` block must be known in this context
-  --> $DIR/unresolved-ct-var.rs:6:17
-   |
-LL |         let s = std::array::from_fn(|_| ()).await;
-   |                 ^^^^^^^^^^^^^^^^^^^ cannot infer the value of const parameter `N` declared on the function `from_fn`
-   |
-note: the type is part of the `async` block because of this `await`
-  --> $DIR/unresolved-ct-var.rs:6:45
-   |
-LL |         let s = std::array::from_fn(|_| ()).await;
-   |                                             ^^^^^
-
-error[E0698]: type inside `async` block must be known in this context
-  --> $DIR/unresolved-ct-var.rs:6:17
-   |
-LL |         let s = std::array::from_fn(|_| ()).await;
-   |                 ^^^^^^^^^^^^^^^^^^^ cannot infer the value of const parameter `N` declared on the function `from_fn`
-   |
-note: the type is part of the `async` block because of this `await`
-  --> $DIR/unresolved-ct-var.rs:6:45
-   |
-LL |         let s = std::array::from_fn(|_| ()).await;
-   |                                             ^^^^^
-
-error[E0698]: type inside `async` block must be known in this context
-  --> $DIR/unresolved-ct-var.rs:6:17
-   |
-LL |         let s = std::array::from_fn(|_| ()).await;
-   |                 ^^^^^^^^^^^^^^^^^^^ cannot infer the value of const parameter `N` declared on the function `from_fn`
-   |
-note: the type is part of the `async` block because of this `await`
-  --> $DIR/unresolved-ct-var.rs:6:45
-   |
-LL |         let s = std::array::from_fn(|_| ()).await;
-   |                                             ^^^^^
-
-error[E0698]: type inside `async` block must be known in this context
-  --> $DIR/unresolved-ct-var.rs:6:17
-   |
-LL |         let s = std::array::from_fn(|_| ()).await;
-   |                 ^^^^^^^^^^^^^^^^^^^ cannot infer the value of const parameter `N` declared on the function `from_fn`
-   |
-note: the type is part of the `async` block because of this `await`
-  --> $DIR/unresolved-ct-var.rs:6:45
-   |
-LL |         let s = std::array::from_fn(|_| ()).await;
-   |                                             ^^^^^
-
-error[E0698]: type inside `async` block must be known in this context
-  --> $DIR/unresolved-ct-var.rs:6:17
-   |
-LL |         let s = std::array::from_fn(|_| ()).await;
-   |                 ^^^^^^^^^^^^^^^^^^^ cannot infer the value of const parameter `N` declared on the function `from_fn`
-   |
-note: the type is part of the `async` block because of this `await`
-  --> $DIR/unresolved-ct-var.rs:6:45
-   |
-LL |         let s = std::array::from_fn(|_| ()).await;
-   |                                             ^^^^^
-
-error: aborting due to 6 previous errors
+error: aborting due to previous error
 
-Some errors have detailed explanations: E0277, E0698.
-For more information about an error, try `rustc --explain E0277`.
+For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/generator/unsized-across-yield.rs b/tests/ui/generator/unsized-capture-across-yield.rs
index 876d08ac1f0..7bcb0800ccf 100644
--- a/tests/ui/generator/unsized-across-yield.rs
+++ b/tests/ui/generator/unsized-capture-across-yield.rs
@@ -5,17 +5,6 @@
 
 use std::ops::Generator;
 
-fn across() -> impl Generator {
-    move || {
-        let b: [u8] = *(Box::new([]) as Box<[u8]>);
-        //~^ ERROR the size for values of type `[u8]` cannot be known at compilation time
-
-        yield;
-
-        for elem in b.iter() {}
-    }
-}
-
 fn capture() -> impl Generator {
     let b: [u8] = *(Box::new([]) as Box<[u8]>);
     move || {
@@ -29,6 +18,5 @@ fn capture() -> impl Generator {
 }
 
 fn main() {
-    across();
     capture();
 }
diff --git a/tests/ui/generator/unsized-across-yield.stderr b/tests/ui/generator/unsized-capture-across-yield.stderr
index 82375a0ec2d..8a5b968a561 100644
--- a/tests/ui/generator/unsized-across-yield.stderr
+++ b/tests/ui/generator/unsized-capture-across-yield.stderr
@@ -1,5 +1,5 @@
 warning: the feature `unsized_locals` is incomplete and may not be safe to use and/or cause compiler crashes
-  --> $DIR/unsized-across-yield.rs:3:12
+  --> $DIR/unsized-capture-across-yield.rs:3:12
    |
 LL | #![feature(unsized_locals)]
    |            ^^^^^^^^^^^^^^
@@ -8,16 +8,7 @@ LL | #![feature(unsized_locals)]
    = note: `#[warn(incomplete_features)]` on by default
 
 error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
-  --> $DIR/unsized-across-yield.rs:10:13
-   |
-LL |         let b: [u8] = *(Box::new([]) as Box<[u8]>);
-   |             ^ doesn't have a size known at compile-time
-   |
-   = help: the trait `Sized` is not implemented for `[u8]`
-   = note: all values live across `yield` must have a statically known size
-
-error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
-  --> $DIR/unsized-across-yield.rs:22:27
+  --> $DIR/unsized-capture-across-yield.rs:11:27
    |
 LL |     move || {
    |          -- this closure captures all values by move
@@ -27,6 +18,6 @@ LL |         println!("{:?}", &b);
    = help: the trait `Sized` is not implemented for `[u8]`
    = note: all values captured by value by a closure must have a statically known size
 
-error: aborting due to 2 previous errors; 1 warning emitted
+error: aborting due to previous error; 1 warning emitted
 
 For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/generator/unsized-local-across-yield.rs b/tests/ui/generator/unsized-local-across-yield.rs
new file mode 100644
index 00000000000..f761f45c2af
--- /dev/null
+++ b/tests/ui/generator/unsized-local-across-yield.rs
@@ -0,0 +1,21 @@
+#![feature(generator_trait)]
+#![feature(generators)]
+#![feature(unsized_locals)]
+//~^ WARN the feature `unsized_locals` is incomplete and may not be safe to use and/or cause compiler crashes
+
+use std::ops::Generator;
+
+fn across() -> impl Generator {
+    move || {
+        let b: [u8] = *(Box::new([]) as Box<[u8]>);
+        //~^ ERROR the size for values of type `[u8]` cannot be known at compilation time
+
+        yield;
+
+        for elem in b.iter() {}
+    }
+}
+
+fn main() {
+    across();
+}
diff --git a/tests/ui/generator/unsized-local-across-yield.stderr b/tests/ui/generator/unsized-local-across-yield.stderr
new file mode 100644
index 00000000000..1942f266e6c
--- /dev/null
+++ b/tests/ui/generator/unsized-local-across-yield.stderr
@@ -0,0 +1,21 @@
+warning: the feature `unsized_locals` is incomplete and may not be safe to use and/or cause compiler crashes
+  --> $DIR/unsized-local-across-yield.rs:3:12
+   |
+LL | #![feature(unsized_locals)]
+   |            ^^^^^^^^^^^^^^
+   |
+   = note: see issue #48055 <https://github.com/rust-lang/rust/issues/48055> for more information
+   = note: `#[warn(incomplete_features)]` on by default
+
+error[E0277]: the size for values of type `[u8]` cannot be known at compilation time
+  --> $DIR/unsized-local-across-yield.rs:10:13
+   |
+LL |         let b: [u8] = *(Box::new([]) as Box<[u8]>);
+   |             ^ doesn't have a size known at compile-time
+   |
+   = help: the trait `Sized` is not implemented for `[u8]`
+   = note: all values live across `yield` must have a statically known size
+
+error: aborting due to previous error; 1 warning emitted
+
+For more information about this error, try `rustc --explain E0277`.
diff --git a/tests/ui/generic-associated-types/bugs/issue-100013.stderr b/tests/ui/generic-associated-types/bugs/issue-100013.stderr
index 86dbad84d99..93c69422f00 100644
--- a/tests/ui/generic-associated-types/bugs/issue-100013.stderr
+++ b/tests/ui/generic-associated-types/bugs/issue-100013.stderr
@@ -7,16 +7,6 @@ LL | |         async {}.await; // a yield point
 LL | |     }
    | |_____^
    |
-note: the lifetime defined here...
-  --> $DIR/issue-100013.rs:16:38
-   |
-LL |         let x = None::<I::Future<'_, '_>>; // a type referencing GAT
-   |                                      ^^
-note: ...must outlive the lifetime defined here
-  --> $DIR/issue-100013.rs:16:34
-   |
-LL |         let x = None::<I::Future<'_, '_>>; // a type referencing GAT
-   |                                  ^^
    = note: this is a known limitation that will be removed in the future (see issue #100013 <https://github.com/rust-lang/rust/issues/100013> for more information)
 
 error: lifetime bound not satisfied
@@ -28,16 +18,6 @@ LL | |         async {}.await; // a yield point
 LL | |     }
    | |_____^
    |
-note: the lifetime `'b` defined here...
-  --> $DIR/issue-100013.rs:21:14
-   |
-LL | fn call2<'a, 'b, I: FutureIterator>() -> impl Send {
-   |              ^^
-note: ...must outlive the lifetime `'a` defined here
-  --> $DIR/issue-100013.rs:21:10
-   |
-LL | fn call2<'a, 'b, I: FutureIterator>() -> impl Send {
-   |          ^^
    = note: this is a known limitation that will be removed in the future (see issue #100013 <https://github.com/rust-lang/rust/issues/100013> for more information)
 
 error: lifetime may not live long enough
@@ -62,16 +42,6 @@ LL | |         async {}.await; // a yield point
 LL | |     }
    | |_____^
    |
-note: the lifetime `'b` defined here...
-  --> $DIR/issue-100013.rs:28:18
-   |
-LL | fn call3<'a: 'b, 'b, I: FutureIterator>() -> impl Send {
-   |                  ^^
-note: ...must outlive the lifetime `'a` defined here
-  --> $DIR/issue-100013.rs:28:10
-   |
-LL | fn call3<'a: 'b, 'b, I: FutureIterator>() -> impl Send {
-   |          ^^
    = note: this is a known limitation that will be removed in the future (see issue #100013 <https://github.com/rust-lang/rust/issues/100013> for more information)
 
 error: aborting due to 4 previous errors
diff --git a/tests/ui/impl-trait/issue-55872-2.rs b/tests/ui/impl-trait/issue-55872-2.rs
index ec3d924cea7..8a96fdc5c63 100644
--- a/tests/ui/impl-trait/issue-55872-2.rs
+++ b/tests/ui/impl-trait/issue-55872-2.rs
@@ -13,6 +13,7 @@ impl<S> Bar for S {
     fn foo<T>() -> Self::E {
         async {}
         //~^ ERROR type parameter `T` is part of concrete type but not used in parameter list for the `impl Trait` type alias
+        //~| ERROR type parameter `T` is part of concrete type but not used in parameter list for the `impl Trait` type alias
     }
 }
 
diff --git a/tests/ui/impl-trait/issue-55872-2.stderr b/tests/ui/impl-trait/issue-55872-2.stderr
index 11b8485c8bb..3e70f1cf800 100644
--- a/tests/ui/impl-trait/issue-55872-2.stderr
+++ b/tests/ui/impl-trait/issue-55872-2.stderr
@@ -4,5 +4,11 @@ error: type parameter `T` is part of concrete type but not used in parameter lis
 LL |         async {}
    |         ^^^^^^^^
 
-error: aborting due to previous error
+error: type parameter `T` is part of concrete type but not used in parameter list for the `impl Trait` type alias
+  --> $DIR/issue-55872-2.rs:14:9
+   |
+LL |         async {}
+   |         ^^^^^^^^
+
+error: aborting due to 2 previous errors
 
diff --git a/tests/ui/impl-trait/recursive-generator.rs b/tests/ui/impl-trait/recursive-generator.rs
index e876f0fb43f..000af70c454 100644
--- a/tests/ui/impl-trait/recursive-generator.rs
+++ b/tests/ui/impl-trait/recursive-generator.rs
@@ -7,7 +7,6 @@ fn foo() -> impl Generator<Yield = (), Return = ()> {
     //~| NOTE recursive opaque type
     //~| NOTE in this expansion of desugaring of
     || {
-    //~^ NOTE returning here
         let mut gen = Box::pin(foo());
         //~^ NOTE generator captures itself here
         let mut r = gen.as_mut().resume(());
diff --git a/tests/ui/impl-trait/recursive-generator.stderr b/tests/ui/impl-trait/recursive-generator.stderr
index 9d8139ef114..86e193d9599 100644
--- a/tests/ui/impl-trait/recursive-generator.stderr
+++ b/tests/ui/impl-trait/recursive-generator.stderr
@@ -1,18 +1,11 @@
 error[E0720]: cannot resolve opaque type
   --> $DIR/recursive-generator.rs:5:13
    |
-LL |   fn foo() -> impl Generator<Yield = (), Return = ()> {
-   |               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ recursive opaque type
+LL | fn foo() -> impl Generator<Yield = (), Return = ()> {
+   |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ recursive opaque type
 ...
-LL | /     || {
-LL | |
-LL | |         let mut gen = Box::pin(foo());
-   | |             ------- generator captures itself here
-LL | |
-...  |
-LL | |         }
-LL | |     }
-   | |_____- returning here with type `{generator@$DIR/recursive-generator.rs:9:5: 9:7}`
+LL |         let mut gen = Box::pin(foo());
+   |             ------- generator captures itself here
 
 error: aborting due to previous error
 
diff --git a/tests/ui/impl-trait/recursive-impl-trait-type-indirect.stderr b/tests/ui/impl-trait/recursive-impl-trait-type-indirect.stderr
index a792e371185..1d919fb5240 100644
--- a/tests/ui/impl-trait/recursive-impl-trait-type-indirect.stderr
+++ b/tests/ui/impl-trait/recursive-impl-trait-type-indirect.stderr
@@ -112,16 +112,11 @@ LL |     (substs_change::<&T>(),)
 error[E0720]: cannot resolve opaque type
   --> $DIR/recursive-impl-trait-type-indirect.rs:72:24
    |
-LL |   fn generator_hold() -> impl Sized {
-   |                          ^^^^^^^^^^ recursive opaque type
-LL |
-LL | /     move || {
-LL | |         let x = generator_hold();
-   | |             - generator captures itself here
-LL | |         yield;
-LL | |         x;
-LL | |     }
-   | |_____- returning here with type `{generator@$DIR/recursive-impl-trait-type-indirect.rs:74:5: 74:12}`
+LL | fn generator_hold() -> impl Sized {
+   |                        ^^^^^^^^^^ recursive opaque type
+...
+LL |         let x = generator_hold();
+   |             - generator captures itself here
 
 error[E0720]: cannot resolve opaque type
   --> $DIR/recursive-impl-trait-type-indirect.rs:86:26
diff --git a/tests/ui/lint/must_not_suspend/dedup.rs b/tests/ui/lint/must_not_suspend/dedup.rs
index 81a08579bb7..867bdf2ec12 100644
--- a/tests/ui/lint/must_not_suspend/dedup.rs
+++ b/tests/ui/lint/must_not_suspend/dedup.rs
@@ -13,7 +13,10 @@ async fn wheeee<T>(t: T) {
 }
 
 async fn yes() {
-    wheeee(&No {}).await; //~ ERROR `No` held across
+    let no = No {};
+    //~^ ERROR `No` held across
+    wheeee(&no).await;
+    drop(no);
 }
 
 fn main() {
diff --git a/tests/ui/lint/must_not_suspend/dedup.stderr b/tests/ui/lint/must_not_suspend/dedup.stderr
index 6925b1640b2..5d5b04a5d95 100644
--- a/tests/ui/lint/must_not_suspend/dedup.stderr
+++ b/tests/ui/lint/must_not_suspend/dedup.stderr
@@ -1,14 +1,17 @@
 error: `No` held across a suspend point, but should not be
-  --> $DIR/dedup.rs:16:13
+  --> $DIR/dedup.rs:16:9
    |
-LL |     wheeee(&No {}).await;
-   |             ^^^^^  ----- the value is held across this suspend point
+LL |     let no = No {};
+   |         ^^
+LL |
+LL |     wheeee(&no).await;
+   |                 ----- the value is held across this suspend point
    |
 help: consider using a block (`{ ... }`) to shrink the value's scope, ending before the suspend point
-  --> $DIR/dedup.rs:16:13
+  --> $DIR/dedup.rs:16:9
    |
-LL |     wheeee(&No {}).await;
-   |             ^^^^^
+LL |     let no = No {};
+   |         ^^
 note: the lint level is defined here
   --> $DIR/dedup.rs:3:9
    |
diff --git a/tests/ui/lint/must_not_suspend/ref.stderr b/tests/ui/lint/must_not_suspend/ref.stderr
index 148af00a3d2..ed91a4a0bc6 100644
--- a/tests/ui/lint/must_not_suspend/ref.stderr
+++ b/tests/ui/lint/must_not_suspend/ref.stderr
@@ -1,22 +1,22 @@
-error: `Umm` held across a suspend point, but should not be
-  --> $DIR/ref.rs:18:26
+error: reference to `Umm` held across a suspend point, but should not be
+  --> $DIR/ref.rs:18:13
    |
 LL |         let guard = &mut self.u;
-   |                          ^^^^^^
+   |             ^^^^^
 LL |
 LL |         other().await;
    |                 ----- the value is held across this suspend point
    |
 note: You gotta use Umm's, ya know?
-  --> $DIR/ref.rs:18:26
+  --> $DIR/ref.rs:18:13
    |
 LL |         let guard = &mut self.u;
-   |                          ^^^^^^
+   |             ^^^^^
 help: consider using a block (`{ ... }`) to shrink the value's scope, ending before the suspend point
-  --> $DIR/ref.rs:18:26
+  --> $DIR/ref.rs:18:13
    |
 LL |         let guard = &mut self.u;
-   |                          ^^^^^^
+   |             ^^^^^
 note: the lint level is defined here
   --> $DIR/ref.rs:3:9
    |
diff --git a/tests/ui/lint/must_not_suspend/unit.rs b/tests/ui/lint/must_not_suspend/unit.rs
index d3a19f70432..af4a76caa4e 100644
--- a/tests/ui/lint/must_not_suspend/unit.rs
+++ b/tests/ui/lint/must_not_suspend/unit.rs
@@ -19,6 +19,7 @@ async fn other() {}
 pub async fn uhoh() {
     let _guard = bar(); //~ ERROR `Umm` held across
     other().await;
+    drop(_guard);
 }
 
 fn main() {
diff --git a/tests/ui/lint/must_not_suspend/warn.rs b/tests/ui/lint/must_not_suspend/warn.rs
index 7fdea66a235..2d5dd01e5bf 100644
--- a/tests/ui/lint/must_not_suspend/warn.rs
+++ b/tests/ui/lint/must_not_suspend/warn.rs
@@ -18,8 +18,9 @@ fn bar() -> Umm {
 async fn other() {}
 
 pub async fn uhoh() {
-    let _guard = bar(); //~ WARNING `Umm` held across
+    let guard = bar(); //~ WARNING `Umm` held across
     other().await;
+    drop(guard);
 }
 
 fn main() {
diff --git a/tests/ui/lint/must_not_suspend/warn.stderr b/tests/ui/lint/must_not_suspend/warn.stderr
index 194433552cf..e59656e508c 100644
--- a/tests/ui/lint/must_not_suspend/warn.stderr
+++ b/tests/ui/lint/must_not_suspend/warn.stderr
@@ -1,21 +1,21 @@
 warning: `Umm` held across a suspend point, but should not be
   --> $DIR/warn.rs:21:9
    |
-LL |     let _guard = bar();
-   |         ^^^^^^
+LL |     let guard = bar();
+   |         ^^^^^
 LL |     other().await;
    |             ----- the value is held across this suspend point
    |
 note: You gotta use Umm's, ya know?
   --> $DIR/warn.rs:21:9
    |
-LL |     let _guard = bar();
-   |         ^^^^^^
+LL |     let guard = bar();
+   |         ^^^^^
 help: consider using a block (`{ ... }`) to shrink the value's scope, ending before the suspend point
   --> $DIR/warn.rs:21:9
    |
-LL |     let _guard = bar();
-   |         ^^^^^^
+LL |     let guard = bar();
+   |         ^^^^^
 note: the lint level is defined here
   --> $DIR/warn.rs:4:9
    |
diff --git a/tests/ui/traits/new-solver/auto-with-drop_tracking_mir.rs b/tests/ui/traits/new-solver/auto-with-drop_tracking_mir.rs
index e311a4af2f4..6b54718e35c 100644
--- a/tests/ui/traits/new-solver/auto-with-drop_tracking_mir.rs
+++ b/tests/ui/traits/new-solver/auto-with-drop_tracking_mir.rs
@@ -1,4 +1,4 @@
-// compile-flags: -Ztrait-solver=next -Zdrop-tracking-mir
+// compile-flags: -Ztrait-solver=next
 // edition: 2021
 // revisions: pass fail
 //[pass] check-pass
diff --git a/tests/ui/traits/unsend-future.rs b/tests/ui/traits/unsend-future.rs
index fbbc07b11e7..a8367573fbd 100644
--- a/tests/ui/traits/unsend-future.rs
+++ b/tests/ui/traits/unsend-future.rs
@@ -13,6 +13,7 @@ fn require_handler<H: Handler>(h: H) {}
 async fn handler() {
     let a = &1 as *const i32;
     async {}.await;
+    let b = a;
 }
 
 fn main() {
diff --git a/tests/ui/traits/unsend-future.stderr b/tests/ui/traits/unsend-future.stderr
index 6ce1cf452f4..01829021b4a 100644
--- a/tests/ui/traits/unsend-future.stderr
+++ b/tests/ui/traits/unsend-future.stderr
@@ -1,5 +1,5 @@
 error: future cannot be sent between threads safely
-  --> $DIR/unsend-future.rs:19:21
+  --> $DIR/unsend-future.rs:20:21
    |
 LL |     require_handler(handler)
    |                     ^^^^^^^ future returned by `handler` is not `Send`
@@ -12,8 +12,6 @@ LL |     let a = &1 as *const i32;
    |         - has type `*const i32` which is not `Send`
 LL |     async {}.await;
    |              ^^^^^ await occurs here, with `a` maybe used later
-LL | }
-   | - `a` is later dropped here
 note: required by a bound in `require_handler`
   --> $DIR/unsend-future.rs:11:23
    |
diff --git a/tests/ui/type-alias-impl-trait/indirect-recursion-issue-112047.rs b/tests/ui/type-alias-impl-trait/indirect-recursion-issue-112047.rs
index baa22e1ce18..f6cbbf04d82 100644
--- a/tests/ui/type-alias-impl-trait/indirect-recursion-issue-112047.rs
+++ b/tests/ui/type-alias-impl-trait/indirect-recursion-issue-112047.rs
@@ -1,6 +1,6 @@
 // edition: 2021
 // build-fail
-//~^^ ERROR overflow evaluating the requirement `<() as Recur>::Recur == _`
+//~^^ ERROR cycle detected when computing layout of
 
 #![feature(impl_trait_in_assoc_type)]
 
diff --git a/tests/ui/type-alias-impl-trait/indirect-recursion-issue-112047.stderr b/tests/ui/type-alias-impl-trait/indirect-recursion-issue-112047.stderr
index 0238694c24d..3312230bc81 100644
--- a/tests/ui/type-alias-impl-trait/indirect-recursion-issue-112047.stderr
+++ b/tests/ui/type-alias-impl-trait/indirect-recursion-issue-112047.stderr
@@ -1,5 +1,16 @@
-error[E0275]: overflow evaluating the requirement `<() as Recur>::Recur == _`
+error[E0391]: cycle detected when computing layout of `{async block@$DIR/indirect-recursion-issue-112047.rs:23:9: 23:42}`
+   |
+   = note: ...which requires computing layout of `core::mem::maybe_uninit::MaybeUninit<recur::{opaque#0}>`...
+   = note: ...which requires computing layout of `core::mem::maybe_uninit::MaybeUninit<{async fn body@$DIR/indirect-recursion-issue-112047.rs:15:31: 17:2}>`...
+   = note: ...which requires computing layout of `core::mem::manually_drop::ManuallyDrop<{async fn body@$DIR/indirect-recursion-issue-112047.rs:15:31: 17:2}>`...
+   = note: ...which requires computing layout of `{async fn body@$DIR/indirect-recursion-issue-112047.rs:15:31: 17:2}`...
+   = note: ...which requires computing layout of `core::mem::maybe_uninit::MaybeUninit<<() as Recur>::Recur>`...
+   = note: ...which requires computing layout of `core::mem::maybe_uninit::MaybeUninit<{async block@$DIR/indirect-recursion-issue-112047.rs:23:9: 23:42}>`...
+   = note: ...which requires computing layout of `core::mem::manually_drop::ManuallyDrop<{async block@$DIR/indirect-recursion-issue-112047.rs:23:9: 23:42}>`...
+   = note: ...which again requires computing layout of `{async block@$DIR/indirect-recursion-issue-112047.rs:23:9: 23:42}`, completing the cycle
+   = note: cycle used when computing layout of `<impl at $DIR/indirect-recursion-issue-112047.rs:19:1: 19:18>::Recur`
+   = note: see https://rustc-dev-guide.rust-lang.org/overview.html#queries and https://rustc-dev-guide.rust-lang.org/query.html for more information
 
 error: aborting due to previous error
 
-For more information about this error, try `rustc --explain E0275`.
+For more information about this error, try `rustc --explain E0391`.