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

Unified Diff: src/json-parser.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/isolate.cc ('k') | src/json-stringifier.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/json-parser.h
diff --git a/src/json-parser.h b/src/json-parser.h
index 78ac378c1e09dc4ffc9d8bc4c462e94857257377..b996fb04a4f7b8bf4e3544d000efa03398194391 100644
--- a/src/json-parser.h
+++ b/src/json-parser.h
@@ -104,7 +104,7 @@ class JsonParser BASE_EMBEDDED {
DisallowHeapAllocation no_gc;
String::FlatContent content = expected->GetFlatContent();
if (content.IsAscii()) {
- ASSERT_EQ('"', c0_);
+ DCHECK_EQ('"', c0_);
const uint8_t* input_chars = seq_source_->GetChars() + position_ + 1;
const uint8_t* expected_chars = content.ToOneByteVector().start();
for (int i = 0; i < length; i++) {
@@ -300,7 +300,7 @@ Handle<Object> JsonParser<seq_ascii>::ParseJsonObject() {
factory()->NewJSObject(object_constructor(), pretenure_);
Handle<Map> map(json_object->map());
ZoneList<Handle<Object> > properties(8, zone());
- ASSERT_EQ(c0_, '{');
+ DCHECK_EQ(c0_, '{');
bool transitioning = true;
@@ -397,7 +397,7 @@ Handle<Object> JsonParser<seq_ascii>::ParseJsonObject() {
isolate(), expected_representation));
Map::GeneralizeFieldType(target, descriptor, value_type);
}
- ASSERT(target->instance_descriptors()->GetFieldType(
+ DCHECK(target->instance_descriptors()->GetFieldType(
descriptor)->NowContains(value));
properties.Add(value, zone());
map = target;
@@ -451,7 +451,7 @@ template <bool seq_ascii>
Handle<Object> JsonParser<seq_ascii>::ParseJsonArray() {
HandleScope scope(isolate());
ZoneList<Handle<Object> > elements(4, zone());
- ASSERT_EQ(c0_, '[');
+ DCHECK_EQ(c0_, '[');
AdvanceSkipWhitespace();
if (c0_ != ']') {
@@ -666,7 +666,7 @@ Handle<String> JsonParser<seq_ascii>::SlowScanJsonString(
}
}
- ASSERT_EQ('"', c0_);
+ DCHECK_EQ('"', c0_);
// Advance past the last '"'.
AdvanceSkipWhitespace();
@@ -678,7 +678,7 @@ Handle<String> JsonParser<seq_ascii>::SlowScanJsonString(
template <bool seq_ascii>
template <bool is_internalized>
Handle<String> JsonParser<seq_ascii>::ScanJsonString() {
- ASSERT_EQ('"', c0_);
+ DCHECK_EQ('"', c0_);
Advance();
if (c0_ == '"') {
AdvanceSkipWhitespace();
@@ -741,7 +741,7 @@ Handle<String> JsonParser<seq_ascii>::ScanJsonString() {
#ifdef DEBUG
uint32_t hash_field =
(hash << String::kHashShift) | String::kIsNotArrayIndexMask;
- ASSERT_EQ(static_cast<int>(result->Hash()),
+ DCHECK_EQ(static_cast<int>(result->Hash()),
static_cast<int>(hash_field >> String::kHashShift));
#endif
break;
@@ -779,7 +779,7 @@ Handle<String> JsonParser<seq_ascii>::ScanJsonString() {
uint8_t* dest = SeqOneByteString::cast(*result)->GetChars();
String::WriteToFlat(*source_, dest, beg_pos, position_);
- ASSERT_EQ('"', c0_);
+ DCHECK_EQ('"', c0_);
// Advance past the last '"'.
AdvanceSkipWhitespace();
return result;
« no previous file with comments | « src/isolate.cc ('k') | src/json-stringifier.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698