2016-12-22 19:46:08 +02:00
|
|
|
pub trait Resources<'a> {}
|
|
|
|
|
|
|
|
pub trait Buffer<'a, R: Resources<'a>> {
|
2017-05-11 15:05:00 +03:00
|
|
|
|
2016-12-22 19:46:08 +02:00
|
|
|
fn select(&self) -> BufferViewHandle<R>;
|
|
|
|
//~^ ERROR mismatched types
|
|
|
|
//~| lifetime mismatch
|
|
|
|
//~| ERROR mismatched types
|
|
|
|
//~| lifetime mismatch
|
|
|
|
}
|
|
|
|
|
|
|
|
pub struct BufferViewHandle<'a, R: 'a+Resources<'a>>(&'a R);
|
|
|
|
|
|
|
|
fn main() {}
|