]> git.lizzy.rs Git - rust.git/blob - src/test/ui/variance/variance-associated-types2.stderr
Move some tests with compare-mode=nll output to revisions
[rust.git] / src / test / ui / variance / variance-associated-types2.stderr
1 error[E0308]: mismatched types
2   --> $DIR/variance-associated-types2.rs:13:42
3    |
4 LL |     let _: Box<dyn Foo<Bar = &'a u32>> = make();
5    |                                          ^^^^^^ lifetime mismatch
6    |
7    = note: expected trait object `dyn Foo<Bar = &'a u32>`
8               found trait object `dyn Foo<Bar = &'static u32>`
9 note: the lifetime `'a` as defined here...
10   --> $DIR/variance-associated-types2.rs:12:9
11    |
12 LL | fn take<'a>(_: &'a u32) {
13    |         ^^
14    = note: ...does not necessarily outlive the static lifetime
15
16 error: aborting due to previous error
17
18 For more information about this error, try `rustc --explain E0308`.