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 library dart2js.js_backend.element_strategy; | 5 library dart2js.js_backend.element_strategy; |
6 | 6 |
7 import '../backend_strategy.dart'; | 7 import '../backend_strategy.dart'; |
8 import '../common.dart'; | 8 import '../common.dart'; |
9 import '../common/codegen.dart'; | 9 import '../common/codegen.dart'; |
10 import '../common/work.dart'; | 10 import '../common/work.dart'; |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
43 | 43 |
44 void convertClosures(ClosedWorldRefiner closedWorldRefiner) { | 44 void convertClosures(ClosedWorldRefiner closedWorldRefiner) { |
45 _compiler.closureToClassMapper.createClosureClasses(closedWorldRefiner); | 45 _compiler.closureToClassMapper.createClosureClasses(closedWorldRefiner); |
46 } | 46 } |
47 | 47 |
48 @override | 48 @override |
49 CodegenWorldBuilder createCodegenWorldBuilder( | 49 CodegenWorldBuilder createCodegenWorldBuilder( |
50 NativeBasicData nativeBasicData, | 50 NativeBasicData nativeBasicData, |
51 ClosedWorld closedWorld, | 51 ClosedWorld closedWorld, |
52 SelectorConstraintsStrategy selectorConstraintsStrategy) { | 52 SelectorConstraintsStrategy selectorConstraintsStrategy) { |
53 return new ElementCodegenWorldBuilderImpl(_compiler.elementEnvironment, | 53 return new ElementCodegenWorldBuilderImpl(closedWorld.elementEnvironment, |
54 nativeBasicData, closedWorld, selectorConstraintsStrategy); | 54 nativeBasicData, closedWorld, selectorConstraintsStrategy); |
55 } | 55 } |
56 | 56 |
57 @override | 57 @override |
58 WorkItemBuilder createCodegenWorkItemBuilder(ClosedWorld closedWorld) { | 58 WorkItemBuilder createCodegenWorkItemBuilder(ClosedWorld closedWorld) { |
59 return new ElementCodegenWorkItemBuilder( | 59 return new ElementCodegenWorkItemBuilder( |
60 _compiler.backend, closedWorld, _compiler.options); | 60 _compiler.backend, closedWorld, _compiler.options); |
61 } | 61 } |
62 | 62 |
63 @override | 63 @override |
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
153 | 153 |
154 MemberElement get element => resolvedAst.element; | 154 MemberElement get element => resolvedAst.element; |
155 | 155 |
156 WorldImpact run() { | 156 WorldImpact run() { |
157 registry = new CodegenRegistry(element); | 157 registry = new CodegenRegistry(element); |
158 return _backend.codegen(this, _closedWorld); | 158 return _backend.codegen(this, _closedWorld); |
159 } | 159 } |
160 | 160 |
161 String toString() => 'CodegenWorkItem(${resolvedAst.element})'; | 161 String toString() => 'CodegenWorkItem(${resolvedAst.element})'; |
162 } | 162 } |
OLD | NEW |