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

Unified Diff: third_party/WebKit/Source/platform/text/DateTimeFormat.cpp

Issue 2811453002: Replace ASSERT, ASSERT_NOT_REACHED, and RELEASE_ASSERT in platform/text (Closed)
Patch Set: Replace ASSERT, ASSERT_NOT_REACHED, and RELEASE_ASSERT in platform/text Created 3 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
Index: third_party/WebKit/Source/platform/text/DateTimeFormat.cpp
diff --git a/third_party/WebKit/Source/platform/text/DateTimeFormat.cpp b/third_party/WebKit/Source/platform/text/DateTimeFormat.cpp
index 32bb1c2291847603b4c31c3244f8a1fcde113144..f2184400146131ea7fc39a1eaf2c64bbdb80aeef 100644
--- a/third_party/WebKit/Source/platform/text/DateTimeFormat.cpp
+++ b/third_party/WebKit/Source/platform/text/DateTimeFormat.cpp
@@ -179,9 +179,9 @@ bool DateTimeFormat::parse(const String& source, TokenHandler& tokenHandler) {
break;
case StateSymbol: {
- ASSERT(fieldType != FieldTypeInvalid);
- ASSERT(fieldType != FieldTypeLiteral);
- ASSERT(literalBuffer.isEmpty());
+ DCHECK_NE(fieldType, FieldTypeInvalid);
+ DCHECK_NE(fieldType, FieldTypeLiteral);
+ DCHECK(literalBuffer.isEmpty());
FieldType fieldType2 = mapCharacterToFieldType(ch);
if (fieldType2 == FieldTypeInvalid)
@@ -211,7 +211,7 @@ bool DateTimeFormat::parse(const String& source, TokenHandler& tokenHandler) {
}
}
- ASSERT(fieldType != FieldTypeInvalid);
+ DCHECK_NE(fieldType, FieldTypeInvalid);
switch (state) {
case StateLiteral:
@@ -227,13 +227,13 @@ bool DateTimeFormat::parse(const String& source, TokenHandler& tokenHandler) {
return false;
case StateSymbol:
- ASSERT(fieldType != FieldTypeLiteral);
- ASSERT(!literalBuffer.length());
+ DCHECK_NE(fieldType, FieldTypeLiteral);
+ DCHECK(!literalBuffer.length());
tokenHandler.visitField(fieldType, fieldCounter);
return true;
}
- ASSERT_NOT_REACHED();
+ NOTREACHED();
return false;
}

Powered by Google App Engine
This is Rietveld 408576698