| 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 '../compiler.dart' show | 9 import '../compiler.dart' show |
| 10 Compiler; | 10 Compiler; |
| (...skipping 325 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 336 /// [recentClasses], but every class seen by the [enqueuer] will be present in | 336 /// [recentClasses], but every class seen by the [enqueuer] will be present in |
| 337 /// [recentClasses] at least once. | 337 /// [recentClasses] at least once. |
| 338 bool onQueueEmpty(Enqueuer enqueuer, Iterable<ClassElement> recentClasses) { | 338 bool onQueueEmpty(Enqueuer enqueuer, Iterable<ClassElement> recentClasses) { |
| 339 return true; | 339 return true; |
| 340 } | 340 } |
| 341 | 341 |
| 342 /// Called after the queue is closed. [onQueueEmpty] may be called multiple | 342 /// Called after the queue is closed. [onQueueEmpty] may be called multiple |
| 343 /// times, but [onQueueClosed] is only called once. | 343 /// times, but [onQueueClosed] is only called once. |
| 344 void onQueueClosed() {} | 344 void onQueueClosed() {} |
| 345 | 345 |
| 346 /// Called when the compiler starts running the codegen enqueuer. |
| 347 void onCodegenStart() {} |
| 348 |
| 346 /// Called after [element] has been resolved. | 349 /// Called after [element] has been resolved. |
| 347 // TODO(johnniwinther): Change [TreeElements] to [Registry] or a dependency | 350 // TODO(johnniwinther): Change [TreeElements] to [Registry] or a dependency |
| 348 // node. [elements] is currently unused by the implementation. | 351 // node. [elements] is currently unused by the implementation. |
| 349 void onElementResolved(Element element, TreeElements elements) {} | 352 void onElementResolved(Element element, TreeElements elements) {} |
| 350 | 353 |
| 351 // Does this element belong in the output | 354 // Does this element belong in the output |
| 352 bool shouldOutput(Element element) => true; | 355 bool shouldOutput(Element element) => true; |
| 353 | 356 |
| 354 FunctionElement helperForBadMain() => null; | 357 FunctionElement helperForBadMain() => null; |
| 355 | 358 |
| 356 FunctionElement helperForMissingMain() => null; | 359 FunctionElement helperForMissingMain() => null; |
| 357 | 360 |
| 358 FunctionElement helperForMainArity() => null; | 361 FunctionElement helperForMainArity() => null; |
| 359 | 362 |
| 360 void forgetElement(Element element) {} | 363 void forgetElement(Element element) {} |
| 361 | 364 |
| 362 void registerMainHasArguments(Enqueuer enqueuer) {} | 365 void registerMainHasArguments(Enqueuer enqueuer) {} |
| 363 | 366 |
| 364 void registerAsyncMarker(FunctionElement element, | 367 void registerAsyncMarker(FunctionElement element, |
| 365 Enqueuer enqueuer, | 368 Enqueuer enqueuer, |
| 366 Registry registry) {} | 369 Registry registry) {} |
| 367 } | 370 } |
| 368 | 371 |
| OLD | NEW |