pin_project_internal::pin_project::derive

Function make_drop_impl

source
fn make_drop_impl(cx: &Context<'_>) -> TokenStream
Expand description

Creates Drop implementation for the original type.

The kind of Drop impl generated depends on pinned_drop field:

  • Some - implements Drop via PinnedDrop impl.
  • None - generates code that ensures that Drop trait is not implemented, instead of generating Drop impl.