Skip to content

Commit

Permalink
Back out "RNTester-ios / RCTAppDelegate > correctly check for USE_HER…
Browse files Browse the repository at this point in the history
…MES Flag" (facebook#41626)

Summary:
Pull Request resolved: facebook#41626

In the codebase, we never set the RCT_USE_HERMES flag.

When we install the pods, we use the USE_HERMES flag and we set USE_HERMES as a build setting. So, the RCT_USE_HERMES flag will always be not set for the OSS.

https://pxl.cl/3RRxr

## Changelog:
[iOS][Fixed] - use the right USE_HERMES flag

## Facebook:
This change was incorrect as in OSS we never set the RCT_USE_HERMES flag, while we actually set the USE_HERMES one.

I will align the BUCK RNTester setup in the next diff of the stackog:

Reviewed By: dmytrorykun

Differential Revision: D51547810

fbshipit-source-id: 1da5b3a48a83a8ba49cf65382927bed2f9fc893d
  • Loading branch information
cipolleschi authored and Othinn committed Jan 9, 2024
1 parent 4bac7ba commit 7f95185
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/react-native/Libraries/AppDelegate/RCTAppDelegate.mm
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
#import <React/RCTSurfaceHostingProxyRootView.h>
#import <React/RCTSurfacePresenter.h>
#import <ReactCommon/RCTContextContainerHandling.h>
#if RCT_USE_HERMES
#if USE_HERMES
#import <ReactCommon/RCTHermesInstance.h>
#else
#import <ReactCommon/RCTJscInstance.h>
Expand Down Expand Up @@ -292,7 +292,7 @@ - (void)createReactHost

- (std::shared_ptr<facebook::react::JSRuntimeFactory>)createJSRuntimeFactory
{
#if RCT_USE_HERMES
#if USE_HERMES
return std::make_shared<facebook::react::RCTHermesInstance>(_reactNativeConfig, nullptr);
#else
return std::make_shared<facebook::react::RCTJscInstance>();
Expand Down

0 comments on commit 7f95185

Please sign in to comment.