| 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_RAW_OBJECT_H_ | 5 #ifndef VM_RAW_OBJECT_H_ |
| 6 #define VM_RAW_OBJECT_H_ | 6 #define VM_RAW_OBJECT_H_ |
| 7 | 7 |
| 8 #include "platform/assert.h" | 8 #include "platform/assert.h" |
| 9 #include "vm/atomic.h" | 9 #include "vm/atomic.h" |
| 10 #include "vm/globals.h" | 10 #include "vm/globals.h" |
| (...skipping 911 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 922 }; | 922 }; |
| 923 | 923 |
| 924 RAW_HEAP_OBJECT_IMPLEMENTATION(Library); | 924 RAW_HEAP_OBJECT_IMPLEMENTATION(Library); |
| 925 | 925 |
| 926 RawObject** from() { return reinterpret_cast<RawObject**>(&ptr()->name_); } | 926 RawObject** from() { return reinterpret_cast<RawObject**>(&ptr()->name_); } |
| 927 RawString* name_; | 927 RawString* name_; |
| 928 RawString* url_; | 928 RawString* url_; |
| 929 RawScript* script_; | 929 RawScript* script_; |
| 930 RawString* private_key_; | 930 RawString* private_key_; |
| 931 RawArray* dictionary_; // Top-level names in this library. | 931 RawArray* dictionary_; // Top-level names in this library. |
| 932 RawArray* resolved_names_; // Cache of resolved names in library scope. | |
| 933 RawGrowableObjectArray* metadata_; // Metadata on classes, methods etc. | 932 RawGrowableObjectArray* metadata_; // Metadata on classes, methods etc. |
| 934 RawArray* anonymous_classes_; // Classes containing top-level elements. | 933 RawArray* anonymous_classes_; // Classes containing top-level elements. |
| 935 RawArray* imports_; // List of Namespaces imported without prefix. | 934 RawArray* imports_; // List of Namespaces imported without prefix. |
| 936 RawArray* exports_; // List of re-exported Namespaces. | 935 RawArray* exports_; // List of re-exported Namespaces. |
| 936 RawInstance* load_error_; // Error iff load_state_ == kLoadError. |
| 937 RawObject** to_snapshot() { |
| 938 return reinterpret_cast<RawObject**>(&ptr()->load_error_); |
| 939 } |
| 940 RawArray* resolved_names_; // Cache of resolved names in library scope. |
| 937 RawArray* loaded_scripts_; // Array of scripts loaded in this library. | 941 RawArray* loaded_scripts_; // Array of scripts loaded in this library. |
| 938 RawInstance* load_error_; // Error iff load_state_ == kLoadError. | |
| 939 RawObject** to() { | 942 RawObject** to() { |
| 940 return reinterpret_cast<RawObject**>(&ptr()->load_error_); | 943 return reinterpret_cast<RawObject**>(&ptr()->loaded_scripts_); |
| 941 } | 944 } |
| 942 | 945 |
| 943 Dart_NativeEntryResolver native_entry_resolver_; // Resolves natives. | 946 Dart_NativeEntryResolver native_entry_resolver_; // Resolves natives. |
| 944 Dart_NativeEntrySymbol native_entry_symbol_resolver_; | 947 Dart_NativeEntrySymbol native_entry_symbol_resolver_; |
| 945 classid_t index_; // Library id number. | 948 classid_t index_; // Library id number. |
| 946 classid_t num_anonymous_; // Number of entries in anonymous_classes_. | 949 classid_t num_anonymous_; // Number of entries in anonymous_classes_. |
| 947 uint16_t num_imports_; // Number of entries in imports_. | 950 uint16_t num_imports_; // Number of entries in imports_. |
| 948 int8_t load_state_; // Of type LibraryState. | 951 int8_t load_state_; // Of type LibraryState. |
| 949 bool corelib_imported_; | 952 bool corelib_imported_; |
| 950 bool is_dart_scheme_; | 953 bool is_dart_scheme_; |
| (...skipping 1251 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2202 COMPILE_ASSERT(kExternalTypedDataInt8ArrayCid == | 2205 COMPILE_ASSERT(kExternalTypedDataInt8ArrayCid == |
| 2203 kTypedDataInt8ArrayViewCid + 15); | 2206 kTypedDataInt8ArrayViewCid + 15); |
| 2204 COMPILE_ASSERT(kByteBufferCid == kExternalTypedDataInt8ArrayCid + 14); | 2207 COMPILE_ASSERT(kByteBufferCid == kExternalTypedDataInt8ArrayCid + 14); |
| 2205 COMPILE_ASSERT(kNullCid == kByteBufferCid + 1); | 2208 COMPILE_ASSERT(kNullCid == kByteBufferCid + 1); |
| 2206 return (kNullCid - kTypedDataInt8ArrayCid); | 2209 return (kNullCid - kTypedDataInt8ArrayCid); |
| 2207 } | 2210 } |
| 2208 | 2211 |
| 2209 } // namespace dart | 2212 } // namespace dart |
| 2210 | 2213 |
| 2211 #endif // VM_RAW_OBJECT_H_ | 2214 #endif // VM_RAW_OBJECT_H_ |
| OLD | NEW |