diff options
Diffstat (limited to 'rust/src/callingconvention.rs')
| -rw-r--r-- | rust/src/callingconvention.rs | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/rust/src/callingconvention.rs b/rust/src/callingconvention.rs index 4af9b9c9..dcb88970 100644 --- a/rust/src/callingconvention.rs +++ b/rust/src/callingconvention.rs @@ -409,12 +409,15 @@ unsafe impl<A: Architecture> Send for CallingConvention<A> {} unsafe impl<A: Architecture> Sync for CallingConvention<A> {} impl<A: Architecture> CallingConvention<A> { - pub(crate) unsafe fn from_raw(handle: *mut BNCallingConvention, arch: A::Handle) -> Self { - CallingConvention { + pub(crate) unsafe fn ref_from_raw( + handle: *mut BNCallingConvention, + arch: A::Handle, + ) -> Ref<Self> { + Ref::new(CallingConvention { handle: handle, arch_handle: arch, _arch: PhantomData, - } + }) } } |
