-
Notifications
You must be signed in to change notification settings - Fork 475
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
Are there tests against legacy magic properties that are nonconfigurable and nonwritable? #649
Comments
Thanks for reporting; that's a very strange bug! I think there's value in including a test for it, but it raises a question about test organization. This isn't the right place to discuss it, so I've opened gh-650 to elaborate. If you have any thoughts on the matter, please let me know! |
It's hard to say, strictly speaking, whether these are spec violations. Is it a prohibited extension to make these objects "exotic" with respect to those properties? (Definitely seems not that great though!) |
@littledan Objects may behave as exotically as they want, as long as they do not violate the essential invariants given in 6.1.7.3. Citing the spec:
Among other things, the integrity of proxies depends on that. |
I've opened gh-653 to address this. |
According to 6.1.7.3
However, as of today, many implementations define some legacy magic properties as nonconfigurable and nonwritable, but keep them changing their value over time, e.g.:
f.arguments
andf.caller
for sloppy functionf
(bug observed in WebKit, V8 and Chakra);RegExp.$1
, etc. (bug observed in WebKit).Are there tests against these cases.
Suggested sample test:
The text was updated successfully, but these errors were encountered: