Destructor

A destructor is a function that is run when a value is destroyed. Destructors are often used to free resources (e.g. heap memory) that are no longer required when a value is destroyed.

In Rust, destructors are defined by implementing the trait.

Example
TODO

Use cases
TODO

Impact on non-lexical lifetimes
TODO