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

Side by Side Diff: pkg/compiler/lib/src/universe/world_impact.dart

Issue 2366363002: Move remaining functionality from ClassWorld to ClosedWorld (Closed)
Patch Set: Created 4 years, 2 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.universe.world_impact; 5 library dart2js.universe.world_impact;
6 6
7 import '../elements/elements.dart' show Element; 7 import '../elements/elements.dart' show Element;
8 import '../util/util.dart' show Setlet; 8 import '../util/util.dart' show Setlet;
9 import 'use.dart' show DynamicUse, StaticUse, TypeUse; 9 import 'use.dart' show DynamicUse, StaticUse, TypeUse;
10 10
11 /// Describes how an element (e.g. a method) impacts the closed-world 11 /// Describes how an element (e.g. a method) impacts the closed-world
12 /// semantics of a program. 12 /// semantics of a program.
13 /// 13 ///
14 /// A [WorldImpact] contains information about how a program element affects our 14 /// A [WorldImpact] contains information about how a program element affects our
15 /// understanding of what's live in a program. For example, it can indicate 15 /// understanding of what's live in a program. For example, it can indicate
16 /// that a method uses a certain feature, or allocates a specific type. 16 /// that a method uses a certain feature, or allocates a specific type.
17 /// 17 ///
18 /// The impact object can be computed locally by inspecting just the resolution 18 /// The impact object can be computed locally by inspecting just the resolution
19 /// information of that element alone. The compiler uses [Universe] and 19 /// information of that element alone. The compiler uses [Universe] and
20 /// [ClassWorld] to combine the information discovered in the impact objects of 20 /// [World] to combine the information discovered in the impact objects of
21 /// all elements reachable in an application. 21 /// all elements reachable in an application.
22 class WorldImpact { 22 class WorldImpact {
23 const WorldImpact(); 23 const WorldImpact();
24 24
25 Iterable<DynamicUse> get dynamicUses => const <DynamicUse>[]; 25 Iterable<DynamicUse> get dynamicUses => const <DynamicUse>[];
26 26
27 Iterable<StaticUse> get staticUses => const <StaticUse>[]; 27 Iterable<StaticUse> get staticUses => const <StaticUse>[];
28 28
29 // TODO(johnniwinther): Replace this by called constructors with type 29 // TODO(johnniwinther): Replace this by called constructors with type
30 // arguments. 30 // arguments.
(...skipping 259 matching lines...) Expand 10 before | Expand all | Expand 10 after
290 } 290 }
291 } 291 }
292 292
293 @override 293 @override
294 void visitTypeUse(TypeUse use) { 294 void visitTypeUse(TypeUse use) {
295 if (_visitTypeUse != null) { 295 if (_visitTypeUse != null) {
296 _visitTypeUse(use); 296 _visitTypeUse(use);
297 } 297 }
298 } 298 }
299 } 299 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698