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

Unified Diff: src/objects-printer.cc

Issue 13064003: First steps towards implementing ArrayBuffer &co in V8 (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Added forgotten tests Created 7 years, 9 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/objects-inl.h ('k') | src/objects-visiting.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/objects-printer.cc
diff --git a/src/objects-printer.cc b/src/objects-printer.cc
index 86382e1d54188ed119925369f5d224323f6eae0b..834223261f301a88af8912c43f24da913ca7e93a 100644
--- a/src/objects-printer.cc
+++ b/src/objects-printer.cc
@@ -184,6 +184,8 @@ void HeapObject::HeapObjectPrint(FILE* out) {
case JS_GLOBAL_PROPERTY_CELL_TYPE:
JSGlobalPropertyCell::cast(this)->JSGlobalPropertyCellPrint(out);
break;
+ case JS_ARRAY_BUFFER_TYPE:
+ JSArrayBuffer::cast(this)->JSArrayBufferPrint(out);
#define MAKE_STRUCT_CASE(NAME, Name, name) \
case NAME##_TYPE: \
Name::cast(this)->Name##Print(out); \
@@ -795,6 +797,16 @@ void JSWeakMap::JSWeakMapPrint(FILE* out) {
}
+void JSArrayBuffer::JSArrayBufferPrint(FILE* out) {
+ HeapObject::PrintHeader(out, "JSArrayBuffer");
+ PrintF(out, " - map = 0x%p\n", reinterpret_cast<void*>(map()));
+ PrintF(out, " - backing_store = -0x%p\n", backing_store());
+ PrintF(out, " - byte_length = ");
+ byte_length()->ShortPrint(out);
+ PrintF(out, "\n");
+}
+
+
void JSFunction::JSFunctionPrint(FILE* out) {
HeapObject::PrintHeader(out, "Function");
PrintF(out, " - map = 0x%p\n", reinterpret_cast<void*>(map()));
« no previous file with comments | « src/objects-inl.h ('k') | src/objects-visiting.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698