WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED WORKSFORME
55171
Omitted value field in descriptor passed to Object.defineProperty is mishandled
https://bugs.webkit.org/show_bug.cgi?id=55171
Summary
Omitted value field in descriptor passed to Object.defineProperty is mishandled
Jeff Walden (remove +bwo to email)
Reported
2011-02-24 12:09:30 PST
jsc behavior:
> typeof Object.defineProperty(Object.defineProperty({}, "p", { value: 7, writable: false, configurable: false, enumerable: true }), "p", { writable: false })
Exception: TypeError: Attempting to change value of a readonly property. Correct behavior: js> typeof Object.defineProperty(Object.defineProperty({}, "p", { value: 7, writable: false, configurable: false, enumerable: true }), "p", { writable: false }) "object"
Attachments
Add attachment
proposed patch, testcase, etc.
Oliver Hunt
Comment 1
2011-02-25 00:01:18 PST
(In reply to
comment #0
)
> jsc behavior: > > > typeof Object.defineProperty(Object.defineProperty({}, "p", { value: 7, writable: false, configurable: false, enumerable: true }), "p", { writable: false }) > Exception: TypeError: Attempting to change value of a readonly property. > > Correct behavior: > > js> typeof Object.defineProperty(Object.defineProperty({}, "p", { value: 7, writable: false, configurable: false, enumerable: true }), "p", { writable: false }) > "object"
Erk is that ToT or shipping safari? I have a dream that it's shipping safari, but i suspect not :-(
Jeff Walden (remove +bwo to email)
Comment 2
2011-02-25 00:25:04 PST
It's a fairly recent svn checkout,
r77758
if the build correlates to the revision of my tree (they should be, I update+build through a single shell alias). I don't know if a shipping Safari has this. I did an update and rebuild, and it's still present with
r79663
(unsurprising as I happened to notice the problem by inspection of the algorithm).
Gavin Barraclough
Comment 3
2012-03-08 17:20:02 PST
This works in ToT. I've fixed a lot of defineOwnProperty bugs in the last couple of months, I'm not going to work out exactly which revision landed the fix for this particular failure. :-)
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