about summary refs log tree commit diff
path: root/src/test/ui/object-lifetime/object-lifetime-default-from-rptr-struct-error.base.stderr
blob: b97a7d225499533578fd4e7f6522f9db9130b317 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
error[E0308]: mismatched types
  --> $DIR/object-lifetime-default-from-rptr-struct-error.rs:24:12
   |
LL |     ss.t = t;
   |            ^ lifetime mismatch
   |
   = note: expected reference `&'a MyBox<(dyn Test + 'static)>`
              found reference `&'a MyBox<(dyn Test + 'a)>`
note: the lifetime `'a` as defined here...
  --> $DIR/object-lifetime-default-from-rptr-struct-error.rs:23:6
   |
LL | fn c<'a>(t: &'a MyBox<dyn Test+'a>, mut ss: SomeStruct<'a>) {
   |      ^^
   = note: ...does not necessarily outlive the static lifetime

error: aborting due to previous error

For more information about this error, try `rustc --explain E0308`.