-
Notifications
You must be signed in to change notification settings - Fork 609
Open
Description
Hi! I am working on targets that don't support the libc.
Wren relies on the following libc functions:
free(used bydefaultReallocate)realloc(used bydefaultReallocate)printf(used only on debug?)clock__errno(I don't know what is using it)_ctype_(I don't know what is using it)abs(used incalculateRange)fabs(theabsfunction of wren)strcmpstrncmpmodfstrtod(used to parse numbers)strtoll(used to parse hex numbers)vsprintfsprintf(used for formatting: only%d,%g,%.14g,%s,%.*s, and%.are used)
It is possible to provide shims for all these functions (except free, realloc, printf, and clock).
I have written such shims for my own usage of wren.
Are you open to add these shims in the Wren repository or even to directly use some of them to reduce the dependency of wren over libc?
Also, it could be nice to have a second function that creates a new VM without defaulting to defaultReallocate. This could remove the dependency over free/realloc.
Thanks!
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels