2017-11-26 14:28:04 -06:00
|
|
|
#![allow(dead_code)]
|
|
|
|
|
|
|
|
use std::cell::Cell;
|
|
|
|
|
|
|
|
struct Foo<'a: 'b, 'b> {
|
|
|
|
x: Cell<&'a u32>,
|
|
|
|
y: Cell<&'b u32>,
|
|
|
|
}
|
|
|
|
|
|
|
|
fn bar<'a, 'b>(x: Cell<&'a u32>, y: Cell<&'b u32>) {
|
|
|
|
Foo { x, y };
|
2018-12-11 15:49:40 -06:00
|
|
|
//~^ ERROR lifetime may not live long enough
|
2017-11-26 14:28:04 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {}
|