copy ( src i dst -- )
Factor handbook > The language > Collections > Sequence operations > Destructive sequence operations

Prev:exchange ( m n seq -- )
Next:When to use destructive operations


Vocabulary
sequences

Inputs and outputs
srca sequence
ian index in dst
dsta mutable sequence


Word description
Copies all elements of src to dst, with destination indices starting from i. Grows dst first if necessary.

Side effects
Modifies dst

Errors
An error is thrown if dst is not resizable, and not large enough to hold the copied elements.

Definition