Reimplement js::SetPropertyIgnoringNamedGetter to follow ES6 draft rev 32 9.1.9 [[Set]]

RESOLVED FIXED in Firefox 39

Status

()

Core
JavaScript Engine
RESOLVED FIXED
3 years ago
3 years ago

People

(Reporter: jorendorff, Assigned: jorendorff)

Tracking

(Blocks: 1 bug)

unspecified
mozilla39
x86_64
Linux
Points:
---
Bug Flags:
in-testsuite +

Firefox Tracking Flags

(firefox39 fixed)

Details

Attachments

(1 attachment)

(Assignee)

Description

3 years ago
Bug 1083211 fixed BaseProxyHandler::set, but a handful of proxies are using SetPropertyIgnoringNamedGetter which still does not resemble the spec at all.

The behavior should be just like 9.1.9 from step 4 to the end, with ownDesc passed in as an argument.
(Assignee)

Comment 1

3 years ago
Created attachment 8564262 [details] [diff] [review]
Update js::SetPropertyIgnoringNamedGetter to ES6 idioms
Attachment #8564262 - Flags: review?(efaustbmo)
(Assignee)

Updated

3 years ago
Assignee: nobody → jorendorff
Status: NEW → ASSIGNED

Comment 2

3 years ago
Comment on attachment 8564262 [details] [diff] [review]
Update js::SetPropertyIgnoringNamedGetter to ES6 idioms

Review of attachment 8564262 [details] [diff] [review]:
-----------------------------------------------------------------

Makes sense. A nice simplification.

::: dom/base/nsGlobalWindow.cpp
@@ +916,5 @@
>    int32_t index = GetArrayIndexFromId(cx, id);
>    if (IsArrayIndex(index)) {
>      // Reject the set.  It's up to the caller to decide whether to throw a
>      // TypeError.  If the caller is strict mode JS code, it'll throw.
> +    return result.failReadOnly();

rebasing gunk, maybe? How did this compile before?
Attachment #8564262 - Flags: review?(efaustbmo) → review+
(Assignee)

Comment 3

3 years ago
Yes, that was rebasing gunk.
(Assignee)

Updated

3 years ago
Blocks: 1139700
https://hg.mozilla.org/mozilla-central/rev/b7a80ceeed2f
Status: ASSIGNED → RESOLVED
Last Resolved: 3 years ago
status-firefox39: --- → fixed
Flags: in-testsuite+
Resolution: --- → FIXED
Target Milestone: --- → mozilla39
You need to log in before you can comment on or make changes to this bug.