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

Side by Side Diff: pkg/compiler/lib/src/serialization/serialization.dart

Issue 2647043002: Fix hints reported by analyzer. (Closed)
Patch Set: Created 3 years, 11 months 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2015, 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 library dart2js.serialization; 5 library dart2js.serialization;
6 6
7 import '../common.dart'; 7 import '../common.dart';
8 import '../common/resolution.dart'; 8 import '../common/resolution.dart';
9 import '../constants/expressions.dart'; 9 import '../constants/expressions.dart';
10 import '../elements/resolution_types.dart'; 10 import '../elements/resolution_types.dart';
(...skipping 641 matching lines...) Expand 10 before | Expand all | Expand 10 after
652 /// {...}, // [ObjectValue] of the 0th [ConstantExpression]. 652 /// {...}, // [ObjectValue] of the 0th [ConstantExpression].
653 /// ... 653 /// ...
654 /// {...}, // [ObjectValue] of the n-th [ConstantExpression]. 654 /// {...}, // [ObjectValue] of the n-th [ConstantExpression].
655 /// ], 655 /// ],
656 /// } 656 /// }
657 /// 657 ///
658 // TODO(johnniwinther): Support dependencies between serialized subcomponent. 658 // TODO(johnniwinther): Support dependencies between serialized subcomponent.
659 class Serializer { 659 class Serializer {
660 List<SerializerPlugin> plugins = <SerializerPlugin>[]; 660 List<SerializerPlugin> plugins = <SerializerPlugin>[];
661 661
662 Map<Uri, dynamic> _dependencyMap = <Uri, dynamic>{};
663 Map<Element, DataObject> _elementMap = <Element, DataObject>{}; 662 Map<Element, DataObject> _elementMap = <Element, DataObject>{};
664 Map<ConstantExpression, DataObject> _constantMap = 663 Map<ConstantExpression, DataObject> _constantMap =
665 <ConstantExpression, DataObject>{}; 664 <ConstantExpression, DataObject>{};
666 Map<ResolutionDartType, DataObject> _typeMap = 665 Map<ResolutionDartType, DataObject> _typeMap =
667 <ResolutionDartType, DataObject>{}; 666 <ResolutionDartType, DataObject>{};
668 List _pendingList = []; 667 List _pendingList = [];
669 ElementMatcher shouldInclude; 668 ElementMatcher shouldInclude;
670 669
671 // TODO(johnniwinther): Replace [includeElement] with a general strategy. 670 // TODO(johnniwinther): Replace [includeElement] with a general strategy.
672 Serializer({this.shouldInclude: includeAllElements}); 671 Serializer({this.shouldInclude: includeAllElements});
(...skipping 467 matching lines...) Expand 10 before | Expand all | Expand 10 after
1140 1139
1141 /// Returns the value used to store [key] as a property in the encoding an 1140 /// Returns the value used to store [key] as a property in the encoding an
1142 /// [ObjectValue]. 1141 /// [ObjectValue].
1143 /// 1142 ///
1144 /// Different encodings have different restrictions and capabilities as how 1143 /// Different encodings have different restrictions and capabilities as how
1145 /// to store a [Key] value. For instance: A JSON encoding needs to convert 1144 /// to store a [Key] value. For instance: A JSON encoding needs to convert
1146 /// [Key] to a [String] to store it in a JSON object; a Dart encoding can 1145 /// [Key] to a [String] to store it in a JSON object; a Dart encoding can
1147 /// choose to store a [Key] as an [int] or as the [Key] itself. 1146 /// choose to store a [Key] as an [int] or as the [Key] itself.
1148 getObjectPropertyValue(Key key); 1147 getObjectPropertyValue(Key key);
1149 } 1148 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698