WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
154665
[ES6] for...in iteration doesn't comply with the specification
https://bugs.webkit.org/show_bug.cgi?id=154665
Summary
[ES6] for...in iteration doesn't comply with the specification
Saam Barati
Reported
2016-02-24 20:53:31 PST
Specifically, the has_*_property call JSObject::hasProperty instead of JSObject::hasOwnProperty (which is essentially calling [[GetOwnProperty]]). see the specification:
https://tc39.github.io/ecma262/#sec-enumerate-object-properties
Attachments
patch
(11.16 KB, patch)
2016-02-25 15:28 PST
,
Saam Barati
msaboff
: review+
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Saam Barati
Comment 1
2016-02-25 14:36:49 PST
(In reply to
comment #0
)
> Specifically, the has_*_property call JSObject::hasProperty > instead of JSObject::hasOwnProperty (which is essentially calling > [[GetOwnProperty]]). > > see the specification: >
https://tc39.github.io/ecma262/#sec-enumerate-object-properties
This assessment isn't quite right. We want to process over the entire prototype chain like hasProperty does, but we want to perform [[GetOwnProperty]] and not [[HasProperty]].
Saam Barati
Comment 2
2016-02-25 15:28:14 PST
Created
attachment 272252
[details]
patch
Michael Saboff
Comment 3
2016-02-25 15:35:29 PST
Comment on
attachment 272252
[details]
patch r=me
Saam Barati
Comment 4
2016-02-25 16:16:24 PST
landed in:
http://trac.webkit.org/changeset/197144
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug