MCPcopy Create free account
hub / github.com/SoftbearStudios/bitcode / into_allocation

Method into_allocation

src/fast.rs:350–353  ·  view source on GitHub ↗

Converts a [`CowSlice`] into its internal allocation. The [`Vec `] is empty.

(mut self)

Source from the content-addressed store, hash-verified

348
349 /// Converts a [`CowSlice`] into its internal allocation. The [`Vec<T>`] is empty.
350 pub fn into_allocation(mut self) -> Vec<T> {
351 self.vec.clear();
352 self.vec
353 }
354
355 /// References the inner [`SliceImpl`] as a `[T]`.
356 /// Safety: `len` must be equal to the slices original len.

Callers

nothing calls this directly

Calls 1

clearMethod · 0.80

Tested by

no test coverage detected