MCPcopy Create free account
hub / github.com/nodejs/node / wrapInEagerFunction

Function wrapInEagerFunction

deps/v8/test/mjsunit/call-lhs-web-compat-early-errors.js:13–17  ·  view source on GitHub ↗
(s)

Source from the content-addressed store, hash-verified

11}
12
13function wrapInEagerFunction(s) {
14 // Use an async function, since some tests use the await keyword. Await the
15 // result, so that we get the error right away.
16 return "await (async function test() { " + s + "})();";
17}
18
19function assertEarlyError(s) {
20 assertThrows(wrapInLazyFunction(s), SyntaxError);

Callers 1

assertLateErrorFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected