1 error[E0716]: temporary value dropped while borrowed
2 --> $DIR/auto-trait-regions.rs:45:24
4 LL | let a = A(&mut true, &mut true, No);
5 | ^^^^ - temporary value is freed at the end of this statement
7 | creates a temporary value which is freed while still in use
10 | - borrow later used here
12 = note: consider using a `let` binding to create a longer lived value
14 error[E0716]: temporary value dropped while borrowed
15 --> $DIR/auto-trait-regions.rs:45:35
17 LL | let a = A(&mut true, &mut true, No);
18 | ^^^^ - temporary value is freed at the end of this statement
20 | creates a temporary value which is freed while still in use
23 | - borrow later used here
25 = note: consider using a `let` binding to create a longer lived value
27 error: implementation of `Foo` is not general enough
28 --> $DIR/auto-trait-regions.rs:31:5
31 | ^^^^^^^^^^^^^^^ implementation of `Foo` is not general enough
33 = note: `&'0 OnlyFooIfStaticRef` must implement `Foo`, for any lifetime `'0`...
34 = note: ...but `Foo` is actually implemented for the type `&'static OnlyFooIfStaticRef`
36 error: implementation of `Foo` is not general enough
37 --> $DIR/auto-trait-regions.rs:51:5
40 | ^^^^^^^^^^^^^^^ implementation of `Foo` is not general enough
42 = note: `Foo` would have to be implemented for the type `A<'0, '1>`, for any two lifetimes `'0` and `'1`...
43 = note: ...but `Foo` is actually implemented for the type `A<'_, '2>`, for some specific lifetime `'2`
45 error: aborting due to 4 previous errors
47 For more information about this error, try `rustc --explain E0716`.