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

Unified Diff: src/isolate.cc

Issue 229973004: Remove calls to non-handlified version of GetProperty(name). (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: update Created 6 years, 8 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
« no previous file with comments | « src/factory.cc ('k') | src/messages.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/isolate.cc
diff --git a/src/isolate.cc b/src/isolate.cc
index 20d148e2850e1dc82abc55326967271a15482d35..e384090ef33ab38abb887088fbd3844b633b9af8 100644
--- a/src/isolate.cc
+++ b/src/isolate.cc
@@ -1046,15 +1046,17 @@ bool Isolate::ShouldReportException(bool* can_be_caught_externally,
bool Isolate::IsErrorObject(Handle<Object> obj) {
if (!obj->IsJSObject()) return false;
- String* error_key =
- *(factory()->InternalizeOneByteString(STATIC_ASCII_VECTOR("$Error")));
- Object* error_constructor =
- js_builtins_object()->GetPropertyNoExceptionThrown(error_key);
+ Handle<String> error_key =
+ factory()->InternalizeOneByteString(STATIC_ASCII_VECTOR("$Error"));
+ Handle<Object> error_constructor = GlobalObject::GetPropertyNoExceptionThrown(
+ js_builtins_object(), error_key);
+ DisallowHeapAllocation no_gc;
for (Object* prototype = *obj; !prototype->IsNull();
prototype = prototype->GetPrototype(this)) {
if (!prototype->IsJSObject()) return false;
- if (JSObject::cast(prototype)->map()->constructor() == error_constructor) {
+ if (JSObject::cast(prototype)->map()->constructor() ==
+ *error_constructor) {
return true;
}
}
« no previous file with comments | « src/factory.cc ('k') | src/messages.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698