summaryrefslogtreecommitdiffstats
path: root/tests/ui/nll/ty-outlives/projection-where-clause-env-wrong-bound.stderr
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-06-07 05:48:42 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-06-07 05:48:42 +0000
commitcec1877e180393eba0f6ddb0cf97bf3a791631c7 (patch)
tree47b4dac2a9dd9a40c30c251b4d4a72d7ccf77e9f /tests/ui/nll/ty-outlives/projection-where-clause-env-wrong-bound.stderr
parentAdding debian version 1.74.1+dfsg1-1. (diff)
downloadrustc-cec1877e180393eba0f6ddb0cf97bf3a791631c7.tar.xz
rustc-cec1877e180393eba0f6ddb0cf97bf3a791631c7.zip
Merging upstream version 1.75.0+dfsg1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'tests/ui/nll/ty-outlives/projection-where-clause-env-wrong-bound.stderr')
-rw-r--r--tests/ui/nll/ty-outlives/projection-where-clause-env-wrong-bound.stderr6
1 files changed, 4 insertions, 2 deletions
diff --git a/tests/ui/nll/ty-outlives/projection-where-clause-env-wrong-bound.stderr b/tests/ui/nll/ty-outlives/projection-where-clause-env-wrong-bound.stderr
index b4435fe06..1fa74f67c 100644
--- a/tests/ui/nll/ty-outlives/projection-where-clause-env-wrong-bound.stderr
+++ b/tests/ui/nll/ty-outlives/projection-where-clause-env-wrong-bound.stderr
@@ -1,11 +1,13 @@
error[E0309]: the associated type `<T as MyTrait<'_>>::Output` may not live long enough
--> $DIR/projection-where-clause-env-wrong-bound.rs:15:5
|
+LL | fn foo1<'a, 'b, T>() -> &'a ()
+ | -- the associated type `<T as MyTrait<'_>>::Output` must be valid for the lifetime `'a` as defined here...
+...
LL | bar::<T::Output>()
- | ^^^^^^^^^^^^^^^^
+ | ^^^^^^^^^^^^^^^^ ...so that the type `<T as MyTrait<'_>>::Output` will meet its required lifetime bounds
|
= help: consider adding an explicit lifetime bound `<T as MyTrait<'_>>::Output: 'a`...
- = note: ...so that the type `<T as MyTrait<'_>>::Output` will meet its required lifetime bounds
error: aborting due to previous error