3.9 Copy and move
- Copy types: primitives,
str,bytes,Duration,Timeand other time types,distinct/refined types over a Copy type, tuples and arrays of Copy types, anddata/enumwith@derive(Copy)all of whose fields are Copy. - Other values are moved on assignment, on passing to a function and on return. Use after move is a compile error.
- An explicit copy is
x.clone()(interfaceClone).
Related diagnostics
See also
Source: docs/spec/oxl-standard.en.md