Skip to content

Commit 694f9d7

Browse files
RSNarafacebook-github-bot
authored andcommitted
[skip ci] Noop: ReactInstance: Add todo above getRuntimeScheduler() (facebook#43952)
Summary: getRuntimeScheduler() allows things to schedule work on the js thread by bypassing main bundle buffering. This is unsafe: almost everything should be using the buffered runtime executor, unless it sets up bindings used in the main bundle. I filed a task for the investigation to see if there's any problems. And added it to the code in this diff. Changelog: [Internal] Reviewed By: cipolleschi Differential Revision: D55547899
1 parent 3422dcf commit 694f9d7

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

packages/react-native/ReactCommon/react/runtime/ReactInstance.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,8 @@ RuntimeExecutor ReactInstance::getBufferedRuntimeExecutor() noexcept {
163163
};
164164
}
165165

166+
// TODO(T184010230): Should the RuntimeScheduler returned from this method be
167+
// buffered?
166168
std::shared_ptr<RuntimeScheduler>
167169
ReactInstance::getRuntimeScheduler() noexcept {
168170
return runtimeScheduler_;

0 commit comments

Comments
 (0)