OLD | NEW |
1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2017, 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 RUNTIME_VM_KERNEL_BINARY_FLOWGRAPH_H_ | 5 #ifndef RUNTIME_VM_KERNEL_BINARY_FLOWGRAPH_H_ |
6 #define RUNTIME_VM_KERNEL_BINARY_FLOWGRAPH_H_ | 6 #define RUNTIME_VM_KERNEL_BINARY_FLOWGRAPH_H_ |
7 | 7 |
8 #if !defined(DART_PRECOMPILED_RUNTIME) | 8 #if !defined(DART_PRECOMPILED_RUNTIME) |
9 | 9 |
10 #include <map> | 10 #include <map> |
(...skipping 1194 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1205 class ClassHelper { | 1205 class ClassHelper { |
1206 public: | 1206 public: |
1207 enum Fields { | 1207 enum Fields { |
1208 kStart, // tag. | 1208 kStart, // tag. |
1209 kCanonicalName, | 1209 kCanonicalName, |
1210 kPosition, | 1210 kPosition, |
1211 kEndPosition, | 1211 kEndPosition, |
1212 kIsAbstract, | 1212 kIsAbstract, |
1213 kNameIndex, | 1213 kNameIndex, |
1214 kSourceUriIndex, | 1214 kSourceUriIndex, |
| 1215 kDocumentationCommentIndex, |
1215 kAnnotations, | 1216 kAnnotations, |
1216 kTypeParameters, | 1217 kTypeParameters, |
1217 kSuperClass, | 1218 kSuperClass, |
1218 kMixinType, | 1219 kMixinType, |
1219 kImplementedClasses, | 1220 kImplementedClasses, |
1220 kFields, | 1221 kFields, |
1221 kConstructors, | 1222 kConstructors, |
1222 kProcedures, | 1223 kProcedures, |
1223 kEnd | 1224 kEnd |
1224 }; | 1225 }; |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1256 is_abstract_ = builder_->ReadBool(); // read is_abstract. | 1257 is_abstract_ = builder_->ReadBool(); // read is_abstract. |
1257 if (++next_read_ == field) return; | 1258 if (++next_read_ == field) return; |
1258 case kNameIndex: | 1259 case kNameIndex: |
1259 name_index_ = builder_->ReadStringReference(); // read name index. | 1260 name_index_ = builder_->ReadStringReference(); // read name index. |
1260 if (++next_read_ == field) return; | 1261 if (++next_read_ == field) return; |
1261 case kSourceUriIndex: | 1262 case kSourceUriIndex: |
1262 source_uri_index_ = builder_->ReadUInt(); // read source_uri_index. | 1263 source_uri_index_ = builder_->ReadUInt(); // read source_uri_index. |
1263 builder_->current_script_id_ = source_uri_index_; | 1264 builder_->current_script_id_ = source_uri_index_; |
1264 builder_->record_token_position(position_); | 1265 builder_->record_token_position(position_); |
1265 if (++next_read_ == field) return; | 1266 if (++next_read_ == field) return; |
| 1267 case kDocumentationCommentIndex: |
| 1268 builder_->ReadStringReference(); |
| 1269 if (++next_read_ == field) return; |
1266 case kAnnotations: { | 1270 case kAnnotations: { |
1267 annotation_count_ = builder_->ReadListLength(); // read list length. | 1271 annotation_count_ = builder_->ReadListLength(); // read list length. |
1268 for (intptr_t i = 0; i < annotation_count_; ++i) { | 1272 for (intptr_t i = 0; i < annotation_count_; ++i) { |
1269 builder_->SkipExpression(); // read ith expression. | 1273 builder_->SkipExpression(); // read ith expression. |
1270 } | 1274 } |
1271 if (++next_read_ == field) return; | 1275 if (++next_read_ == field) return; |
1272 } | 1276 } |
1273 case kTypeParameters: | 1277 case kTypeParameters: |
1274 builder_->SkipTypeParametersList(); // read type parameters. | 1278 builder_->SkipTypeParametersList(); // read type parameters. |
1275 if (++next_read_ == field) return; | 1279 if (++next_read_ == field) return; |
(...skipping 202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1478 private: | 1482 private: |
1479 Reader* reader_; | 1483 Reader* reader_; |
1480 intptr_t saved_offset_; | 1484 intptr_t saved_offset_; |
1481 }; | 1485 }; |
1482 | 1486 |
1483 } // namespace kernel | 1487 } // namespace kernel |
1484 } // namespace dart | 1488 } // namespace dart |
1485 | 1489 |
1486 #endif // !defined(DART_PRECOMPILED_RUNTIME) | 1490 #endif // !defined(DART_PRECOMPILED_RUNTIME) |
1487 #endif // RUNTIME_VM_KERNEL_BINARY_FLOWGRAPH_H_ | 1491 #endif // RUNTIME_VM_KERNEL_BINARY_FLOWGRAPH_H_ |
OLD | NEW |