]> git.proxmox.com Git - rustc.git/blame - src/test/ui/in-band-lifetimes/mismatched_trait_impl-2.rs
New upstream version 1.36.0+dfsg1
[rustc.git] / src / test / ui / in-band-lifetimes / mismatched_trait_impl-2.rs
CommitLineData
2c00a5a8
XL
1use std::ops::Deref;
2trait Trait {}
a7813a04 3
2c00a5a8 4struct Struct;
a7813a04 5
2c00a5a8
XL
6impl Deref for Struct {
7 type Target = Trait;
8 fn deref(&self) -> &Trait {
9 unimplemented!();
a7813a04 10 }
ff7c6d11 11}
2c00a5a8 12//~^^^^ ERROR cannot infer an appropriate lifetime for lifetime parameter
0531ce1d
XL
13
14fn main() {}