pub struct CudaResourceGuard<'s, T> { /* private fields */ }Expand description
A vendor resource lent from the engine’s extension caches for the session’s life.
§Examples
use tenferro_gpu::cuda::raw::CudaResourceGuard;
fn handle_lifetime(guard: &CudaResourceGuard<'_, u64>) -> u64 {
// The guard dereferences to the cached resource and releases it when dropped.
**guard + 1
}
Trait Implementations§
Source§impl<T: Debug> Debug for CudaResourceGuard<'_, T>
impl<T: Debug> Debug for CudaResourceGuard<'_, T>
Source§impl<T> Deref for CudaResourceGuard<'_, T>
impl<T> Deref for CudaResourceGuard<'_, T>
Auto Trait Implementations§
impl<'s, T> !RefUnwindSafe for CudaResourceGuard<'s, T>
impl<'s, T> !Send for CudaResourceGuard<'s, T>
impl<'s, T> !Sync for CudaResourceGuard<'s, T>
impl<'s, T> !UnwindSafe for CudaResourceGuard<'s, T>
impl<'s, T> Freeze for CudaResourceGuard<'s, T>
impl<'s, T> Unpin for CudaResourceGuard<'s, T>
impl<'s, T> UnsafeUnpin for CudaResourceGuard<'s, T>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more