Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ PRs still in flight. Every row has a patch in `packages/` you can drop into your

| Package | Version | Fix | PR |
| :--- | :--- | :--- | :--- |
| [`hermes`](packages/hermes/) | n/a | Cherry-pick `18a9634659` onto the `250829098.0.0-stable` branch React Native 0.85 ships. `genObjectExpr` passed `nullptr` as the home object when generating an object-literal getter or setter, so `super.x` inside an accessor compiled against a null home object and SIGSEGV'd `hermesc` at compile time. Makes accessors consistent with the regular-method path, which already passes `capturedObj`. Source fix for one of the three Hermes V1 codegen bugs `babel-preset-expo` works around ([expo/expo#45601](https://github.com/expo/expo/pull/45601)). Root cause [facebook/hermes#1761](https://github.com/facebook/hermes/issues/1761). | [facebook/hermes#2045](https://github.com/facebook/hermes/pull/2045) |
| [`react-native`](packages/react-native/) | `0.85.3` | Set `:always_out_of_date => "1"` on `hermes-engine.podspec`'s `[Hermes] Replace Hermes for the right configuration, if needed` script_phase. The phase had no declared outputs (overwrites the prebuilt Hermes binary in place per `$CONFIGURATION`), so Xcode 14+ was warning about it on every clean build of every project on the default prebuilt-release-tarball Hermes path. Matches the family pattern from `React-Core-prebuilt.podspec` ([#52133](https://github.com/facebook/react-native/pull/52133)) and `ReactNativeDependencies.podspec` ([#49812](https://github.com/facebook/react-native/pull/49812)). | [facebook/react-native#56912](https://github.com/facebook/react-native/pull/56912) |
| [`bun`](packages/oven-sh/bun/) | `1.3.14` | Drop the order-dependent peer-dep early-match block from `get_or_put_resolved_package` so `bun.lock` stops varying run to run. The block bound peers to whichever same-name resolution `package_index` held first, and `package_index` fills in thread-pool-completion order. Dedup and the "incorrect peer dependency" warning move into `Tree::hoist_dependency` where placement is deterministic. Rust port of Dylan's [#29804](https://github.com/oven-sh/bun/pull/29804). | [oven-sh/bun#30855](https://github.com/oven-sh/bun/pull/30855) |
| [`@convex-dev/better-auth`](packages/@convex-dev/better-auth/) | `0.12.2` | Wrap `fetchAccessToken` in `new Promise()` so `useConvexAuth().isAuthenticated` flips after sign-in on Hermes V1. The Expo SDK 56 canary dropped `@babel/plugin-transform-async-to-generator` from its Hermes V1 preset ([expo/expo#45345](https://github.com/expo/expo/pull/45345)), exposing a bridge race the transform's extra tick was hiding. Babel-layer root fix in [facebook/react-native#56816](https://github.com/facebook/react-native/pull/56816). | [get-convex/better-auth#368](https://github.com/get-convex/better-auth/pull/368) |
Expand Down
46 changes: 46 additions & 0 deletions packages/hermes/hermes-pr2045.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
diff --git a/lib/IRGen/ESTreeIRGen-expr.cpp b/lib/IRGen/ESTreeIRGen-expr.cpp
index 073cb38e5a0..4d27ac94007 100644
--- a/lib/IRGen/ESTreeIRGen-expr.cpp
+++ b/lib/IRGen/ESTreeIRGen-expr.cpp
@@ -1634,7 +1634,7 @@ Value *ESTreeIRGen::genObjectExpr(ESTree::ObjectExpressionNode *Expr) {
Builder.createIdentifier("get " + keyStr.str()),
/* superClassNode */ nullptr,
Function::DefinitionKind::ES5Function,
- /* homeObject */ nullptr,
+ /* homeObject */ capturedObj,
/* parentNode */ propValue->getterProp);
}

@@ -1645,7 +1645,7 @@ Value *ESTreeIRGen::genObjectExpr(ESTree::ObjectExpressionNode *Expr) {
Builder.createIdentifier("set " + keyStr.str()),
/* superClassNode */ nullptr,
Function::DefinitionKind::ES5Function,
- /* homeObject */ nullptr,
+ /* homeObject */ capturedObj,
/* parentNode */ propValue->setterProp);
}

diff --git a/test/hermes/object-literal-getter-super.js b/test/hermes/object-literal-getter-super.js
index 5ba94c9a0ba..846fd684f51 100644
--- a/test/hermes/object-literal-getter-super.js
+++ b/test/hermes/object-literal-getter-super.js
@@ -20,3 +20,19 @@ var object = {
Object.setPrototypeOf(object, proto);
print(object.a);
// CHECK: a proto m
+
+// Test that accessors without computed names can also refer to super.
+(function () {
+ let v1 = {
+ get a() {
+ let x = super.m;
+ print(x);
+ }
+ }
+ let parent = { m: 12 };
+ v1.a;
+// CHECK-NEXT: undefined
+ Object.setPrototypeOf(v1, parent);
+ v1.a;
+// CHECK-NEXT: 12
+})();