| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, 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.backend_api; | 5 library dart2js.backend_api; |
| 6 | 6 |
| 7 import 'dart:async' show Future; | 7 import 'dart:async' show Future; |
| 8 | 8 |
| 9 import '../common.dart'; | 9 import '../common.dart'; |
| 10 import '../common/codegen.dart' show CodegenImpact; | 10 import '../common/codegen.dart' show CodegenImpact; |
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 96 // default, so tools like dart2dart can ignore the native classes. | 96 // default, so tools like dart2dart can ignore the native classes. |
| 97 native.NativeEnqueuer nativeResolutionEnqueuer() { | 97 native.NativeEnqueuer nativeResolutionEnqueuer() { |
| 98 return new native.NativeEnqueuer(); | 98 return new native.NativeEnqueuer(); |
| 99 } | 99 } |
| 100 | 100 |
| 101 native.NativeEnqueuer nativeCodegenEnqueuer() { | 101 native.NativeEnqueuer nativeCodegenEnqueuer() { |
| 102 return new native.NativeEnqueuer(); | 102 return new native.NativeEnqueuer(); |
| 103 } | 103 } |
| 104 | 104 |
| 105 /// Generates the output and returns the total size of the generated code. | 105 /// Generates the output and returns the total size of the generated code. |
| 106 int assembleProgram(); | 106 int assembleProgram(ClosedWorld closedWorld); |
| 107 | 107 |
| 108 List<CompilerTask> get tasks; | 108 List<CompilerTask> get tasks; |
| 109 | 109 |
| 110 void onResolutionComplete( | 110 void onResolutionComplete( |
| 111 ClosedWorld closedWorld, ClosedWorldRefiner closedWorldRefiner) {} | 111 ClosedWorld closedWorld, ClosedWorldRefiner closedWorldRefiner) {} |
| 112 void onTypeInferenceComplete() {} | 112 void onTypeInferenceComplete() {} |
| 113 | 113 |
| 114 bool classNeedsRti(ClassElement cls); | 114 bool classNeedsRti(ClassElement cls); |
| 115 bool methodNeedsRti(FunctionElement function); | 115 bool methodNeedsRti(FunctionElement function); |
| 116 | 116 |
| (...skipping 187 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 304 bool onQueueEmpty(Enqueuer enqueuer, Iterable<ClassEntity> recentClasses) { | 304 bool onQueueEmpty(Enqueuer enqueuer, Iterable<ClassEntity> recentClasses) { |
| 305 return true; | 305 return true; |
| 306 } | 306 } |
| 307 | 307 |
| 308 /// Called after the queue is closed. [onQueueEmpty] may be called multiple | 308 /// Called after the queue is closed. [onQueueEmpty] may be called multiple |
| 309 /// times, but [onQueueClosed] is only called once. | 309 /// times, but [onQueueClosed] is only called once. |
| 310 void onQueueClosed() {} | 310 void onQueueClosed() {} |
| 311 | 311 |
| 312 /// Called when the compiler starts running the codegen enqueuer. The | 312 /// Called when the compiler starts running the codegen enqueuer. The |
| 313 /// [WorldImpact] of enabled backend features is returned. | 313 /// [WorldImpact] of enabled backend features is returned. |
| 314 WorldImpact onCodegenStart() => const WorldImpact(); | 314 WorldImpact onCodegenStart(ClosedWorld closedWorld) => const WorldImpact(); |
| 315 | 315 |
| 316 // Does this element belong in the output | 316 // Does this element belong in the output |
| 317 bool shouldOutput(Element element) => true; | 317 bool shouldOutput(Element element) => true; |
| 318 | 318 |
| 319 FunctionElement helperForBadMain() => null; | 319 FunctionElement helperForBadMain() => null; |
| 320 | 320 |
| 321 FunctionElement helperForMissingMain() => null; | 321 FunctionElement helperForMissingMain() => null; |
| 322 | 322 |
| 323 FunctionElement helperForMainArity() => null; | 323 FunctionElement helperForMainArity() => null; |
| 324 | 324 |
| (...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 416 ClassElement get asyncFutureImplementation; | 416 ClassElement get asyncFutureImplementation; |
| 417 ClassElement get asyncStarStreamImplementation; | 417 ClassElement get asyncStarStreamImplementation; |
| 418 ClassElement get indexableImplementation; | 418 ClassElement get indexableImplementation; |
| 419 ClassElement get mutableIndexableImplementation; | 419 ClassElement get mutableIndexableImplementation; |
| 420 ClassElement get indexingBehaviorImplementation; | 420 ClassElement get indexingBehaviorImplementation; |
| 421 | 421 |
| 422 bool isDefaultEqualityImplementation(Element element); | 422 bool isDefaultEqualityImplementation(Element element); |
| 423 bool isInterceptorClass(ClassElement cls); | 423 bool isInterceptorClass(ClassElement cls); |
| 424 bool isNative(Element element); | 424 bool isNative(Element element); |
| 425 } | 425 } |
| OLD | NEW |