summary refs log tree commit diff
path: root/src/test/ui/object-lifetime/object-lifetime-default-from-rptr-struct-error.nll.stderr
blob: 803f9d3fd7e5c27086209211b57ced335843c26c (plain)
1
2
3
4
5
6
7
8
9
10
error: borrowed data escapes outside of function
  --> $DIR/object-lifetime-default-from-rptr-struct-error.rs:31:5
   |
LL | fn c<'a>(t: &'a MyBox<Test+'a>, mut ss: SomeStruct<'a>) {
   |          - `t` is a reference that is only valid in the function body
LL |     ss.t = t; //~ ERROR mismatched types
   |     ^^^^^^^^ `t` escapes the function body here

error: aborting due to previous error