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_H_ | 5 #ifndef VM_OBJECT_H_ |
6 #define VM_OBJECT_H_ | 6 #define VM_OBJECT_H_ |
7 | 7 |
8 #include "include/dart_api.h" | 8 #include "include/dart_api.h" |
9 #include "platform/assert.h" | 9 #include "platform/assert.h" |
10 #include "platform/utils.h" | 10 #include "platform/utils.h" |
(...skipping 3182 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3193 // into the token objects array for IDENT or literal tokens). | 3193 // into the token objects array for IDENT or literal tokens). |
3194 intptr_t ReadToken() { | 3194 intptr_t ReadToken() { |
3195 int64_t value = stream_.ReadUnsigned(); | 3195 int64_t value = stream_.ReadUnsigned(); |
3196 ASSERT((value >= 0) && (value <= kIntptrMax)); | 3196 ASSERT((value >= 0) && (value <= kIntptrMax)); |
3197 return static_cast<intptr_t>(value); | 3197 return static_cast<intptr_t>(value); |
3198 } | 3198 } |
3199 | 3199 |
3200 TokenStream& tokens_; | 3200 TokenStream& tokens_; |
3201 ExternalTypedData& data_; | 3201 ExternalTypedData& data_; |
3202 ReadStream stream_; | 3202 ReadStream stream_; |
3203 GrowableObjectArray& token_objects_; | 3203 Array& token_objects_; |
3204 Object& obj_; | 3204 Object& obj_; |
3205 intptr_t cur_token_pos_; | 3205 intptr_t cur_token_pos_; |
3206 Token::Kind cur_token_kind_; | 3206 Token::Kind cur_token_kind_; |
3207 intptr_t cur_token_obj_index_; | 3207 intptr_t cur_token_obj_index_; |
3208 Iterator::StreamType stream_type_; | 3208 Iterator::StreamType stream_type_; |
3209 }; | 3209 }; |
3210 | 3210 |
3211 private: | 3211 private: |
3212 void SetPrivateKey(const String& value) const; | 3212 void SetPrivateKey(const String& value) const; |
3213 | 3213 |
(...skipping 5011 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8225 | 8225 |
8226 | 8226 |
8227 RawObject* MegamorphicCache::GetTargetFunction(const Array& array, | 8227 RawObject* MegamorphicCache::GetTargetFunction(const Array& array, |
8228 intptr_t index) { | 8228 intptr_t index) { |
8229 return array.At((index * kEntryLength) + kTargetFunctionIndex); | 8229 return array.At((index * kEntryLength) + kTargetFunctionIndex); |
8230 } | 8230 } |
8231 | 8231 |
8232 } // namespace dart | 8232 } // namespace dart |
8233 | 8233 |
8234 #endif // VM_OBJECT_H_ | 8234 #endif // VM_OBJECT_H_ |
OLD | NEW |