1 // A method's receiver must be well-formed, even if it has late-bound regions.
2 // Because of this, a method's substs being well-formed does not imply that
3 // the method's implied bounds are met.
5 struct Foo<'b>(Option<&'b ()>);
8 fn xmute<'a>(&'a self, u: &'b u32) -> &'a u32;
11 impl<'b> Bar<'b> for Foo<'b> {
12 fn xmute<'a>(&'a self, u: &'b u32) -> &'a u32 { u }
19 let pointer = Box::new(42);
22 //~^^ ERROR `pointer` does not live long enough
23 println!("{}", dangling);