Closed
Description
Great project!
What do you think about adding a feature flag that causes this crate to implement the libc malloc API (i.e. extern "C"
malloc
, realloc
, calloc
, free
, and maybe posix_memalign
) for linked C/C++ code to consume?
I have a mixed Rust/C project that I'm compiling to Wasm. I need a malloc
implementation, because I'd like to use wasm32-unknown-unknown
and not Emscripten, so that I can use wasm-bindgen
. Also, to reduce the binary size, I'd like for my Rust and C code to share the same allocator.
I've hacked this in locally, so if you're in favor of it, I'd be up for submitting a PR.
Metadata
Metadata
Assignees
Labels
No labels