I don't see why emitDiagnostic should be async, as it's basically calling codespan-reporting's underlying sync function.
In my specific case I wanted to call emitDiagnostic in a js sync function that's being called back from within a wasm sync call:
js ---> call something in wasm and pass a callback to it ---> calls the js callback from within wasm ---> my sync callback can't call emitDiagnostic because it's async.
I don't see why
emitDiagnostic
should be async, as it's basically calling codespan-reporting's underlying sync function. In my specific case I wanted to callemitDiagnostic
in a js sync function that's being called back from within a wasm sync call:js ---> call something in wasm and pass a callback to it ---> calls the js callback from within wasm ---> my sync callback can't call
emitDiagnostic
because it's async.