-
Notifications
You must be signed in to change notification settings - Fork 1.2k
OS#14101048: For all built-in functions, func.hasOwnProperty('caller'|'arguments') === false #4639
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
Conversation
…ned in JsBuiltInEngineInterfaceExtensionObject.cpp
…uments') === false
|
Can't user code define a property named 'caller' or 'arguments' on a library function?
Is that only in sloppy mode? |
|
@boingoing yes, that is supposed to be allowed. I'm trying to figure out a way to detect that a caller/arguments property has been overwritten or otherwise decide that this regression is worth the fix. |
…l is enabled before testing Intl builtins
64e033f to
e9ed67e
Compare
|
I'm working on a more complete fix for this. Will update soon. |
|
Closing in favor of a new PR with a more complete fix. |
|
See #4651 |
…ould not have caller/arguments (and related fixes) Merge pull request #4651 from dilijev:func-restricted-props Replaces #4639 Several tests and test baselines needed to be updated to reflect the change in behavior. This change improves caller/arguments behavior without regressing any previous Chakra behavior. Chakra still differs from the spec and other engines on some aspects of caller/arguments. See: https://tc39.github.io/ecma262/#sec-forbidden-extensions Fixes #249 Fixes OS#14101048 --- Test262 results strictly improved. Using test262 commit tc39/test262@03da228: Previously 44130 passed, now 44138 passed out of 57102. (Duplicates below are strict and non-strict versions of the tests.) ``` +PASS e:/dd/test262/test262/test/built-ins/Function/prototype/restricted-property-arguments.js +PASS e:/dd/test262/test262/test/built-ins/Function/prototype/restricted-property-arguments.js +PASS e:/dd/test262/test262/test/built-ins/Function/prototype/restricted-property-caller.js +PASS e:/dd/test262/test262/test/built-ins/Function/prototype/restricted-property-caller.js +PASS e:/dd/test262/test262/test/built-ins/ThrowTypeError/forbidden-arguments.js +PASS e:/dd/test262/test262/test/built-ins/ThrowTypeError/forbidden-arguments.js +PASS e:/dd/test262/test262/test/built-ins/ThrowTypeError/forbidden-caller.js +PASS e:/dd/test262/test262/test/built-ins/ThrowTypeError/forbidden-caller.js ```
…nctions should not have caller/arguments (and related fixes) Merge pull request #4651 from dilijev:func-restricted-props Replaces #4639 Several tests and test baselines needed to be updated to reflect the change in behavior. This change improves caller/arguments behavior without regressing any previous Chakra behavior. Chakra still differs from the spec and other engines on some aspects of caller/arguments. See: https://tc39.github.io/ecma262/#sec-forbidden-extensions Fixes #249 Fixes OS#14101048 --- Test262 results strictly improved. Using test262 commit tc39/test262@03da228: Previously 44130 passed, now 44138 passed out of 57102. (Duplicates below are strict and non-strict versions of the tests.) ``` +PASS e:/dd/test262/test262/test/built-ins/Function/prototype/restricted-property-arguments.js +PASS e:/dd/test262/test262/test/built-ins/Function/prototype/restricted-property-arguments.js +PASS e:/dd/test262/test262/test/built-ins/Function/prototype/restricted-property-caller.js +PASS e:/dd/test262/test262/test/built-ins/Function/prototype/restricted-property-caller.js +PASS e:/dd/test262/test262/test/built-ins/ThrowTypeError/forbidden-arguments.js +PASS e:/dd/test262/test262/test/built-ins/ThrowTypeError/forbidden-arguments.js +PASS e:/dd/test262/test262/test/built-ins/ThrowTypeError/forbidden-caller.js +PASS e:/dd/test262/test262/test/built-ins/ThrowTypeError/forbidden-caller.js ```
… built-in functions should not have caller/arguments (and related fixes) Merge pull request #4651 from dilijev:func-restricted-props Replaces #4639 Several tests and test baselines needed to be updated to reflect the change in behavior. This change improves caller/arguments behavior without regressing any previous Chakra behavior. Chakra still differs from the spec and other engines on some aspects of caller/arguments. See: https://tc39.github.io/ecma262/#sec-forbidden-extensions Fixes #249 Fixes OS#14101048 --- Test262 results strictly improved. Using test262 commit tc39/test262@03da228: Previously 44130 passed, now 44138 passed out of 57102. (Duplicates below are strict and non-strict versions of the tests.) ``` +PASS e:/dd/test262/test262/test/built-ins/Function/prototype/restricted-property-arguments.js +PASS e:/dd/test262/test262/test/built-ins/Function/prototype/restricted-property-arguments.js +PASS e:/dd/test262/test262/test/built-ins/Function/prototype/restricted-property-caller.js +PASS e:/dd/test262/test262/test/built-ins/Function/prototype/restricted-property-caller.js +PASS e:/dd/test262/test262/test/built-ins/ThrowTypeError/forbidden-arguments.js +PASS e:/dd/test262/test262/test/built-ins/ThrowTypeError/forbidden-arguments.js +PASS e:/dd/test262/test262/test/built-ins/ThrowTypeError/forbidden-caller.js +PASS e:/dd/test262/test262/test/built-ins/ThrowTypeError/forbidden-caller.js ```
Fixes OS#14101048
Partial fix for #249