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

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

Issue 564373004: Add LibraryLoader.resetAsync. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge
Patch Set: Restore code. Created 6 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, 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_incremental; 5 library dart2js_incremental;
6 6
7 import 'dart:async' show 7 import 'dart:async' show
8 Future; 8 Future;
9 9
10 import 'dart:profiler' show 10 import 'dart:profiler' show
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 throw new ArgumentError('inputProvider is null.'); 62 throw new ArgumentError('inputProvider is null.');
63 } 63 }
64 if (diagnosticHandler == null) { 64 if (diagnosticHandler == null) {
65 throw new ArgumentError('diagnosticHandler is null.'); 65 throw new ArgumentError('diagnosticHandler is null.');
66 } 66 }
67 } 67 }
68 68
69 Future<bool> compile(Uri script) { 69 Future<bool> compile(Uri script) {
70 List<String> options = new List<String>.from(this.options); 70 List<String> options = new List<String>.from(this.options);
71 options.addAll(INCREMENTAL_OPTIONS); 71 options.addAll(INCREMENTAL_OPTIONS);
72 _compiler = reuseCompiler( 72 Future<Compiler> future = reuseCompiler(
73 cachedCompiler: _compiler, 73 cachedCompiler: _compiler,
74 libraryRoot: libraryRoot, 74 libraryRoot: libraryRoot,
75 packageRoot: packageRoot, 75 packageRoot: packageRoot,
76 inputProvider: inputProvider, 76 inputProvider: inputProvider,
77 diagnosticHandler: diagnosticHandler, 77 diagnosticHandler: diagnosticHandler,
78 options: options, 78 options: options,
79 outputProvider: outputProvider, 79 outputProvider: outputProvider,
80 environment: environment); 80 environment: environment);
81 return _compiler.run(script); 81 return future.then((Compiler compiler) {
82 _compiler = compiler;
83 return compiler.run(script);
84 });
82 } 85 }
83 } 86 }
OLDNEW
« no previous file with comments | « dart/pkg/dart2js_incremental/lib/caching_compiler.dart ('k') | dart/sdk/lib/_internal/compiler/implementation/compiler.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698