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.kernel.backend_strategy; | 5 library dart2js.kernel.backend_strategy; |
6 | 6 |
7 import 'package:kernel/ast.dart' as ir; | 7 import 'package:kernel/ast.dart' as ir; |
8 | 8 |
9 import '../backend_strategy.dart'; | 9 import '../backend_strategy.dart'; |
10 import '../closure.dart'; | 10 import '../closure.dart'; |
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
71 Sorter get sorter { | 71 Sorter get sorter { |
72 if (_sorter == null) { | 72 if (_sorter == null) { |
73 _sorter = new KernelSorter(elementMap); | 73 _sorter = new KernelSorter(elementMap); |
74 } | 74 } |
75 return _sorter; | 75 return _sorter; |
76 } | 76 } |
77 | 77 |
78 @override | 78 @override |
79 ClosureConversionTask get closureDataLookup => | 79 ClosureConversionTask get closureDataLookup => |
80 _closureDataLookup ??= new KernelClosureConversionTask( | 80 _closureDataLookup ??= new KernelClosureConversionTask( |
81 _compiler.measurer, elementMap, null, _globalLocalsMap); | 81 _compiler.measurer, elementMap, _globalLocalsMap); |
82 | 82 |
83 @override | 83 @override |
84 WorkItemBuilder createCodegenWorkItemBuilder(ClosedWorld closedWorld) { | 84 WorkItemBuilder createCodegenWorkItemBuilder(ClosedWorld closedWorld) { |
85 return new KernelCodegenWorkItemBuilder(_compiler.backend, closedWorld); | 85 return new KernelCodegenWorkItemBuilder(_compiler.backend, closedWorld); |
86 } | 86 } |
87 | 87 |
88 @override | 88 @override |
89 CodegenWorldBuilder createCodegenWorldBuilder( | 89 CodegenWorldBuilder createCodegenWorldBuilder( |
90 NativeBasicData nativeBasicData, | 90 NativeBasicData nativeBasicData, |
91 ClosedWorld closedWorld, | 91 ClosedWorld closedWorld, |
(...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
306 Iterable<ClassEntity> sortClasses(Iterable<ClassEntity> classes) { | 306 Iterable<ClassEntity> sortClasses(Iterable<ClassEntity> classes) { |
307 return classes.toList() | 307 return classes.toList() |
308 ..sort((ClassEntity a, ClassEntity b) { | 308 ..sort((ClassEntity a, ClassEntity b) { |
309 int r = _compareLibraries(a.library, b.library); | 309 int r = _compareLibraries(a.library, b.library); |
310 if (r != 0) return r; | 310 if (r != 0) return r; |
311 return _compareNodes( | 311 return _compareNodes( |
312 a, elementMap.getClassNode(a), b, elementMap.getClassNode(b)); | 312 a, elementMap.getClassNode(a), b, elementMap.getClassNode(b)); |
313 }); | 313 }); |
314 } | 314 } |
315 } | 315 } |
OLD | NEW |