VecInitClone
- Macro
- October 8, 2025
Table of Contents
VecInitClone
VecInitClone
Description
Initialize clone of vector from vs
to vd
.
Note
Ownership trasfer takes place if vector is not creating it’s own copy of item.
Parameters
Name | Direction | Description |
---|---|---|
vd | out | Destination vector to create clone into |
vs | in | Source vector to create clone using. |
Success
vd
Failure
Does not return on failure
Usage example (Cross-references)
- In
VecInt.c:390
:
}
VecInitClone(vec, &temp);
VecDeinit(&temp); // Clean up temp to prevent memory leak
break;
- In
VecStr.c:419
:
}
VecInitClone(vec, &temp);
VecDeinit(&temp);
}
- In
VecCharPtr.c:457
:
}
VecInitClone(vec, &temp);
VecDeinit(&temp);
}