Skip to content

Glossary: Rust Beyond the Basics

Clone

Also written: .clone(), clone

A trait that gives a type a `.clone()` method to make a copy of a value. Deriving `Clone` requires every field to be cloneable.

Where the book teaches it

Related terms

Copyderive