2018-08-30 07:18:55 -05:00
|
|
|
// run-pass
|
2018-09-25 16:51:35 -05:00
|
|
|
#![allow(dead_code)]
|
2015-03-22 15:13:15 -05:00
|
|
|
// pretty-expanded FIXME #23616
|
|
|
|
|
2015-02-12 09:29:52 -06:00
|
|
|
trait Aaa { fn dummy(&self) { } }
|
2014-12-07 09:22:06 -06:00
|
|
|
|
2019-05-28 13:47:21 -05:00
|
|
|
impl<'a> Aaa for &'a mut (dyn Aaa + 'a) {}
|
2014-12-07 09:22:06 -06:00
|
|
|
|
|
|
|
struct Bar<'a> {
|
2019-05-28 13:47:21 -05:00
|
|
|
writer: &'a mut (dyn Aaa + 'a),
|
2014-12-07 09:22:06 -06:00
|
|
|
}
|
|
|
|
|
2019-05-28 13:47:21 -05:00
|
|
|
fn baz(_: &mut dyn Aaa) {
|
2014-12-07 09:22:06 -06:00
|
|
|
}
|
|
|
|
|
|
|
|
fn foo<'a>(mut bar: Bar<'a>) {
|
|
|
|
baz(&mut bar.writer);
|
|
|
|
}
|
|
|
|
|
|
|
|
fn main() {
|
|
|
|
}
|