title: Emscripten malloc and free across JS and C++
body: <p>Suppose I allocate some memory M in Javascript via Emscripten <code>_malloc</code> (Javascript). Am I allowed to pass ownership of M into a marshaled C++ function that calls <code>free</code> (C++) on it?</p>