Closed
Bug 558950
Opened 14 years ago
Closed 14 years ago
setting watchpoint on readonly property returns callee
Categories
(Core :: JavaScript Engine, defect)
Tracking
()
RESOLVED
FIXED
People
(Reporter: luke, Assigned: luke)
Details
(Whiteboard: fixed-in-tracemonkey)
Attachments
(1 file)
1.33 KB,
patch
|
Waldo
:
review+
|
Details | Diff | Splinter Review |
The bug is simply that *vp = JSVAL_VOID is done after an early exit for readonly properties so Object.watch (safely) returns the callee, not void. Fix and test attached.
Attachment #438622 -
Flags: review?(jwalden+bmo)
Comment 1•14 years ago
|
||
Comment on attachment 438622 [details] [diff] [review] fix >+ >+ /* Set return value before first successful return. */ >+ *vp = JSVAL_VOID; >+ Comment not necessary here, this is more than obvious to any semi-seasoned JS hacker. >diff --git a/js/src/trace-test/tests/basic/testSettingWatchPointOnReadOnlyProp.js b/js/src/trace- Technically this would be better as a standard JS test (js/src/tests), but it's extensionland already so I don't really care.
Attachment #438622 -
Flags: review?(jwalden+bmo) → review+
Assignee | ||
Comment 2•14 years ago
|
||
http://hg.mozilla.org/tracemonkey/rev/75928f966ea2
Whiteboard: fixed-in-tracemonkey
Comment 3•14 years ago
|
||
http://hg.mozilla.org/mozilla-central/rev/75928f966ea2
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•