rm TODO comment about integrating detectLateRejectionHandling with clearStack
In theory, resetting clearStack's inline call count every time late rejection handling does a setTimeout should reduce the performance penalty in some environments. In practice, it doesn't: * In Chrome and FF, late rejection handling has no measurable penalty. * In Safari, resetting the inline call count actually slows things down considerably(!). * In Node, clearStack doesn't use setTimeout so there is no benefit.
This commit is contained in:
@@ -11614,7 +11614,6 @@ getJasmineRequireObj().TreeRunner = function(j$) {
|
||||
return {
|
||||
fn: done => {
|
||||
// setTimeout is necessary to trigger rejectionhandled events
|
||||
// TODO: let clearStack know about this so it doesn't do redundant setTimeouts
|
||||
this.#setTimeout(function() {
|
||||
globalErrors.reportUnhandledRejections();
|
||||
done();
|
||||
|
||||
@@ -192,7 +192,6 @@ getJasmineRequireObj().TreeRunner = function(j$) {
|
||||
return {
|
||||
fn: done => {
|
||||
// setTimeout is necessary to trigger rejectionhandled events
|
||||
// TODO: let clearStack know about this so it doesn't do redundant setTimeouts
|
||||
this.#setTimeout(function() {
|
||||
globalErrors.reportUnhandledRejections();
|
||||
done();
|
||||
|
||||
Reference in New Issue
Block a user