about summary refs log tree commit diff
path: root/tests/ui/impl-trait/precise-capturing
diff options
context:
space:
mode:
authorEsteban Küber <esteban@kuber.com.ar>2025-08-29 20:14:01 +0000
committerEsteban Küber <esteban@kuber.com.ar>2025-09-28 20:55:34 +0000
commit7a0319f01d08e541c8e16febaa68c5fa8b66b586 (patch)
treeec121637a9fd9181f608a83bd24b53c3ad3b2f22 /tests/ui/impl-trait/precise-capturing
parentc3e0b29e79f347edf7e0ae559bfec2d3cdf353d8 (diff)
downloadrust-7a0319f01d08e541c8e16febaa68c5fa8b66b586.tar.gz
rust-7a0319f01d08e541c8e16febaa68c5fa8b66b586.zip
Point at lifetime requirement origin in more cases
Diffstat (limited to 'tests/ui/impl-trait/precise-capturing')
-rw-r--r--tests/ui/impl-trait/precise-capturing/migration-note.rs4
-rw-r--r--tests/ui/impl-trait/precise-capturing/migration-note.stderr4
2 files changed, 4 insertions, 4 deletions
diff --git a/tests/ui/impl-trait/precise-capturing/migration-note.rs b/tests/ui/impl-trait/precise-capturing/migration-note.rs
index 25b594e9b1e..211def33320 100644
--- a/tests/ui/impl-trait/precise-capturing/migration-note.rs
+++ b/tests/ui/impl-trait/precise-capturing/migration-note.rs
@@ -32,7 +32,7 @@ fn needs_static() {
     //~| NOTE borrowed value does not live long enoug
 
     fn needs_static(_: impl Sized + 'static) {}
-    //~^ NOTE requirement that `x` is borrowed for `'static` introduced here
+    //~^ NOTE requirement for `'static` introduced here
     needs_static(a);
     //~^ NOTE argument requires that `x` is borrowed for `'static`
 }
@@ -80,7 +80,7 @@ fn needs_static_mut() {
     //~| NOTE borrowed value does not live long enough
 
     fn needs_static(_: impl Sized + 'static) {}
-    //~^ NOTE requirement that `x` is borrowed for `'static` introduced here
+    //~^ NOTE requirement for `'static` introduced here
     needs_static(a);
     //~^ NOTE argument requires that `x` is borrowed for `'static`
 }
diff --git a/tests/ui/impl-trait/precise-capturing/migration-note.stderr b/tests/ui/impl-trait/precise-capturing/migration-note.stderr
index e42a6f15c7e..c06b14a4113 100644
--- a/tests/ui/impl-trait/precise-capturing/migration-note.stderr
+++ b/tests/ui/impl-trait/precise-capturing/migration-note.stderr
@@ -50,7 +50,7 @@ LL |
 LL | }
    | - `x` dropped here while still borrowed
    |
-note: requirement that `x` is borrowed for `'static` introduced here
+note: requirement for `'static` introduced here
   --> $DIR/migration-note.rs:34:37
    |
 LL |     fn needs_static(_: impl Sized + 'static) {}
@@ -131,7 +131,7 @@ LL |
 LL | }
    | - `x` dropped here while still borrowed
    |
-note: requirement that `x` is borrowed for `'static` introduced here
+note: requirement for `'static` introduced here
   --> $DIR/migration-note.rs:82:37
    |
 LL |     fn needs_static(_: impl Sized + 'static) {}