8000 Iterator helpers missing · Issue #1684 · facebook/hermes · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Iterator helpers missing #1684

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
2 tasks done
dlindenkreuz opened this issue Apr 23, 2025 · 1 comment
Open
2 tasks done

Iterator helpers missing #1684

dlindenkreuz opened this issue Apr 23, 2025 · 1 comment
Labels
enhancement New feature or request

Comments

@dlindenkreuz
Copy link
Contributor

Bug Description

Iterator Helpers have been added to WebKit / JSC recently. They are available in Safari >= 18.4. Hermes does not support them yet.

I ran into this by accident because TypeScript's ECMA support already suggests helper methods on iterators.

  • I have run gradle clean and confirmed this bug does not occur with JSC
  • The issue is reproducible with the latest version of React Native.

Hermes git revision (if applicable): rn/0.79-stable
React Native version: 0.79
OS: macOS 14.7.2
Platform (most likely one of arm64-v8a, armeabi-v7a, x86, x86_64): arm64

Steps To Reproduce

One-liner:

new Map([["a", 1], ["b", 2]]).values().map(v => v * 2)
// Uncaught TypeError: new Map([["a", 1], ["b", 2]]).values().map is not a function (it is undefined)

The Expected Behavior

Should not throw and instead return a new iterator. The code above works in Safari 18.4 console.

@dlindenkreuz dlindenkreuz added the bug Something isn't working label Apr 23, 2025
@avp
Copy link
Contributor
avp commented Apr 23, 2025

Thanks for the report, we're working on implementing this feature.

@avp avp added enhancement New feature or request and removed bug Something isn't working labels Apr 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants
0