Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nodejs/node.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/src/env.h
diff options
context:
space:
mode:
authorAnna Henningsen <anna@addaleax.net>2020-03-16 14:25:21 +0300
committerMyles Borins <mylesborins@google.com>2020-03-24 09:55:13 +0300
commit11650c683eccada148e2f10c02219898c9d375cb (patch)
treebf363559dd322bad14d909f38ed4ee81050e87b2 /src/env.h
parent2cb9f7acb68fe0cdf024234007739c6411262050 (diff)
src: update comment for SetImmediate()
Refs: https://github.com/nodejs/node/pull/31502#issuecomment-599242824 PR-URL: https://github.com/nodejs/node/pull/32300 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: David Carlier <devnexen@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
Diffstat (limited to 'src/env.h')
-rw-r--r--src/env.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/env.h b/src/env.h
index 579d0f547e4..0351af5dea0 100644
--- a/src/env.h
+++ b/src/env.h
@@ -1171,7 +1171,8 @@ class Environment : public MemoryRetainer {
}
// cb will be called as cb(env) on the next event loop iteration.
- // keep_alive will be kept alive between now and after the callback has run.
+ // Unlike the JS setImmediate() function, nested SetImmediate() calls will
+ // be run without returning control to the event loop, similar to nextTick().
template <typename Fn>
inline void SetImmediate(Fn&& cb);
template <typename Fn>