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

Unified Diff: src/uri.h

Issue 430503007: Rename ASSERT* to DCHECK*. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: REBASE and fixes Created 6 years, 4 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/unique.h ('k') | src/utils.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/uri.h
diff --git a/src/uri.h b/src/uri.h
index a35ee9919d54e2c4ed0448c43a98415b0ff578e1..bb5140b8c02414b2d643ab2c853621b1751ebadf 100644
--- a/src/uri.h
+++ b/src/uri.h
@@ -22,7 +22,7 @@ static INLINE(Vector<const Char> GetCharVector(Handle<String> string));
template <>
Vector<const uint8_t> GetCharVector(Handle<String> string) {
String::FlatContent flat = string->GetFlatContent();
- ASSERT(flat.IsAscii());
+ DCHECK(flat.IsAscii());
return flat.ToOneByteVector();
}
@@ -30,7 +30,7 @@ Vector<const uint8_t> GetCharVector(Handle<String> string) {
template <>
Vector<const uc16> GetCharVector(Handle<String> string) {
String::FlatContent flat = string->GetFlatContent();
- ASSERT(flat.IsTwoByte());
+ DCHECK(flat.IsTwoByte());
return flat.ToUC16Vector();
}
@@ -100,13 +100,13 @@ MaybeHandle<String> URIUnescape::UnescapeSlow(
}
}
- ASSERT(start_index < length);
+ DCHECK(start_index < length);
Handle<String> first_part =
isolate->factory()->NewProperSubString(string, 0, start_index);
int dest_position = 0;
Handle<String> second_part;
- ASSERT(unescaped_length <= String::kMaxLength);
+ DCHECK(unescaped_length <= String::kMaxLength);
if (one_byte) {
Handle<SeqOneByteString> dest = isolate->factory()->NewRawOneByteString(
unescaped_length).ToHandleChecked();
@@ -226,7 +226,7 @@ const char URIEscape::kNotEscaped[] = {
template<typename Char>
MaybeHandle<String> URIEscape::Escape(Isolate* isolate, Handle<String> string) {
- ASSERT(string->IsFlat());
+ DCHECK(string->IsFlat());
int escaped_length = 0;
int length = string->length();
@@ -243,7 +243,7 @@ MaybeHandle<String> URIEscape::Escape(Isolate* isolate, Handle<String> string) {
}
// We don't allow strings that are longer than a maximal length.
- ASSERT(String::kMaxLength < 0x7fffffff - 6); // Cannot overflow.
+ DCHECK(String::kMaxLength < 0x7fffffff - 6); // Cannot overflow.
if (escaped_length > String::kMaxLength) break; // Provoke exception.
}
}
« no previous file with comments | « src/unique.h ('k') | src/utils.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698