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

Unified Diff: runtime/vm/object_store.cc

Issue 8383029: Implement external strings. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address final review comments Created 9 years, 1 month 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 | « runtime/vm/object_store.h ('k') | runtime/vm/object_test.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/object_store.cc
diff --git a/runtime/vm/object_store.cc b/runtime/vm/object_store.cc
index 4f14b88e7f577f433504fe6bcf2ea0a39cf28e02..6a5e7c9eb25499ef531e3c5b8029a9e5dd097e3f 100644
--- a/runtime/vm/object_store.cc
+++ b/runtime/vm/object_store.cc
@@ -25,11 +25,15 @@ ObjectStore::ObjectStore()
one_byte_string_class_(Class::null()),
two_byte_string_class_(Class::null()),
four_byte_string_class_(Class::null()),
+ external_one_byte_string_class_(Class::null()),
+ external_two_byte_string_class_(Class::null()),
+ external_four_byte_string_class_(Class::null()),
bool_interface_(Type::null()),
bool_class_(Class::null()),
list_interface_(Type::null()),
array_class_(Class::null()),
immutable_array_class_(Class::null()),
+ byte_buffer_class_(Class::null()),
unhandled_exception_class_(Class::null()),
stacktrace_class_(Class::null()),
jsregexp_class_(Class::null()),
@@ -75,6 +79,9 @@ RawClass* ObjectStore::GetClass(int index) {
case kOneByteStringClass: return one_byte_string_class_;
case kTwoByteStringClass: return two_byte_string_class_;
case kFourByteStringClass: return four_byte_string_class_;
+ case kExternalOneByteStringClass: return external_one_byte_string_class_;
+ case kExternalTwoByteStringClass: return external_two_byte_string_class_;
+ case kExternalFourByteStringClass: return external_four_byte_string_class_;
case kBoolClass: return bool_class_;
case kArrayClass: return array_class_;
case kImmutableArrayClass: return immutable_array_class_;
@@ -107,6 +114,12 @@ int ObjectStore::GetClassIndex(const RawClass* raw_class) {
return kTwoByteStringClass;
} else if (raw_class == four_byte_string_class_) {
return kFourByteStringClass;
+ } else if (raw_class == external_one_byte_string_class_) {
+ return kExternalOneByteStringClass;
+ } else if (raw_class == external_two_byte_string_class_) {
+ return kExternalTwoByteStringClass;
+ } else if (raw_class == external_four_byte_string_class_) {
+ return kExternalFourByteStringClass;
} else if (raw_class == bool_class_) {
return kBoolClass;
} else if (raw_class == array_class_) {
« no previous file with comments | « runtime/vm/object_store.h ('k') | runtime/vm/object_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698