2018-08-08 07:28:26 -05:00
|
|
|
error[E0623]: lifetime mismatch
|
2018-09-27 16:30:04 -05:00
|
|
|
--> $DIR/regions-variance-invariant-use-contravariant.rs:30:32
|
2018-08-08 07:28:26 -05:00
|
|
|
|
|
|
|
|
LL | fn use_<'short,'long>(c: Invariant<'long>,
|
|
|
|
| ----------------
|
|
|
|
LL | s: &'short isize,
|
|
|
|
| ------------- these two types are declared with different lifetimes...
|
|
|
|
...
|
|
|
|
LL | let _: Invariant<'short> = c; //~ ERROR E0623
|
|
|
|
| ^ ...but data from `s` flows into `c` here
|
|
|
|
|
|
|
|
error: aborting due to previous error
|
|
|
|
|
|
|
|
For more information about this error, try `rustc --explain E0623`.
|