# Trait std::ops::InPlace [−] [src]

    pub trait InPlace<Data>: Place<Data> where
        Data: ?Sized, {
        type Owner;
        unsafe fn finalize(self) -> Self::Owner;
    }

🔬 This is a nightly-only experimental API. (`placement_new_protocol` #27779)

Specialization of `Place` trait supporting `PLACE <- EXPR`.

## Associated Types

### `type Owner`

🔬 This is a nightly-only experimental API. (`placement_new_protocol` #27779)

`Owner` is the type of the end value of `PLACE <- EXPR`

Note that when `PLACE <- EXPR` is solely used for side-effecting an existing data-structure, e.g. `Vec::emplace_back`, then `Owner` need not carry any information at all (e.g. it can be the unit type `()` in that case).

## Required Methods

### `unsafe fn finalize(self) -> Self::Owner`

🔬 This is a nightly-only experimental API. (`placement_new_protocol` #27779)

Converts self into the final value, shifting deallocation/cleanup responsibilities (if any remain), over to the returned instance of `Owner` and forgetting self.

## Implementors

- [src]
  `impl<'a, T> InPlace<T> for BinaryHeapPlace<'a, T> where
  T: Clone + Ord, type Owner = &'a T;`
- [src]
  `impl<T> InPlace<T> for IntermediateBox<T> type Owner = Box<T>;`
- [src]
  `impl<'a, T> InPlace<T> for std::vec::PlaceBack<'a, T> type Owner = &'a mut T;`
- [src]
  `impl<'a, T> InPlace<T> for FrontPlace<'a, T> type Owner = ();`
- [src]
  `impl<'a, T> InPlace<T> for BackPlace<'a, T> type Owner = ();`
- [src]
  `impl<'a, T> InPlace<T> for std::collections::vec_deque::PlaceBack<'a, T> type Owner = &'a mut T;`
- [src]
  `impl<'a, T> InPlace<T> for PlaceFront<'a, T> type Owner = &'a mut T;`
- [src]
  `impl<'a, K, V> InPlace<V> for EntryPlace<'a, K, V> type Owner = ();`

# Help

## Keyboard Shortcuts

?
  Show this help dialog
S
  Focus the search field
↑
  Move up in search results
↓
  Move down in search results
↹
  Switch tab
⏎
  Go to active search result
+ / -
  Collapse/expand all sections

## Search Tricks

Prefix searches with a type followed by a colon (e.g. `fn:`) to restrict the search to a given type.

Accepted types are: `fn`, `mod`, `struct`, `enum`, `trait`, `type`, `macro`, and `const`.

Search functions by type signature (e.g. `vec -> usize` or `* -> vec`)