Dictu icon indicating copy to clipboard operation
Dictu copied to clipboard

[CLEANUP] Uses of `valueToString` and such use default malloc and free

Open Jason2605 opened this issue 4 years ago • 0 comments

Is there an existing issue for this?

  • [X] I have searched the existing issues

Is your feature request related to a problem?

Uses of valueToString and such use default malloc and free, it would be much better if it was handled via the macros provided within https://github.com/dictu-lang/Dictu/blob/develop/src/vm/memory.h

This means if we ever need to swap allocator at some point in the future, it's all handled in a single place. It also means that the GC isn't running when it potentially should be as this is happening outside the realm of the memory watermark.

Describe the solution you'd like

No uses of malloc / realloc / free within the project, all handled through the macros.

Describe alternatives you've considered

No response

Additional context

No response

Jason2605 avatar Oct 20 '21 22:10 Jason2605