Open YiWen-y opened 4 years ago
This appears to be an issue with the implementation of abstract operation ValidateAndApplyPropertyDescriptor, specifically part 4.b. https://tc39.es/ecma262/#sec-validateandapplypropertydescriptor
4. If current.[[Configurable]] is false, then
a. If Desc.[[Configurable]] is present and its value is true, return false.
b. If Desc.[[Enumerable]] is present and ! SameValue(Desc.[[Enumerable]], current.[[Enumerable]]) is false, return false.
Desc.[[Enumerable]]
is not present, but it appears to be using a default value of false, which is not the same value as current.[[Enumerable]]
Version
rhino-1.7.13
Test case
Execution steps
Output
Expected behavior
Description
When executing this test case, other engines passed normally without throwing any exceptions, such as v8, spiderMonkey, JavaScriptCore, etc. But rhino throws a TypeError exception. I would like to ask how this is achieved?