- flexvector-copy! to at from #!optional start endprocedure
Copies the elements of flexvector from between start and end to flexvector to, starting at at. The order in which elements are copied is unspecified, except that if the source and destination overlap, copying takes place as if the source is first copied into a temporary vector and then into the destination. This can be achieved without allocating storage by making sure to copy in the correct direction in such circumstances. flexvector-reverse-copy! is the same, but copies elements in reverse order. start and end default to 0 and (flexvector-length from) if not present. Both start and end are clamped to the range [0, (flexvector-length from)]. It is an error if end is less than start. Unlike vector-copy!, flexvector-copy! may copy elements past the end of to, which will increase the length of to. flexvector-copy! shares the performance characteristics of vector-copy! — in particular, if a given Scheme's vector-copy! uses a fast memcpy operation instead of an element-by-element loop, flexvector-copy! should also use this operation. Both procedures return to after mutating it.