OLD | NEW |
1 | 1 |
2 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 2 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
3 // for details. All rights reserved. Use of this source code is governed by a | 3 // for details. All rights reserved. Use of this source code is governed by a |
4 // BSD-style license that can be found in the LICENSE file. | 4 // BSD-style license that can be found in the LICENSE file. |
5 | 5 |
6 library dart2js.common.resolution; | 6 library dart2js.common.resolution; |
7 | 7 |
8 import '../common.dart'; | 8 import '../common.dart'; |
9 import '../compiler.dart' show | 9 import '../compiler.dart' show |
10 Compiler; | 10 Compiler; |
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
179 return 'ListLiteralUse($type,isConstant:$isConstant,isEmpty:$isEmpty)'; | 179 return 'ListLiteralUse($type,isConstant:$isConstant,isEmpty:$isEmpty)'; |
180 } | 180 } |
181 } | 181 } |
182 | 182 |
183 // TODO(johnniwinther): Rename to `Resolver` or `ResolverContext`. | 183 // TODO(johnniwinther): Rename to `Resolver` or `ResolverContext`. |
184 abstract class Resolution { | 184 abstract class Resolution { |
185 Parsing get parsing; | 185 Parsing get parsing; |
186 DiagnosticReporter get reporter; | 186 DiagnosticReporter get reporter; |
187 CoreTypes get coreTypes; | 187 CoreTypes get coreTypes; |
188 | 188 |
189 bool retainCaches; | 189 /// If set to `true` resolution caches will not be cleared. Use this only for |
| 190 /// testing. |
| 191 bool retainCachesForTesting; |
190 | 192 |
191 void resolveTypedef(TypedefElement typdef); | 193 void resolveTypedef(TypedefElement typdef); |
192 void resolveClass(ClassElement cls); | 194 void resolveClass(ClassElement cls); |
193 void registerClass(ClassElement cls); | 195 void registerClass(ClassElement cls); |
194 void resolveMetadataAnnotation(MetadataAnnotation metadataAnnotation); | 196 void resolveMetadataAnnotation(MetadataAnnotation metadataAnnotation); |
195 FunctionSignature resolveSignature(FunctionElement function); | 197 FunctionSignature resolveSignature(FunctionElement function); |
196 DartType resolveTypeAnnotation(Element element, TypeAnnotation node); | 198 DartType resolveTypeAnnotation(Element element, TypeAnnotation node); |
197 | 199 |
198 bool hasBeenResolved(Element element); | 200 bool hasBeenResolved(Element element); |
199 | 201 |
(...skipping 22 matching lines...) Expand all Loading... |
222 void emptyCache(); | 224 void emptyCache(); |
223 } | 225 } |
224 | 226 |
225 // TODO(johnniwinther): Rename to `Parser` or `ParsingContext`. | 227 // TODO(johnniwinther): Rename to `Parser` or `ParsingContext`. |
226 abstract class Parsing { | 228 abstract class Parsing { |
227 DiagnosticReporter get reporter; | 229 DiagnosticReporter get reporter; |
228 void parsePatchClass(ClassElement cls); | 230 void parsePatchClass(ClassElement cls); |
229 measure(f()); | 231 measure(f()); |
230 ScannerOptions getScannerOptionsFor(Element element); | 232 ScannerOptions getScannerOptionsFor(Element element); |
231 } | 233 } |
OLD | NEW |