| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef VM_OBJECT_STORE_H_ | 5 #ifndef VM_OBJECT_STORE_H_ |
| 6 #define VM_OBJECT_STORE_H_ | 6 #define VM_OBJECT_STORE_H_ |
| 7 | 7 |
| 8 #include "vm/object.h" | 8 #include "vm/object.h" |
| 9 | 9 |
| 10 namespace dart { | 10 namespace dart { |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 43 void set_object_class(const Class& value) { object_class_ = value.raw(); } | 43 void set_object_class(const Class& value) { object_class_ = value.raw(); } |
| 44 static intptr_t object_class_offset() { | 44 static intptr_t object_class_offset() { |
| 45 return OFFSET_OF(ObjectStore, object_class_); | 45 return OFFSET_OF(ObjectStore, object_class_); |
| 46 } | 46 } |
| 47 | 47 |
| 48 RawType* object_type() const { return object_type_; } | 48 RawType* object_type() const { return object_type_; } |
| 49 void set_object_type(const Type& value) { | 49 void set_object_type(const Type& value) { |
| 50 object_type_ = value.raw(); | 50 object_type_ = value.raw(); |
| 51 } | 51 } |
| 52 | 52 |
| 53 RawClass* null_class() const { |
| 54 ASSERT(null_class_ != Object::null()); |
| 55 return null_class_; |
| 56 } |
| 57 void set_null_class(const Class& value) { null_class_ = value.raw(); } |
| 58 |
| 53 RawType* null_type() const { return null_type_; } | 59 RawType* null_type() const { return null_type_; } |
| 54 void set_null_type(const Type& value) { | 60 void set_null_type(const Type& value) { |
| 55 null_type_ = value.raw(); | 61 null_type_ = value.raw(); |
| 56 } | 62 } |
| 57 | 63 |
| 58 RawType* dynamic_type() const { return dynamic_type_; } | 64 RawType* dynamic_type() const { return dynamic_type_; } |
| 59 void set_dynamic_type(const Type& value) { | 65 void set_dynamic_type(const Type& value) { |
| 60 dynamic_type_ = value.raw(); | 66 dynamic_type_ = value.raw(); |
| 61 } | 67 } |
| 62 | 68 |
| (...skipping 357 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 420 bool PreallocateObjects(); | 426 bool PreallocateObjects(); |
| 421 | 427 |
| 422 static void Init(Isolate* isolate); | 428 static void Init(Isolate* isolate); |
| 423 | 429 |
| 424 private: | 430 private: |
| 425 ObjectStore(); | 431 ObjectStore(); |
| 426 | 432 |
| 427 RawObject** from() { return reinterpret_cast<RawObject**>(&object_class_); } | 433 RawObject** from() { return reinterpret_cast<RawObject**>(&object_class_); } |
| 428 RawClass* object_class_; | 434 RawClass* object_class_; |
| 429 RawType* object_type_; | 435 RawType* object_type_; |
| 436 RawClass* null_class_; |
| 430 RawType* null_type_; | 437 RawType* null_type_; |
| 431 RawType* dynamic_type_; | 438 RawType* dynamic_type_; |
| 432 RawType* void_type_; | 439 RawType* void_type_; |
| 433 RawType* function_type_; | 440 RawType* function_type_; |
| 434 RawClass* type_class_; | 441 RawClass* type_class_; |
| 435 RawClass* type_parameter_class_; | 442 RawClass* type_parameter_class_; |
| 436 RawClass* bounded_type_class_; | 443 RawClass* bounded_type_class_; |
| 437 RawClass* mixin_app_type_class_; | 444 RawClass* mixin_app_type_class_; |
| 438 RawType* number_type_; | 445 RawType* number_type_; |
| 439 RawType* int_type_; | 446 RawType* int_type_; |
| (...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 497 RawObject** to() { return reinterpret_cast<RawObject**>(&keyword_symbols_); } | 504 RawObject** to() { return reinterpret_cast<RawObject**>(&keyword_symbols_); } |
| 498 | 505 |
| 499 friend class SnapshotReader; | 506 friend class SnapshotReader; |
| 500 | 507 |
| 501 DISALLOW_COPY_AND_ASSIGN(ObjectStore); | 508 DISALLOW_COPY_AND_ASSIGN(ObjectStore); |
| 502 }; | 509 }; |
| 503 | 510 |
| 504 } // namespace dart | 511 } // namespace dart |
| 505 | 512 |
| 506 #endif // VM_OBJECT_STORE_H_ | 513 #endif // VM_OBJECT_STORE_H_ |
| OLD | NEW |