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

Side by Side Diff: pkg/dart2js_incremental/lib/caching_compiler.dart

Issue 2346053002: dart2js: fix tests after moving to .packages in the SDK repo (Closed)
Patch Set: Created 4 years, 3 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 | « no previous file | pkg/dart2js_incremental/lib/dart2js_incremental.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) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, 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 part of dart2js_incremental; 5 part of dart2js_incremental;
6 6
7 /// Do not call this method directly. It will be made private. 7 /// Do not call this method directly. It will be made private.
8 // TODO(ahe): Make this method private. 8 // TODO(ahe): Make this method private.
9 Future<CompilerImpl> reuseCompiler( 9 Future<CompilerImpl> reuseCompiler(
10 {CompilerDiagnostics diagnosticHandler, 10 {CompilerDiagnostics diagnosticHandler,
11 CompilerInput inputProvider, 11 CompilerInput inputProvider,
12 CompilerOutput outputProvider, 12 CompilerOutput outputProvider,
13 List<String> options: const [], 13 List<String> options: const [],
14 CompilerImpl cachedCompiler, 14 CompilerImpl cachedCompiler,
15 Uri libraryRoot, 15 Uri libraryRoot,
16 Uri packageRoot, 16 Uri packageRoot,
17 Uri packageConfig,
17 bool packagesAreImmutable: false, 18 bool packagesAreImmutable: false,
18 Map<String, dynamic> environment, 19 Map<String, dynamic> environment,
19 Future<bool> reuseLibrary(LibraryElement library)}) { 20 Future<bool> reuseLibrary(LibraryElement library)}) {
20 UserTag oldTag = new UserTag('_reuseCompiler').makeCurrent(); 21 UserTag oldTag = new UserTag('_reuseCompiler').makeCurrent();
21 if (libraryRoot == null) { 22 if (libraryRoot == null) {
22 throw 'Missing libraryRoot'; 23 throw 'Missing libraryRoot';
23 } 24 }
24 if (inputProvider == null) { 25 if (inputProvider == null) {
25 throw 'Missing inputProvider'; 26 throw 'Missing inputProvider';
26 } 27 }
(...skipping 26 matching lines...) Expand all
53 } 54 }
54 } 55 }
55 oldTag.makeCurrent(); 56 oldTag.makeCurrent();
56 compiler = new CompilerImpl( 57 compiler = new CompilerImpl(
57 inputProvider, 58 inputProvider,
58 outputProvider, 59 outputProvider,
59 diagnosticHandler, 60 diagnosticHandler,
60 new CompilerOptions.parse( 61 new CompilerOptions.parse(
61 libraryRoot: libraryRoot, 62 libraryRoot: libraryRoot,
62 packageRoot: packageRoot, 63 packageRoot: packageRoot,
64 packageConfig: packageConfig,
63 options: options, 65 options: options,
64 environment: environment)); 66 environment: environment));
65 JavaScriptBackend backend = compiler.backend; 67 JavaScriptBackend backend = compiler.backend;
66 68
67 full.Emitter emitter = backend.emitter.emitter; 69 full.Emitter emitter = backend.emitter.emitter;
68 70
69 // Much like a scout, an incremental compiler is always prepared. For 71 // Much like a scout, an incremental compiler is always prepared. For
70 // mixins, classes, and lazy statics, at least. 72 // mixins, classes, and lazy statics, at least.
71 emitter 73 emitter
72 ..needsClassSupport = true 74 ..needsClassSupport = true
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
187 final Map<String, String> output = new Map<String, String>(); 189 final Map<String, String> output = new Map<String, String>();
188 190
189 EventSink<String> createEventSink(String name, String extension) { 191 EventSink<String> createEventSink(String name, String extension) {
190 return new StringEventSink((String data) { 192 return new StringEventSink((String data) {
191 output['$name.$extension'] = data; 193 output['$name.$extension'] = data;
192 }); 194 });
193 } 195 }
194 196
195 String operator[] (String key) => output[key]; 197 String operator[] (String key) => output[key];
196 } 198 }
OLDNEW
« no previous file with comments | « no previous file | pkg/dart2js_incremental/lib/dart2js_incremental.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698