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

Issue 12040039: Always fail when trying to store to an undeclared global variable, even if it was found. (Closed)

Created:
7 years, 11 months ago by Toon Verwaest
Modified:
7 years, 11 months ago
Reviewers:
Jakob Kummerow
CC:
v8-dev
Visibility:
Public.

Description

Always fail when trying to store to an undeclared global variable, even if it was found. Finding a property, but not using an IC, indicates that the variable was found on the prototype (in DOMWindow). Those properties need to be ignored while storing global properties via the IC. Committed: https://code.google.com/p/v8/source/detail?r=13480

Patch Set 1 #

Total comments: 2

Patch Set 2 : Fix test to check for the exact reference error. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+32 lines, -33 lines) Patch
M src/ic.h View 1 1 chunk +4 lines, -4 lines 0 comments Download
M src/ic.cc View 1 5 chunks +6 lines, -9 lines 0 comments Download
M src/stub-cache.cc View 1 1 chunk +1 line, -1 line 0 comments Download
M test/cctest/cctest.gyp View 1 chunk +1 line, -0 lines 0 comments Download
A + test/cctest/test-global-object.cc View 1 1 chunk +20 lines, -19 lines 0 comments Download

Messages

Total messages: 3 (0 generated)
Toon Verwaest
PTAL
7 years, 11 months ago (2013-01-23 15:14:48 UTC) #1
Jakob Kummerow
LGTM with a comment. https://chromiumcodereview.appspot.com/12040039/diff/1/test/cctest/test-global-object.cc File test/cctest/test-global-object.cc (right): https://chromiumcodereview.appspot.com/12040039/diff/1/test/cctest/test-global-object.cc#newcode44 test/cctest/test-global-object.cc:44: "try { x = 42; ...
7 years, 11 months ago (2013-01-23 15:51:25 UTC) #2
Toon Verwaest
7 years, 11 months ago (2013-01-23 16:03:53 UTC) #3
Addressed comment.

https://chromiumcodereview.appspot.com/12040039/diff/1/test/cctest/test-globa...
File test/cctest/test-global-object.cc (right):

https://chromiumcodereview.appspot.com/12040039/diff/1/test/cctest/test-globa...
test/cctest/test-global-object.cc:44: "try { x = 42; z = 10; } catch (e) { z =
20; };");
On 2013/01/23 15:51:25, Jakob wrote:
> Would be nice to assert that we're getting the right kind of exception here.

Done.

Powered by Google App Engine
This is Rietveld 408576698