eval/inject improved; testing won t fail on non existing javascript engine

This commit is contained in:
2026-05-28 00:07:21 +02:00
parent 8fe47a7ed4
commit e89ab88670
6 changed files with 185 additions and 66 deletions
+10 -4
View File
@@ -54,8 +54,10 @@ The test framework looks for JavaScript engines such as `node`, `deno`,
or when `JSMAKER_BROWSER_FALLBACK=1` is set.
When no JavaScript engine is available, the tests generate the JavaScript test
files and print warnings, but do not fail unless `JSMAKER_REQUIRE_ENGINE` or
`JSMAKER_REQUIRE_NODE` is set.
files and use an explicit `non-failing-javascript-stub`. The stub prints notes
to stdout, does not execute the generated JavaScript, and succeeds unless
`JSMAKER_REQUIRE_ENGINE` or `JSMAKER_REQUIRE_NODE` is set. This avoids package
server failures caused solely by a missing JavaScript runtime.
Useful environment variables:
@@ -105,8 +107,12 @@ Belangrijk:
This build includes the `with-handlers` callee-position fix for inline lambda
handlers, including rest-argument handlers such as `(lambda args ...)`. It also
adds a Racket-like division-by-zero runtime check for `/`, so the generic
`exn?` handler subset can catch `(/ 10 0)`.
fixes top-level `js` statement-context handling for `with-handlers`, so a
side-effecting catch handler does not prematurely return from the surrounding
JavaScript wrapper. Use `js/expression` when the value of a `with-handlers`
form itself is needed. The build also adds a Racket-like division-by-zero
runtime check for `/`, so the generic `exn?` handler subset can catch
`(/ 10 0)`.
## JavaScript use case demos