Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(41)

Side by Side Diff: pkg/compiler/lib/src/common/resolution.dart

Issue 1970703002: Store ResolvedAst on AstElement (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: Updated cf. comments. Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « pkg/compiler/lib/src/common/codegen.dart ('k') | pkg/compiler/lib/src/compiler.dart » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 '../common.dart'; 7 import '../common.dart';
8 import '../compiler.dart' show Compiler; 8 import '../compiler.dart' show Compiler;
9 import '../constants/expressions.dart' show ConstantExpression; 9 import '../constants/expressions.dart' show ConstantExpression;
10 import '../core_types.dart' show CoreTypes; 10 import '../core_types.dart' show CoreTypes;
(...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after
184 } 184 }
185 185
186 String toString() { 186 String toString() {
187 return 'ListLiteralUse($type,isConstant:$isConstant,isEmpty:$isEmpty)'; 187 return 'ListLiteralUse($type,isConstant:$isConstant,isEmpty:$isEmpty)';
188 } 188 }
189 } 189 }
190 190
191 /// Interface for the accessing the front-end analysis. 191 /// Interface for the accessing the front-end analysis.
192 // TODO(johnniwinther): Find a better name for this. 192 // TODO(johnniwinther): Find a better name for this.
193 abstract class Frontend { 193 abstract class Frontend {
194 /// Returns `true` if [element] has a [ResolvedAst].
195 bool hasResolvedAst(ExecutableElement element);
196
197 /// Returns the `ResolvedAst` for the [element].
198 ResolvedAst getResolvedAst(ExecutableElement element);
199
200 /// Returns the [ResolutionImpact] for [element]. 194 /// Returns the [ResolutionImpact] for [element].
201 ResolutionImpact getResolutionImpact(Element element); 195 ResolutionImpact getResolutionImpact(Element element);
202 } 196 }
203 197
204 // TODO(johnniwinther): Rename to `Resolver` or `ResolverContext`. 198 // TODO(johnniwinther): Rename to `Resolver` or `ResolverContext`.
205 abstract class Resolution implements Frontend { 199 abstract class Resolution implements Frontend {
206 ParsingContext get parsingContext; 200 ParsingContext get parsingContext;
207 DiagnosticReporter get reporter; 201 DiagnosticReporter get reporter;
208 CoreTypes get coreTypes; 202 CoreTypes get coreTypes;
209 203
(...skipping 98 matching lines...) Expand 10 before | Expand all | Expand 10 after
308 if (cls.isPatch) { 302 if (cls.isPatch) {
309 patchParser.parsePatchClassNode(cls); 303 patchParser.parsePatchClassNode(cls);
310 } 304 }
311 }); 305 });
312 } 306 }
313 307
314 @override 308 @override
315 ScannerOptions getScannerOptionsFor(Element element) => new ScannerOptions( 309 ScannerOptions getScannerOptionsFor(Element element) => new ScannerOptions(
316 canUseNative: backend.canLibraryUseNative(element.library)); 310 canUseNative: backend.canLibraryUseNative(element.library));
317 } 311 }
OLDNEW
« no previous file with comments | « pkg/compiler/lib/src/common/codegen.dart ('k') | pkg/compiler/lib/src/compiler.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698