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

Side by Side Diff: pkg/front_end/lib/src/fasta/analyzer/analyzer_loader.dart

Issue 2756593004: Start unraveling circularities between analyzer and front_end/kernel. (Closed)
Patch Set: Created 3 years, 9 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
OLDNEW
1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2017, 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 fasta.analyzer_loader; 5 library fasta.analyzer_loader;
6 6
7 import 'package:kernel/ast.dart' show Program; 7 import 'package:kernel/ast.dart' show Program;
8 8
9 import '../builder/builder.dart' show LibraryBuilder; 9 import '../builder/builder.dart' show LibraryBuilder;
10 10
11 import '../target_implementation.dart' show TargetImplementation; 11 import '../target_implementation.dart' show TargetImplementation;
12 12
13 import '../source/source_loader.dart' show SourceLoader; 13 import '../source/source_loader.dart' show SourceLoader;
14 14
15 import 'element_store.dart' show ElementStore; 15 import 'package:analyzer/src/fasta/element_store.dart' show ElementStore;
16 16
17 import 'analyzer_diet_listener.dart' show AnalyzerDietListener; 17 import 'analyzer_diet_listener.dart' show AnalyzerDietListener;
18 18
19 class AnalyzerLoader<L> extends SourceLoader<L> { 19 class AnalyzerLoader<L> extends SourceLoader<L> {
20 ElementStore elementStore; 20 ElementStore elementStore;
21 21
22 AnalyzerLoader(TargetImplementation target) : super(target); 22 AnalyzerLoader(TargetImplementation target) : super(target);
23 23
24 @override 24 @override
25 void computeHierarchy(Program program) { 25 void computeHierarchy(Program program) {
26 elementStore = new ElementStore(coreLibrary, builders); 26 elementStore = new ElementStore(coreLibrary, builders);
27 ticker.logMs("Built analyzer element model."); 27 ticker.logMs("Built analyzer element model.");
28 } 28 }
29 29
30 @override 30 @override
31 AnalyzerDietListener createDietListener(LibraryBuilder library) { 31 AnalyzerDietListener createDietListener(LibraryBuilder library) {
32 return new AnalyzerDietListener(library, elementStore); 32 return new AnalyzerDietListener(library, elementStore);
33 } 33 }
34 } 34 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698