Lines Matching refs:alloc
27 use crate::alloc::Allocator;
29 use crate::alloc::{self, Global};
94 use core::alloc::Allocator;
105 let (b, alloc) = Box::into_raw_with_allocator(b); in into_vec()
106 Vec::from_raw_parts_in(b as *mut T, len, len, alloc) in into_vec()
112 pub fn to_vec<T: ConvertVec, A: Allocator>(s: &[T], alloc: A) -> Vec<T, A> { in to_vec()
113 T::to_vec(s, alloc) in to_vec()
118 fn to_vec<A: Allocator>(s: &[Self], alloc: A) -> Vec<Self, A> in to_vec()
126 default fn to_vec<A: Allocator>(s: &[Self], alloc: A) -> Vec<Self, A> { in to_vec()
141 let mut vec = Vec::with_capacity_in(s.len(), alloc); in to_vec()
163 fn to_vec<A: Allocator>(s: &[Self], alloc: A) -> Vec<Self, A> { in to_vec()
164 let mut v = Vec::with_capacity_in(s.len(), alloc); in to_vec()
438 pub fn to_vec_in<A: Allocator>(&self, alloc: A) -> Vec<T, A> in to_vec_in()
443 hack::to_vec(self, alloc) in to_vec_in()
857 unsafe { alloc::alloc(alloc::Layout::array::<T>(len).unwrap_unchecked()) as *mut T } in stable_sort()
865 alloc::dealloc(buf_ptr as *mut u8, alloc::Layout::array::<T>(len).unwrap_unchecked()); in stable_sort()
873 alloc::alloc(alloc::Layout::array::<sort::TimSortRun>(len).unwrap_unchecked()) in stable_sort()
882 alloc::dealloc( in stable_sort()
884 alloc::Layout::array::<sort::TimSortRun>(len).unwrap_unchecked(), in stable_sort()