| 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.common.resolution; | 5 library dart2js.common.resolution; |
| 6 | 6 |
| 7 import '../compiler.dart' show | 7 import '../compiler.dart' show |
| 8 Compiler; | 8 Compiler; |
| 9 import '../dart_types.dart' show | 9 import '../dart_types.dart' show |
| 10 DartType; | 10 DartType; |
| (...skipping 23 matching lines...) Expand all Loading... |
| 34 WorldImpact impact = compiler.analyze(this, world); | 34 WorldImpact impact = compiler.analyze(this, world); |
| 35 _isAnalyzed = true; | 35 _isAnalyzed = true; |
| 36 return impact; | 36 return impact; |
| 37 } | 37 } |
| 38 | 38 |
| 39 bool get isAnalyzed => _isAnalyzed; | 39 bool get isAnalyzed => _isAnalyzed; |
| 40 } | 40 } |
| 41 | 41 |
| 42 /// Backend callbacks function specific to the resolution phase. | 42 /// Backend callbacks function specific to the resolution phase. |
| 43 class ResolutionCallbacks { | 43 class ResolutionCallbacks { |
| 44 /// Register that [node] is a call to `assert`. | 44 /// Register that an assert has been seen. |
| 45 void onAssert(Send node, Registry registry) {} | 45 void onAssert(Registry registry) {} |
| 46 | 46 |
| 47 /// Register that an 'await for' has been seen. | 47 /// Register that an 'await for' has been seen. |
| 48 void onAsyncForIn(AsyncForIn node, Registry registry) {} | 48 void onAsyncForIn(AsyncForIn node, Registry registry) {} |
| 49 | 49 |
| 50 /// Called during resolution to notify to the backend that the | 50 /// Called during resolution to notify to the backend that the |
| 51 /// program uses string interpolation. | 51 /// program uses string interpolation. |
| 52 void onStringInterpolation(Registry registry) {} | 52 void onStringInterpolation(Registry registry) {} |
| 53 | 53 |
| 54 /// Called during resolution to notify to the backend that the | 54 /// Called during resolution to notify to the backend that the |
| 55 /// program has a catch statement. | 55 /// program has a catch statement. |
| (...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 104 /// Register that a super call will end up calling | 104 /// Register that a super call will end up calling |
| 105 /// [: super.noSuchMethod :]. | 105 /// [: super.noSuchMethod :]. |
| 106 void onSuperNoSuchMethod(Registry registry) {} | 106 void onSuperNoSuchMethod(Registry registry) {} |
| 107 | 107 |
| 108 /// Register that the application creates a constant map. | 108 /// Register that the application creates a constant map. |
| 109 void onMapLiteral(Registry registry, DartType type, bool isConstant) {} | 109 void onMapLiteral(Registry registry, DartType type, bool isConstant) {} |
| 110 | 110 |
| 111 /// Called when resolving the `Symbol` constructor. | 111 /// Called when resolving the `Symbol` constructor. |
| 112 void onSymbolConstructor(Registry registry) {} | 112 void onSymbolConstructor(Registry registry) {} |
| 113 } | 113 } |
| OLD | NEW |