move destroy fn out of `gl`

This commit is contained in:
Nick Spagnola 2020-06-29 07:01:19 -07:00
parent bd6d7eb489
commit 04787f1514
No known key found for this signature in database
GPG Key ID: 4FB92FAC62E13DFE
1 changed files with 4 additions and 5 deletions

View File

@ -530,6 +530,10 @@ pub unsafe extern "C" fn PFFilesystemResourceLoaderFromPath(path: *const c_char)
Box::into_raw(Box::new(ResourceLoaderWrapper(loader as Box<dyn ResourceLoader>)))
}
#[no_mangle]
pub unsafe extern "C" fn PFResourceLoaderDestroy(loader: PFResourceLoaderRef) {
drop(Box::from_raw(loader))
}
// `gl`
@ -558,11 +562,6 @@ pub unsafe extern "C" fn PFGLDeviceDestroy(device: PFGLDeviceRef) {
drop(Box::from_raw(device))
}
#[no_mangle]
pub unsafe extern "C" fn PFResourceLoaderDestroy(loader: PFResourceLoaderRef) {
drop(Box::from_raw(loader))
}
// `gpu`
#[no_mangle]