My understanding about WASM is some things are not specc'ed out fully, so some things don't necessarily line up 100% and is up to implementation specifics or to be interpreted differently, you could have access to functions and such, but you'd have to ensure both implementations line up with the same understandings of returned types like strings involve some tricks that might not be 1:1 between languages compiled to WASM iirc.
Not saying it can't be done, just there might be nuance. I could be wrong though, its been a year or two since I ran through the WASM bytecode spec.