Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions crates/cust/src/module.rs
Original file line number Diff line number Diff line change
Expand Up @@ -418,6 +418,12 @@ impl Module {
}
}

// Get the inner `CUmodule` from the `Module`. If you use this handle elsewhere,
// make sure not to use it after the module has been dropped. Or ManuallyDrop the struct to be safe.
pub fn as_inner(&self) -> driver_sys::CUmodule {
self.inner
}

/// Destroy a `Module`, returning an error.
///
/// Destroying a module can return errors from previous asynchronous work. This function
Expand Down
Loading