]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-47703.rs
Rollup merge of #92942 - Xaeroxe:raw_arg, r=dtolnay
[rust.git] / src / test / ui / issues / issue-47703.rs
1 // check-pass
2
3 struct MyStruct<'a> {
4     field: &'a mut (),
5     field2: WithDrop
6 }
7
8 struct WithDrop;
9
10 impl Drop for WithDrop {
11     fn drop(&mut self) {}
12 }
13
14 impl<'a> MyStruct<'a> {
15     fn consume(self) -> &'a mut () { self.field }
16 }
17
18 fn main() {}