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

Unified Diff: ppapi/cpp/var.cc

Issue 12387073: Add PPB_VarDictionary_Dev support - part 1. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Use correct base branch. Created 7 years, 10 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: ppapi/cpp/var.cc
diff --git a/ppapi/cpp/var.cc b/ppapi/cpp/var.cc
index 7fc67f5b273e754e4b296a030e781c3bb56345e8..034859e3fd2d7d04933a1c445a3ea4182b71b35c 100644
--- a/ppapi/cpp/var.cc
+++ b/ppapi/cpp/var.cc
@@ -229,10 +229,16 @@ std::string Var::DebugString() const {
str.append("...");
}
snprintf(buf, sizeof(buf), format, str.c_str());
- } else if (is_array_buffer()) {
- snprintf(buf, sizeof(buf), "Var(ARRAY_BUFFER)");
} else if (is_object()) {
snprintf(buf, sizeof(buf), "Var(OBJECT)");
+ } else if (is_array()) {
+ snprintf(buf, sizeof(buf), "Var(ARRAY)");
+ } else if (is_dictionary()) {
+ snprintf(buf, sizeof(buf), "Var(DICTIONARY)");
+ } else if (is_array_buffer()) {
+ snprintf(buf, sizeof(buf), "Var(ARRAY_BUFFER)");
+ } else {
+ buf[0] = '\0';
}
return buf;
}

Powered by Google App Engine
This is Rietveld 408576698