]>
Commit | Line | Data |
---|---|---|
dc9dc135 XL |
1 | // check-pass |
2 | ||
dc9dc135 XL |
3 | #![allow(non_snake_case)] |
4 | ||
5 | use std::pin::Pin; | |
6 | use std::rc::Rc; | |
7 | ||
8 | struct Struct<'a> { | |
9 | x: &'a u32 | |
10 | } | |
11 | ||
12 | impl<'a> Struct<'a> { | |
13 | fn take_self(self, f: &u32) -> &u32 { | |
14 | f | |
15 | } | |
16 | ||
17 | fn take_Self(self: Self, f: &u32) -> &u32 { | |
18 | f | |
19 | } | |
20 | ||
21 | fn take_Box_Self(self: Box<Self>, f: &u32) -> &u32 { | |
22 | f | |
23 | } | |
24 | ||
25 | fn take_Box_Box_Self(self: Box<Box<Self>>, f: &u32) -> &u32 { | |
26 | f | |
27 | } | |
28 | ||
29 | fn take_Rc_Self(self: Rc<Self>, f: &u32) -> &u32 { | |
30 | f | |
31 | } | |
32 | ||
33 | fn take_Box_Rc_Self(self: Box<Rc<Self>>, f: &u32) -> &u32 { | |
34 | f | |
35 | } | |
36 | ||
37 | // N/A | |
38 | //fn take_Pin_Self(self: Pin<Self>, f: &u32) -> &u32 { | |
39 | // f | |
40 | //} | |
41 | ||
42 | // N/A | |
43 | //fn take_Box_Pin_Self(self: Box<Pin<Self>>, f: &u32) -> &u32 { | |
44 | // f | |
45 | //} | |
46 | } | |
47 | ||
48 | fn main() { } |