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

Side by Side Diff: pkg/front_end/lib/src/fasta/dill/dill_loader.dart

Issue 2723113002: Consolidate analyzer dependencies. (Closed)
Patch Set: Remove new dependency on AsyncMarker. 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) 2016, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2016, 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.dill_loader; 5 library fasta.dill_loader;
6 6
7 import 'dart:async' show Future; 7 import 'dart:async' show Future;
8 8
9 import 'dart:io' show File; 9 import 'dart:io' show File;
10 10
(...skipping 19 matching lines...) Expand all
30 Future<Null> buildOutline(DillLibraryBuilder builder) async { 30 Future<Null> buildOutline(DillLibraryBuilder builder) async {
31 if (program == null) { 31 if (program == null) {
32 byteCount = await new File.fromUri(input).length(); 32 byteCount = await new File.fromUri(input).length();
33 setProgram(await loadProgramFromBinary(input.toFilePath())); 33 setProgram(await loadProgramFromBinary(input.toFilePath()));
34 } 34 }
35 builder.library.classes.forEach(builder.addClass); 35 builder.library.classes.forEach(builder.addClass);
36 builder.library.procedures.forEach(builder.addMember); 36 builder.library.procedures.forEach(builder.addMember);
37 builder.library.fields.forEach(builder.addMember); 37 builder.library.fields.forEach(builder.addMember);
38 } 38 }
39 39
40 Future<Null> buildBody(DillLibraryBuilder builder, _) { 40 Future<Null> buildBody(DillLibraryBuilder builder) {
41 return buildOutline(builder); 41 return buildOutline(builder);
42 } 42 }
43 43
44 void setProgram(Program program) { 44 void setProgram(Program program) {
45 assert(input != null); 45 assert(input != null);
46 this.program = program; 46 this.program = program;
47 program.unbindCanonicalNames(); 47 program.unbindCanonicalNames();
48 for (Library library in program.libraries) { 48 for (Library library in program.libraries) {
49 read(library.importUri).library = library; 49 read(library.importUri).library = library;
50 } 50 }
51 } 51 }
52 } 52 }
OLDNEW
« no previous file with comments | « pkg/front_end/lib/src/fasta/compile_platform_dartk.dart ('k') | pkg/front_end/lib/src/fasta/dill/dill_target.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698