Commit 0f6f6215 authored by yangguo@chromium.org's avatar yangguo@chromium.org

Assert external strings in external string table. Remove TODOs.

R=hpayer@chromium.org
BUG=

Review URL: https://codereview.chromium.org/23567002

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@16440 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 72826fc8
......@@ -718,13 +718,11 @@ void ExternalStringTable::Verify() {
#ifdef DEBUG
for (int i = 0; i < new_space_strings_.length(); ++i) {
Object* obj = Object::cast(new_space_strings_[i]);
// TODO(yangguo): check that the object is indeed an external string.
ASSERT(heap_->InNewSpace(obj));
ASSERT(obj != HEAP->the_hole_value());
}
for (int i = 0; i < old_space_strings_.length(); ++i) {
Object* obj = Object::cast(old_space_strings_[i]);
// TODO(yangguo): check that the object is indeed an external string.
ASSERT(!heap_->InNewSpace(obj));
ASSERT(obj != HEAP->the_hole_value());
}
......
......@@ -7916,6 +7916,7 @@ void ExternalStringTable::CleanUp() {
if (new_space_strings_[i] == heap_->the_hole_value()) {
continue;
}
ASSERT(new_space_strings_[i]->IsExternalString());
if (heap_->InNewSpace(new_space_strings_[i])) {
new_space_strings_[last++] = new_space_strings_[i];
} else {
......@@ -7930,6 +7931,7 @@ void ExternalStringTable::CleanUp() {
if (old_space_strings_[i] == heap_->the_hole_value()) {
continue;
}
ASSERT(old_space_strings_[i]->IsExternalString());
ASSERT(!heap_->InNewSpace(old_space_strings_[i]));
old_space_strings_[last++] = old_space_strings_[i];
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment