Skip to content

Commit

Permalink
src: update comment for SetImmediate()
Browse files Browse the repository at this point in the history
Refs: #31502 (comment)

PR-URL: #32300
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: David Carlier <[email protected]>
Reviewed-By: James M Snell <[email protected]>
  • Loading branch information
addaleax authored and MylesBorins committed Mar 24, 2020
1 parent 2cb9f7a commit 11650c6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/env.h
Original file line number Diff line number Diff line change
Expand Up @@ -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>
Expand Down

0 comments on commit 11650c6

Please sign in to comment.