Anforderungen  |   Konzepte  |   Entwurf  |   Entwicklung  |   Qualitätssicherung  |   Lebenszyklus  |   Steuerung
 
 
 
 


Quelle  async-livecache.js   Sprache: JAVA

 
// Async stacks should not supplant LiveSavedFrameCache hits.

top();

// An ordinary function, to give the frame a convenient name.
function top() {
  // Perform an async call. F will run in an activation that has an async stack
  // supplied.
  f().catch(catchError);
}

async function f() {
  // Perform an ordinary call. Its parent frame will be a LiveSavedFrameCache
  // hit.
  g();
}

function g() {
  // Populate the LiveSavedFrameCache.
  saveStack();

  // Capturing the stack again should find f (if not g) in the cache. The async
  // stack supplied below the call to f should not supplant f's own frame.
  let frame = saveStack();

  assertEq(frame.functionDisplayName, 'g');
  assertEq(parent(frame).functionDisplayName, 'f');
  assertEq(parent(parent(frame)).functionDisplayName, 'top');
}

// Return the parent of |frame|, skipping self-hosted code and following async
// parent links.
function parent(frame) {
  do {
    frame = frame.parent || frame.asyncParent;
  } while (frame.source.match(/self-hosted/));
  return frame;
}

function catchError(e) {
  print(`${e}\n${e.stack}`);
  quit(1)
}

Messung V0.5
C=94 H=87 G=90

¤ Dauer der Verarbeitung: 0.2 Sekunden  ¤

*© 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.






                                                                                                                                                                                                                                                                                                                                                                                                     


Neuigkeiten

     Aktuelles
     Motto des Tages

Software

     Produkte
     Quellcodebibliothek

Aktivitäten

     Artikel über Sicherheit
     Anleitung zur Aktivierung von SSL

Muße

     Gedichte
     Musik
     Bilder

Jenseits des Üblichen ....
    

Besucherstatistik

Besucherstatistik

Monitoring

Montastic status badge