Tour of Rust Table of Contents

Scope-Based Resource Management

Rust uses the last place of usage or end of function scope as the place to deconstruct and deallocate a resource.

The term for this deconstruction and deallocation is called a drop.

Memory detail: