functionalscript 0.0.415 → 0.0.416
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -35,7 +35,7 @@ impl<T: Class> CObject<T> {
|
|
|
35
35
|
};
|
|
36
36
|
|
|
37
37
|
#[allow(non_snake_case)]
|
|
38
|
-
extern "
|
|
38
|
+
extern "system" fn QueryInterface(
|
|
39
39
|
this: &Object<T::Interface>,
|
|
40
40
|
riid: &u128,
|
|
41
41
|
ppv_object: &mut *const Object,
|
|
@@ -51,7 +51,7 @@ impl<T: Class> CObject<T> {
|
|
|
51
51
|
}
|
|
52
52
|
|
|
53
53
|
#[allow(non_snake_case)]
|
|
54
|
-
extern "
|
|
54
|
+
extern "system" fn AddRef(this: &Object<T::Interface>) -> u32 {
|
|
55
55
|
unsafe { T::to_cobject(this) }
|
|
56
56
|
.counter
|
|
57
57
|
.fetch_add(1, Ordering::Relaxed)
|
|
@@ -59,7 +59,7 @@ impl<T: Class> CObject<T> {
|
|
|
59
59
|
}
|
|
60
60
|
|
|
61
61
|
#[allow(non_snake_case)]
|
|
62
|
-
extern "
|
|
62
|
+
extern "system" fn Release(this: &Object<T::Interface>) -> u32 {
|
|
63
63
|
let t = unsafe { T::to_cobject(this) };
|
|
64
64
|
match t.counter.fetch_sub(1, Ordering::Relaxed) {
|
|
65
65
|
1 => {
|
|
@@ -3,11 +3,11 @@ use crate::{hresult::HRESULT, Object, GUID};
|
|
|
3
3
|
#[allow(non_snake_case)]
|
|
4
4
|
#[repr(C)]
|
|
5
5
|
pub struct IUnknown<I: 'static> {
|
|
6
|
-
pub QueryInterface: unsafe extern "
|
|
6
|
+
pub QueryInterface: unsafe extern "system" fn(
|
|
7
7
|
this: &Object<I>,
|
|
8
8
|
riid: &GUID,
|
|
9
9
|
ppv_object: &mut *const Object,
|
|
10
10
|
) -> HRESULT,
|
|
11
|
-
pub AddRef: unsafe extern "
|
|
12
|
-
pub Release: unsafe extern "
|
|
11
|
+
pub AddRef: unsafe extern "system" fn(this: &Object<I>) -> u32,
|
|
12
|
+
pub Release: unsafe extern "system" fn(this: &Object<I>) -> u32,
|
|
13
13
|
}
|