MCPcopy Create free account
hub / github.com/Rust-GPU/rust-cuda / into_array

Method into_array

crates/cust/src/surface.rs:66–72  ·  view source on GitHub ↗
(mut self)

Source from the content-addressed store, hash-verified

64 }
65
66 pub fn into_array(mut self) -> CudaResult<Option<ArrayObject>> {
67 let desc = unsafe { ManuallyDrop::take(&mut self.resource_desc()?) };
68 self._destroy_array_on_drop = false;
69 Ok(match desc.ty {
70 ResourceType::Array { array } => Some(array),
71 })
72 }
73
74 // see Texture::resource_desc on why this is unsafe and private and returns a manuallydrop
75 unsafe fn resource_desc(&mut self) -> CudaResult<ManuallyDrop<ResourceDescriptor>> {

Callers 2

mainFunction · 0.45
__raygen__renderFunction · 0.45

Calls 1

resource_descMethod · 0.45

Tested by

no test coverage detected