From 69327f5e72c3bec5858815ef788a4fcf46ed82c9 Mon Sep 17 00:00:00 2001 From: JungMinu Date: Tue, 21 Feb 2017 13:14:28 +0900 Subject: [PATCH] lib: rename kMaxCallbacksUntilQueueIsShortened PR-URL: https://github.com/nodejs/node/pull/11473 Ref: https://github.com/nodejs/node/pull/11199#issuecomment-281184439 Reviewed-By: Daniel Bevenius Reviewed-By: James M Snell Reviewed-By: Colin Ihrig --- lib/internal/process/next_tick.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/internal/process/next_tick.js b/lib/internal/process/next_tick.js index bc89c6e8b269e3..ad635aaf494b33 100644 --- a/lib/internal/process/next_tick.js +++ b/lib/internal/process/next_tick.js @@ -4,7 +4,7 @@ // large and cause the process to run out of memory. When this value // is reached the nextTimeQueue array will be shortend (see tickDone // for details). -const kMaxCallbacksUntilQueueIsShortened = 1e4; +const kMaxCallbacksPerLoop = 1e4; exports.setup = setupNextTick; @@ -102,7 +102,7 @@ function setupNextTick() { // callback invocation with small numbers of arguments to avoid the // performance hit associated with using `fn.apply()` _combinedTickCallback(args, callback); - if (kMaxCallbacksUntilQueueIsShortened < tickInfo[kIndex]) + if (kMaxCallbacksPerLoop < tickInfo[kIndex]) tickDone(); } tickDone(); @@ -126,7 +126,7 @@ function setupNextTick() { // callback invocation with small numbers of arguments to avoid the // performance hit associated with using `fn.apply()` _combinedTickCallback(args, callback); - if (kMaxCallbacksUntilQueueIsShortened < tickInfo[kIndex]) + if (kMaxCallbacksPerLoop < tickInfo[kIndex]) tickDone(); if (domain) domain.exit();