Quellcodebibliothek Statistik Leitseite products/Sources/formale Sprachen/C/Firefox/js/src/jit-test/tests/debug/   (Browser von der Mozilla Stiftung Version 136.0.1©)  Datei vom 10.2.2025 mit Größe 804 B image not shown  

Quelle  Frame-older-02.js   Sprache: JAVA

 
// An explicit async stack should interrupt a Debugger.Frame chain.

var g = newGlobal({ newCompartment: true });
var dbg = new Debugger(g);
let done = false;
dbg.onDebuggerStatement = function (frame) {
  // The frame has no "older" frame because the explicit async stack
  // attached to the async function takes priority over the real
  // parent frame that is tracked in the frame iterator.
  assertEq(!!frame.older, false);

  done = true;
};

g.eval(`
let draining = false;
async function run() {
  await Promise.resolve();

  // Make sure that the test is running within "drainJobQueue()".
  assertEq(draining, true);
  debugger;
}

(function main() {
  run();

  // Force resumption of the "run" function.
  draining = true;
  drainJobQueue();
  draining = false;
})();
`);
assertEq(done, true);

Messung V0.5
C=83 H=100 G=91

¤ Dauer der Verarbeitung: 0.0 Sekunden  (vorverarbeitet)  ¤

*© Formatika GbR, Deutschland






Wurzel

Suchen

Beweissystem der NASA

Beweissystem Isabelle

NIST Cobol Testsuite

Cephes Mathematical Library

Wiener Entwicklungsmethode

Haftungshinweis

Die Informationen auf dieser Webseite wurden nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit, noch Qualität der bereit gestellten Informationen zugesichert.

Bemerkung:

Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.