fix(runtime): inherit Object prototype on class instances - #8780
fix(runtime): inherit Object prototype on class instances#8780proggeramlug wants to merge 2 commits into
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
Included review availability: Your plan provides up to 8 included reviews per hour; 4 remain after this review. 📝 WalkthroughWalkthroughThe runtime now permits registered ES class instances to read inherited ChangesClass instance prototype resolution
Estimated code review effort: 2 (Simple) | ~10 minutes Merge Risk: ⚪ Minimal · up to This localized runtime change restores inherited Object.prototype behavior for registered class instances while preserving existing paths for other class IDs. The listed validation passes, and no actionable merge-blocking risk remains beyond normal checks and review. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches 💡 1📝 Generate docstrings 💡
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Lands #8780. A registered ES class instance whose class methods and accessors all missed was excluded from the ordinary Object.prototype read fallback, so inherited reads -- `String(new C())` among them -- failed. Declared class instances do end their implicit prototype chain at Object.prototype, and their own methods are consulted before this fallback runs, so a miss must stay eligible. The exclusion now also requires the class id to be unregistered, keeping native and synthetic class ids on their existing intrinsic prototype paths. No version bump. Co-authored-by: Ralph Küpper <ralph@skelpo.com>
|
Landed on Validated on the merged result: all 30 lint checkers, runtime 2674/0 at |
Summary
Validation
Summary by CodeRabbit
Bug Fixes
Object.prototypeproperty access for declared class instances.toStringandvalueOfbehavior.Documentation