-
Notifications
You must be signed in to change notification settings - Fork 0
Vec_Clone
manuel villagran edited this page Oct 2, 2019
·
1 revision
Vec_Clone(Vec:vec, bool:readonly = false)
Creates a copy of a vector.
-
Vec:vec
the vector to make a copy of. -
bool:readonly = false
whether the copy should be read-only or not
-
INVALID_VECTOR_ID
if was unable to allocate memory for the vector. - the vector is success.
- Due to the way y_malloc works the clone vector's capacity may not be exactly the same capacity as the original, but will never be lower.
- The cloned vector will only be read-only if the second parameter is
true
doesn't matter if the original is read-only or not.