<html>
<head>
<base href="https://bugs.webkit.org/" />
</head>
<body>
<p>
<div>
<b><a class="bz_bug_link
bz_status_NEW "
title="NEW - [test262] Fixing mapped arguments object property test case"
href="https://bugs.webkit.org/show_bug.cgi?id=159398#c25">Comment # 25</a>
on <a class="bz_bug_link
bz_status_NEW "
title="NEW - [test262] Fixing mapped arguments object property test case"
href="https://bugs.webkit.org/show_bug.cgi?id=159398">bug 159398</a>
from <span class="vcard"><a class="email" href="mailto:ggaren@apple.com" title="Geoffrey Garen <ggaren@apple.com>"> <span class="fn">Geoffrey Garen</span></a>
</span></b>
<pre>Comment on <span class=""><a href="attachment.cgi?id=283766&action=diff" name="attach_283766" title="Patch">attachment 283766</a> <a href="attachment.cgi?id=283766&action=edit" title="Patch">[details]</a></span>
Patch
View in context: <a href="https://bugs.webkit.org/attachment.cgi?id=283766&action=review">https://bugs.webkit.org/attachment.cgi?id=283766&action=review</a>
It looks like you've invented a way for the arguments object to override an indexed property by storing a value in its JSObject storage. The arguments object already had a different way to indicate that an indexed property had been overridden: the "overrideArgument" mechanism. Did you consider using the overrideArgument mechanism? What's better about this new mechanism? That's a good thing to explain in your ChangeLog.
I suspect that it might be better to use the overrideArgument mechanism, or to augment it for this purpose.
<span class="quote">> Source/JavaScriptCore/ChangeLog:9
> + mapped arguments object with non-configurable and no-writable property</span >
non-writable
<span class="quote">> Source/JavaScriptCore/ChangeLog:10
> + cases. Also it is fixing cases where arguments[i] cannot be deleted </span >
fixes
<span class="quote">> Source/JavaScriptCore/ChangeLog:11
> + when argument "i" is not configurable. The test cases added are from</span >
from the
<span class="quote">> Source/JavaScriptCore/runtime/GenericArgumentsInlines.h:222
> + object->putDirectMayBeIndex(exec, ident, value);
> +
> + return Base::defineOwnProperty(object, exec, ident, descriptor, shouldThrow);</span >
This looks wrong. You're assigning the property twice -- first by putDirectMayBeIndex and second by defineOwnProperty.
Also, you don't seem to invoke the "overrideArgument" mechanism, which is what we usually use to indicate that something strange has happened to an indexed property.</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>