| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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 compiler.src.inferrer.closure_tracer; | 5 library compiler.src.inferrer.closure_tracer; |
| 6 | 6 |
| 7 import '../types/types.dart' show TypeMask; | |
| 8 import '../common/names.dart' show Names; | 7 import '../common/names.dart' show Names; |
| 9 import '../elements/elements.dart'; | 8 import '../elements/elements.dart'; |
| 9 import '../types/types.dart' show TypeMask; |
| 10 import '../universe/selector.dart' show Selector; | 10 import '../universe/selector.dart' show Selector; |
| 11 import 'debug.dart' as debug; |
| 11 import 'node_tracer.dart'; | 12 import 'node_tracer.dart'; |
| 12 import 'type_graph_nodes.dart'; | 13 import 'type_graph_nodes.dart'; |
| 13 import 'debug.dart' as debug; | |
| 14 | 14 |
| 15 class ClosureTracerVisitor extends TracerVisitor<ApplyableTypeInformation> { | 15 class ClosureTracerVisitor extends TracerVisitor<ApplyableTypeInformation> { |
| 16 final Iterable<FunctionElement> tracedElements; | 16 final Iterable<FunctionElement> tracedElements; |
| 17 final List<CallSiteTypeInformation> _callsToAnalyze = | 17 final List<CallSiteTypeInformation> _callsToAnalyze = |
| 18 new List<CallSiteTypeInformation>(); | 18 new List<CallSiteTypeInformation>(); |
| 19 | 19 |
| 20 ClosureTracerVisitor(this.tracedElements, tracedType, inferrer) | 20 ClosureTracerVisitor(this.tracedElements, tracedType, inferrer) |
| 21 : super(tracedType, inferrer); | 21 : super(tracedType, inferrer); |
| 22 | 22 |
| 23 void run() { | 23 void run() { |
| (...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 125 @override | 125 @override |
| 126 visitStaticCallSiteTypeInformation(StaticCallSiteTypeInformation info) { | 126 visitStaticCallSiteTypeInformation(StaticCallSiteTypeInformation info) { |
| 127 super.visitStaticCallSiteTypeInformation(info); | 127 super.visitStaticCallSiteTypeInformation(info); |
| 128 if (info.calledElement == tracedElements.first && | 128 if (info.calledElement == tracedElements.first && |
| 129 info.selector != null && | 129 info.selector != null && |
| 130 info.selector.isGetter) { | 130 info.selector.isGetter) { |
| 131 addNewEscapeInformation(info); | 131 addNewEscapeInformation(info); |
| 132 } | 132 } |
| 133 } | 133 } |
| 134 } | 134 } |
| OLD | NEW |