pub struct HeapStr { /* private fields */ }Expand description
UTF-8 heap buffer charged against a MemoryBudget.
Charge is based on String::capacity, not just len, so growth of the
backing allocation is visible to the budget.
Self::new / Self::replace take an already-built String (via
Into); any allocation performed by the caller happens before the
budget sees it — see the module docs.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for HeapStr
impl RefUnwindSafe for HeapStr
impl Send for HeapStr
impl Sync for HeapStr
impl Unpin for HeapStr
impl UnsafeUnpin for HeapStr
impl UnwindSafe for HeapStr
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more