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

Side by Side Diff: pkg/compiler/lib/src/js_backend/lookup_map_analysis.dart

Issue 2647043002: Fix hints reported by analyzer. (Closed)
Patch Set: Address review comments. 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 /// Analysis to determine how to generate code for `LookupMap`s. 5 /// Analysis to determine how to generate code for `LookupMap`s.
6 library compiler.src.js_backend.lookup_map_analysis; 6 library compiler.src.js_backend.lookup_map_analysis;
7 7
8 import 'package:pub_semver/pub_semver.dart'; 8 import 'package:pub_semver/pub_semver.dart';
9 9
10 import '../common.dart'; 10 import '../common.dart';
11 import '../compiler.dart' show Compiler; 11 import '../compiler.dart' show Compiler;
12 import '../constants/values.dart' 12 import '../constants/values.dart'
13 show 13 show
14 ConstantValue, 14 ConstantValue,
15 ConstructedConstantValue, 15 ConstructedConstantValue,
16 ListConstantValue, 16 ListConstantValue,
17 NullConstantValue, 17 NullConstantValue,
18 StringConstantValue, 18 StringConstantValue,
19 TypeConstantValue; 19 TypeConstantValue;
20 import '../elements/resolution_types.dart' show ResolutionDartType;
21 import '../elements/resolution_types.dart' show ResolutionInterfaceType; 20 import '../elements/resolution_types.dart' show ResolutionInterfaceType;
22 import '../elements/elements.dart' 21 import '../elements/elements.dart'
23 show ClassElement, FieldElement, LibraryElement, VariableElement; 22 show ClassElement, FieldElement, LibraryElement, VariableElement;
24 import '../universe/use.dart' show StaticUse; 23 import '../universe/use.dart' show StaticUse;
25 import '../universe/world_impact.dart' 24 import '../universe/world_impact.dart'
26 show WorldImpact, StagedWorldImpactBuilder; 25 show WorldImpact, StagedWorldImpactBuilder;
27 import 'js_backend.dart' show JavaScriptBackend; 26 import 'js_backend.dart' show JavaScriptBackend;
28 27
29 /// An analysis and optimization to remove unused entries from a `LookupMap`. 28 /// An analysis and optimization to remove unused entries from a `LookupMap`.
30 /// 29 ///
(...skipping 417 matching lines...) Expand 10 before | Expand all | Expand 10 after
448 original.fields[analysis.valueField] = keyValuePairs[1]; 447 original.fields[analysis.valueField] = keyValuePairs[1];
449 } 448 }
450 } else { 449 } else {
451 original.fields[analysis.entriesField] = 450 original.fields[analysis.entriesField] =
452 new ListConstantValue(listType, keyValuePairs); 451 new ListConstantValue(listType, keyValuePairs);
453 } 452 }
454 } 453 }
455 } 454 }
456 455
457 final _validLookupMapVersionConstraint = new VersionConstraint.parse('^0.0.1'); 456 final _validLookupMapVersionConstraint = new VersionConstraint.parse('^0.0.1');
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/js_backend/custom_elements_analysis.dart ('k') | pkg/compiler/lib/src/js_backend/minify_namer.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698