Skip to content

docs for Drop do not explain drop protocol #30655

@durka

Description

@durka

For example,

  • that the struct being dropped has not been deallocated when drop() is called (it's implied by the existence of &mut self and Rust's general reluctance to dangle pointers, but still...),
  • and that the struct members are recursively dropped after drop() finishes,
  • and what happens if drop() panics.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions