More progress :)
parent: tbd commit: 92c3f32
1 | use transmute; |
2 | |
3 | use |
4 | , | Instance
5 | , |
6 | ; |
7 | |
8 | use crate::; |
9 | |
10 | use OperationVTable; |
11 | |
12 | |
13 | |
14 | /// A pointer to the plugin-local object type. We are not capable of |
15 | /// knowing what this type is, we use the provided vtable. |
16 | inner: , |
17 | pub vtable: SettingVtable, |
18 | |
19 | |
20 | |
21 | |
22 | Self |
23 | inner: from_box .untyped, |
24 | vtable: , |
25 | |
26 | |
27 | |
28 | pub unsafe |
29 | Box from_raw |
30 | |
31 | |
32 | pub unsafe |
33 | let ptr: *const T = transmute; |
34 | |
35 | ptr.as_ref .unwrap |
36 | |
37 | |
38 | |
39 | |
40 | |
41 | unsafe |
42 | |
43 | |
44 | |
45 | |
46 | |
47 | |
48 | pub get_setting_vtable: unsafe extern "C" fn , |
49 | |
50 | pub deserialize: unsafe extern "C" fn , |
51 | pub serialize: unsafe extern "C" fn , |
52 | |
53 | |
54 | |
55 | |
56 | Self |
57 | get_setting_vtable: get_setting_vtable, |
58 | deserialize: deserialize, |
59 | serialize: serialize, |
60 | |
61 | |
62 | |
63 | |
64 | |
65 | unsafe extern "C" ; |
66 | unsafe extern "C" ; |
67 | unsafe extern "C" ; |
68 | |
69 | |
70 | |
71 | |
72 | S: Setting, |
73 | |
74 | unsafe extern "C" |
75 | todo! |
76 | |
77 | |
78 | unsafe extern "C" |
79 | let setting = this.; |
80 | |
81 | let serialized = to_vec .unwrap; |
82 | |
83 | let serialized = serialized.into_boxed_slice; |
84 | |
85 | Ok |
86 | |
87 | |
88 | unsafe extern "C" |
89 | |
90 | |
91 | |
92 |