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

RegExp valueOf returns a string instead of object #15517

Open
evilpie opened this issue Mar 10, 2024 · 0 comments · May be fixed by #18995
Open

RegExp valueOf returns a string instead of object #15517

evilpie opened this issue Mar 10, 2024 · 0 comments · May be fixed by #18995
Labels
A-avm2 Area: AVM2 (ActionScript 3) bug Something isn't working

Comments

@evilpie
Copy link
Collaborator

evilpie commented Mar 10, 2024

RegExp.prototype.valueOf currently returns a string (similar to toString) instead of returning the RegExp object. Actually I think we need to add an actual RegExp.prototype.valueOf method, instead of just implementing the value_of method of the TObject trait.

Testcase: typeof /abc/.valueOf()

@evilpie evilpie added bug Something isn't working A-avm2 Area: AVM2 (ActionScript 3) labels Mar 10, 2024
@Lord-McSweeney Lord-McSweeney linked a pull request Dec 29, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-avm2 Area: AVM2 (ActionScript 3) bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant