Closed ErikMcClure closed 1 year ago
Currently I'm looking at writing an additional function into the /src/gen_llvm.cpp file.
This function will be using the LLVM API --> LLVMTargetMachineEmitToMemoryBuffer defined here.
I will need to figure out exactly how to link this to the runtime of scopes but there should be enough information in the source files that I can figure it out.
See 46b10637b7beea809c5bd84f783ed32de0cf471f for specifics of current implementation. Moving to testing soon.
Technically resolves but I'd like to open another issue to make this function more generic. After a better understanding the language's internals I believe this can simply be: compile-object-buffer. Either way I am comfortable with this being resolved after review.
It would be useful if the compilation step allowed outputing the result of compiling WASM to a memory buffer instead of directly to a file.