Skip to content
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

GetSubstitution replace-with-capture-index behavior diverges from major implementations #228

Open
gibson042 opened this issue Oct 3, 2023 · 0 comments

Comments

@gibson042
Copy link
Contributor

gibson042 commented Oct 3, 2023

The lack of single-digit fallback for nonexistent capture indices will be nonconforming when tc39/ecma262#3157 is merged.

cf. tc39/test262#3931 (comment)

$ eshost -se '"foo-x-bar".replace(/(x)/, "|$10|")'
#### ChakraCore, GraalJS, Hermes, JavaScriptCore, Moddable XS, QuickJS, SpiderMonkey, V8
foo-|x0|-bar

#### engine262
foo-|$10|-bar
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant