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

Unified Diff: src/heap/heap-inl.h

Issue 2627783006: Version 5.7.442.2 (cherry-pick) (Closed)
Patch Set: Created 3 years, 11 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/heap/heap.cc ('k') | src/heap/mark-compact.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/heap/heap-inl.h
diff --git a/src/heap/heap-inl.h b/src/heap/heap-inl.h
index 67d65bfc85b378963803589e3b848f4b95fcfe24..4d060f8e431a7ec8164645f0a6cfd47a2fe56f25 100644
--- a/src/heap/heap-inl.h
+++ b/src/heap/heap-inl.h
@@ -225,8 +225,6 @@ AllocationResult Heap::AllocateInternalizedStringImpl(T t, int chars,
AllocationResult Heap::AllocateOneByteInternalizedString(
Vector<const uint8_t> str, uint32_t hash_field) {
CHECK_GE(String::kMaxLength, str.length());
- // The canonical empty_string is the only zero-length string we allow.
- DCHECK_IMPLIES(str.length() == 0, roots_[kempty_stringRootIndex] == nullptr);
// Compute map and object size.
Map* map = one_byte_internalized_string_map();
int size = SeqOneByteString::SizeFor(str.length());
@@ -258,7 +256,6 @@ AllocationResult Heap::AllocateOneByteInternalizedString(
AllocationResult Heap::AllocateTwoByteInternalizedString(Vector<const uc16> str,
uint32_t hash_field) {
CHECK_GE(String::kMaxLength, str.length());
- DCHECK_NE(0, str.length()); // Use Heap::empty_string() instead.
// Compute map and object size.
Map* map = internalized_string_map();
int size = SeqTwoByteString::SizeFor(str.length());
« no previous file with comments | « src/heap/heap.cc ('k') | src/heap/mark-compact.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698