diff options
Diffstat (limited to 'compiler/nim.nim')
-rw-r--r-- | compiler/nim.nim | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/compiler/nim.nim b/compiler/nim.nim index 46654e352..5ec891816 100644 --- a/compiler/nim.nim +++ b/compiler/nim.nim @@ -95,9 +95,15 @@ proc handleCmdLine(cache: IdentCache; conf: ConfigRef) = var cmdPrefix = "" case conf.backend of backendC, backendCpp, backendObjc: discard - of backendJs: cmdPrefix = findNodeJs() & " " + of backendJs: + # D20210217T215950:here this flag is needed for node < v15.0.0, otherwise + # tasyncjs_fail` would fail, refs https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode + cmdPrefix = findNodeJs() & " --unhandled-rejections=strict " else: doAssert false, $conf.backend + # No space before command otherwise on windows you'd get a cryptic: + # `The parameter is incorrect` execExternalProgram(conf, cmdPrefix & output.quoteShell & ' ' & conf.arguments) + # execExternalProgram(conf, cmdPrefix & ' ' & output.quoteShell & ' ' & conf.arguments) of cmdDocLike, cmdRst2html, cmdRst2tex: # bugfix(cmdRst2tex was missing) if conf.arguments.len > 0: # reserved for future use |