MCPcopy Create free account
hub / github.com/emscripten-core/emscripten / handleThrow

Function handleThrow

test/emscripten_throw_number_pre.js:1–5  ·  view source on GitHub ↗
(value)

Source from the content-addressed store, hash-verified

1function handleThrow(value) {
2 globalThis.disableErrorReporting = true;
3 var result = value === 42 ? 0 : 1;
4 fetch('/report_result?' + result);
5}
6
7addEventListener('error', (event) => {
8 handleThrow(event.error);

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected