Index: src/objects-debug.cc |
=================================================================== |
--- src/objects-debug.cc (revision 539) |
+++ src/objects-debug.cc (working copy) |
@@ -127,6 +127,9 @@ |
case JS_FUNCTION_TYPE: |
JSFunction::cast(this)->JSFunctionPrint(); |
break; |
+ case JS_GLOBAL_PROXY_TYPE: |
+ JSGlobalProxy::cast(this)->JSGlobalProxyPrint(); |
+ break; |
case JS_GLOBAL_OBJECT_TYPE: |
JSGlobalObject::cast(this)->JSGlobalObjectPrint(); |
break; |
@@ -198,6 +201,9 @@ |
case JS_FUNCTION_TYPE: |
JSFunction::cast(this)->JSFunctionVerify(); |
break; |
+ case JS_GLOBAL_PROXY_TYPE: |
+ JSGlobalProxy::cast(this)->JSGlobalProxyVerify(); |
+ break; |
case JS_GLOBAL_OBJECT_TYPE: |
JSGlobalObject::cast(this)->JSGlobalObjectVerify(); |
break; |
@@ -551,9 +557,31 @@ |
} |
+void JSGlobalProxy::JSGlobalProxyPrint() { |
+ PrintF("global_proxy"); |
+ JSObjectPrint(); |
+ PrintF("context : "); |
+ context()->ShortPrint(); |
+ PrintF("\n"); |
+} |
+ |
+ |
+void JSGlobalProxy::JSGlobalProxyVerify() { |
+ CHECK(IsJSGlobalProxy()); |
+ JSObjectVerify(); |
+ VerifyObjectField(JSGlobalProxy::kContextOffset); |
+ // Make sure that this object has no properties, elements. |
+ CHECK(properties()->length() == 0); |
+ CHECK(elements()->length() == 0); |
+} |
+ |
+ |
void JSGlobalObject::JSGlobalObjectPrint() { |
PrintF("global "); |
JSObjectPrint(); |
+ PrintF("global context : "); |
+ global_context()->ShortPrint(); |
+ PrintF("\n"); |
} |