Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3)

Issue 2131019: Fixes issue 712 causing non-configurable accessors to be overwritable by usin... (Closed)

Created:
10 years, 7 months ago by Rico
Modified:
9 years, 6 months ago
Reviewers:
Erik Corry
CC:
v8-dev
Visibility:
Public.

Description

Fixes issue 712 causing non-configurable accessors to be overwritable by using Object.defineProperty with empty property descriptor. The issue is fixed by implementing step 5 and 6 from DefineOwnProperty in the specification (ES5 8.12.9). This also fixes a bug in SameValue when used on boolean values (it would priorly return a number - not a boolean). Committed: http://code.google.com/p/v8/source/detail?r=4708

Patch Set 1 #

Total comments: 12

Patch Set 2 : '' #

Patch Set 3 : '' #

Total comments: 4
Unified diffs Side-by-side diffs Delta from patch set Stats (+296 lines, -20 lines) Patch
M src/runtime.js View 1 2 1 chunk +3 lines, -4 lines 0 comments Download
M src/v8natives.js View 1 3 chunks +23 lines, -1 line 0 comments Download
M test/mjsunit/object-define-property.js View 8 chunks +232 lines, -15 lines 4 comments Download
A test/mjsunit/regress/regress-712.js View 1 1 chunk +38 lines, -0 lines 0 comments Download

Messages

Total messages: 6 (0 generated)
Rico
Ugly conditional with a lot of comparisons - I don't have an easy solution to ...
10 years, 7 months ago (2010-05-20 13:28:05 UTC) #1
Erik Corry
LGTM with comments. http://codereview.chromium.org/2131019/diff/1/2 File src/runtime.js (right): http://codereview.chromium.org/2131019/diff/1/2#newcode566 src/runtime.js:566: if (x === 0 && y ...
10 years, 7 months ago (2010-05-20 14:08:39 UTC) #2
Rico
Erik, could you take another look, I changed it quite a bit + added a ...
10 years, 7 months ago (2010-05-21 12:18:59 UTC) #3
Erik Corry
You can run the test with --expose-natives-as foobar Then you can do foobar.SameValue to get ...
10 years, 7 months ago (2010-05-21 13:16:16 UTC) #4
Erik Corry
LGTM http://codereview.chromium.org/2131019/diff/9001/10003 File test/mjsunit/object-define-property.js (right): http://codereview.chromium.org/2131019/diff/9001/10003#newcode511 test/mjsunit/object-define-property.js:511: // Test that all possible differences in step ...
10 years, 7 months ago (2010-05-21 13:21:57 UTC) #5
Rico
10 years, 7 months ago (2010-05-25 06:24:50 UTC) #6
http://codereview.chromium.org/2131019/diff/9001/10003
File test/mjsunit/object-define-property.js (right):

http://codereview.chromium.org/2131019/diff/9001/10003#newcode511
test/mjsunit/object-define-property.js:511: // Test that all possible
differences in step 6 in DefineOwnProperty is
On 2010/05/21 13:21:57, Erik Corry wrote:
> differences ... is -> differences ... are

Done.

http://codereview.chromium.org/2131019/diff/9001/10003#newcode689
test/mjsunit/object-define-property.js:689: // Make sure that we can't overwrite
+0 with -0 and vise verca.
On 2010/05/21 13:21:57, Erik Corry wrote:
> vise verca -> vice versa
> 
> (or was that deliberate :-)
No :-) done

Powered by Google App Engine
This is Rietveld 408576698