Skip to content

Stop holding runtime ptr in turbomodule provider#54972

Closed
RSNara wants to merge 3 commits into
react:mainfrom
RSNara:export-D89751220
Closed

Stop holding runtime ptr in turbomodule provider#54972
RSNara wants to merge 3 commits into
react:mainfrom
RSNara:export-D89751220

Conversation

@RSNara

@RSNara RSNara commented Dec 24, 2025

Copy link
Copy Markdown
Contributor

Summary:
Holding a reference to the runtime is unsafe. Let's just use the reference provided to the turbomodule binding instead.

Changelog: [Internal]

Differential Revision: D89751220

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. label Dec 24, 2025
@meta-codesync

meta-codesync Bot commented Dec 24, 2025

Copy link
Copy Markdown

@RSNara has exported this pull request. If you are a Meta employee, you can view the originating Diff in D89751220.

Summary:
The TurboModuleBinding constructor actually doesn't need to be public! It's only called from BridgelessTurboModuleProxy or TurboModuleBinding::install.

Changelog: [General][Breaking] Make the TurboModuleBinding constructor private.

Reviewed By: christophpurrer

Differential Revision: D89751218
Summary:
Holding a reference to the runtime is discouraged. Let's just use the reference provided to the turbomodule binding instead.

Changelog: [General][Deprecated] Deprecate TurboModuleProviderFunctionType

Reviewed By: christophpurrer

Differential Revision: D89751220
@react-native-bot

Copy link
Copy Markdown
Collaborator

Closing as this has been merged in 7a6a6ae

@react-native-bot react-native-bot added the Merged This PR has been merged. label Jun 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Facebook bot. Authors need to sign the CLA before a PR can be reviewed. fb-exported Merged This PR has been merged. meta-exported p: Facebook Partner: Facebook Partner

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants