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

Unified Diff: src/heap-inl.h

Issue 196133030: Make max size and max length of strings consistent. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: fix Created 6 years, 9 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.cc ('k') | src/hydrogen.cc » ('j') | src/hydrogen.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/heap-inl.h
diff --git a/src/heap-inl.h b/src/heap-inl.h
index c36a6fd795c0a235066da1013edde6a6d4e072c8..efad2fbf5969cf7604915db269934615e36c3a9a 100644
--- a/src/heap-inl.h
+++ b/src/heap-inl.h
@@ -137,7 +137,7 @@ MaybeObject* Heap::AllocateInternalizedStringImpl(
MaybeObject* Heap::AllocateOneByteInternalizedString(Vector<const uint8_t> str,
uint32_t hash_field) {
- if (str.length() > SeqOneByteString::kMaxLength) {
+ if (str.length() > String::kMaxLength) {
return Failure::OutOfMemoryException(0x2);
}
// Compute map and object size.
@@ -170,7 +170,7 @@ MaybeObject* Heap::AllocateOneByteInternalizedString(Vector<const uint8_t> str,
MaybeObject* Heap::AllocateTwoByteInternalizedString(Vector<const uc16> str,
uint32_t hash_field) {
- if (str.length() > SeqTwoByteString::kMaxLength) {
+ if (str.length() > String::kMaxLength) {
return Failure::OutOfMemoryException(0x3);
}
// Compute map and object size.
« no previous file with comments | « src/heap.cc ('k') | src/hydrogen.cc » ('j') | src/hydrogen.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698