[][src]Function cosmwasm::memory::consume_slice

pub unsafe fn consume_slice(ptr: *mut c_void) -> Result<Vec<u8>, Error>

consume_slice will return the data referenced by the slice and deallocates the slice (and the vector when finished). Warning: only use this when you are sure the caller will never use (or free) the slice later