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

Unified Diff: src/stub-cache.cc

Issue 12040039: Always fail when trying to store to an undeclared global variable, even if it was found. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: src/stub-cache.cc
diff --git a/src/stub-cache.cc b/src/stub-cache.cc
index 08954ba618ae7ef761a9e9a8df1fc8289fb9b9d9..0e8f755c9ff72612826d04f9be1aaf278bdefea5 100644
--- a/src/stub-cache.cc
+++ b/src/stub-cache.cc
@@ -1057,7 +1057,7 @@ static MaybeObject* ThrowReferenceError(String* name) {
// can't use either LoadIC or KeyedLoadIC constructors.
IC ic(IC::NO_EXTRA_FRAME, Isolate::Current());
ASSERT(ic.target()->is_load_stub() || ic.target()->is_keyed_load_stub());
- if (!ic.SlowIsContextual()) return HEAP->undefined_value();
+ if (!ic.SlowIsUndeclaredGlobal()) return HEAP->undefined_value();
// Throw a reference error.
HandleScope scope;
« no previous file with comments | « src/ic.cc ('k') | test/cctest/cctest.gyp » ('j') | test/cctest/test-global-object.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698