Vely logo install
examples
documentation

Vely 15.2.0 released on Jan 18, 2023
Articles updated Jan 17, 2023

resize-mem


Issues with this documentation page? Report here.

Purpose:


Resize memory.

Syntax:



resize-mem <memory> size <size>


Description:


resize-mem resize memory <memory> that must have been previously allocated by Vely. Do not use it on memory allocated by any C-library functions (such as malloc(), calloc() or realloc()). If memory cannot be allocated, or if the pointer is not a valid one, the program will error out.

The pointer returned is void* and can be used for any purpose.

Examples:


Allocate and resize memory:

new-mem define mystr size 300
resize-mem mystr size 1000


See also:


Memory ( delete-mem   memory_handling   new-mem   resize-mem  )  SEE ALL (documentation)



Copyright (c) 2022 DaSoftver LLC. Vely is a trademark of Dasoftver LLC. The software and information herein are provided "AS IS" and without any warranties or guarantees of any kind. Vely elephant logo (c) 2022 DaSoftver LLC. This web page is licensed under CC-BY-SA-4.0.