mirror of
https://github.com/facebook/react-native.git
synced 2026-11-18 20:19:07 +00:00
Easy: Update IEventLoopControl::scheduleTask doc comment (#58580)
Summary: Pull Request resolved: https://github.com/react/react-native/pull/58580 Make it clear that the integrator needs to guarantee the Runtime is alive when running task. Changelog: [Internal] Reviewed By: micleo2 Differential Revision: D120562343 fbshipit-source-id: 13adb048a9ed11c96e733b3d680303801b7a1423
This commit is contained in:
1 parent
3718f624d4
commit
ea9e4832ad
1 file changed
+2
-2
@@ -35,8 +35,8 @@ class Debugger;
|
||||
struct IEventLoopControl {
|
||||
/// `scheduleTask` is a function used by the caller (the Runtime) to schedule
|
||||
/// some \p task. The scheduled task may perform VM operations. Thus, the
|
||||
/// integrator must only run the tasks when it had exclusive access to the
|
||||
/// Runtime.
|
||||
/// integrator must only run the tasks when the Runtime is alive and it has
|
||||
/// exclusive access to it.
|
||||
virtual void scheduleTask(const std::function<void()>& task) = 0;
|
||||
/// Used by the caller (the Runtime) to register a new source that can
|
||||
/// schedule new work via `scheduleTask`. This method return an uint64
|
||||
|
||||
Reference in new issue
Block a user