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

Unified Diff: chrome/common/json_schema_validator.cc

Issue 8368018: Convert chrome/common non-debug logs to debug logs. (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 9 years, 2 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 | « chrome/common/json_pref_store.cc ('k') | chrome/common/logging_chrome.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/json_schema_validator.cc
===================================================================
--- chrome/common/json_schema_validator.cc (revision 106774)
+++ chrome/common/json_schema_validator.cc (working copy)
@@ -93,7 +93,7 @@
case Value::TYPE_LIST:
return "array";
default:
- CHECK(false) << "Unexpected value type: " << value->GetType();
+ NOTREACHED() << "Unexpected value type: " << value->GetType();
return "";
}
}
@@ -133,7 +133,7 @@
std::string id;
CHECK(type->GetString("id", &id));
- CHECK(types_.find(id) == types_.end());
+ DCHECK(types_.find(id) == types_.end());
types_[id] = type;
}
}
@@ -156,7 +156,7 @@
if (iter == types_.end())
types_[id] = schema;
else
- CHECK(iter->second == schema);
+ DCHECK(iter->second == schema);
}
// If the schema has a $ref property, the instance must validate against
@@ -191,7 +191,7 @@
std::string type;
schema->GetString("type", &type);
- CHECK(!type.empty());
+ DCHECK(!type.empty());
if (type != "any") {
if (!ValidateType(instance, type, path))
return;
@@ -206,7 +206,7 @@
else if (type == "number" || type == "integer")
ValidateNumber(instance, schema, path);
else if (type != "boolean" && type != "null")
- CHECK(false) << "Unexpected type: " << type;
+ NOTREACHED() << "Unexpected type: " << type;
}
}
@@ -257,7 +257,7 @@
break;
default:
- CHECK(false) << "Unexpected type in enum: " << choice->GetType();
+ NOTREACHED() << "Unexpected type in enum: " << choice->GetType();
}
}
@@ -320,7 +320,7 @@
if (schema->GetDictionary("items", &single_type)) {
int min_items = 0;
if (schema->GetInteger("minItems", &min_items)) {
- CHECK(min_items >= 0);
+ DCHECK(min_items >= 0);
if (instance_size < static_cast<size_t>(min_items)) {
errors_.push_back(Error(path, FormatErrorMessage(
kArrayMinItems, base::IntToString(min_items))));
@@ -329,7 +329,7 @@
int max_items = 0;
if (schema->GetInteger("maxItems", &max_items)) {
- CHECK(max_items >= 0);
+ DCHECK(max_items >= 0);
if (instance_size > static_cast<size_t>(max_items)) {
errors_.push_back(Error(path, FormatErrorMessage(
kArrayMaxItems, base::IntToString(max_items))));
« no previous file with comments | « chrome/common/json_pref_store.cc ('k') | chrome/common/logging_chrome.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698