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

Function node_exception_flags

tools/shared.py:326–334  ·  view source on GitHub ↗
(nodejs)

Source from the content-addressed store, hash-verified

324
325
326def node_exception_flags(nodejs):
327 node_version = get_node_version(nodejs)
328 # Legacy exception handling was enabled by default in node v17.
329 if node_version and node_version < (17, 0, 0):
330 return ['--experimental-wasm-eh']
331 # Standard exception handling was supported behind flag in node v22.
332 if node_version and node_version >= (22, 0, 0) and not settings.WASM_LEGACY_EXCEPTIONS:
333 return ['--experimental-wasm-exnref']
334 return []
335
336
337@memoize

Callers

nothing calls this directly

Calls 1

get_node_versionFunction · 0.85

Tested by

no test coverage detected