fork/rust
git clone https://git.julia.blue/fork/rust
3bcad65fbf6
master
1error: lifetime may not live long enough 2 --> $DIR/regions-variance-invariant-use-covariant.rs:17:12 3 | 4LL | fn use_<'b>(c: Invariant<'b>) { 5 | -- lifetime `'b` defined here 6... 7LL | let _: Invariant<'static> = c; 8 | ^^^^^^^^^^^^^^^^^^ type annotation requires that `'b` must outlive `'static` 9 | 10 = note: requirement occurs because of the type `Invariant<'_>`, which makes the generic argument `'_` invariant 11 = note: the struct `Invariant<'a>` is invariant over the parameter `'a` 12 = help: see <https://doc.rust-lang.org/nomicon/subtyping.html> for more information about variance 13 14error: aborting due to previous error 15