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

Unified Diff: tests/compiler/dart2js/analyze_helper.dart

Issue 17759007: First pass at asynchronous input loading in dart2js. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Updated cf. comments Created 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tests/compiler/dart2js/analyze_dart2js_test.dart ('k') | tests/compiler/dart2js/analyze_only_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/compiler/dart2js/analyze_helper.dart
diff --git a/tests/compiler/dart2js/analyze_helper.dart b/tests/compiler/dart2js/analyze_helper.dart
index a9c081df39e758ed31cfceed96514b76798719dd..3eee5f881953e5f9d49b556eecec53da2dced97a 100644
--- a/tests/compiler/dart2js/analyze_helper.dart
+++ b/tests/compiler/dart2js/analyze_helper.dart
@@ -5,6 +5,7 @@
library analyze_helper;
import "package:expect/expect.dart";
+import 'dart:async';
import 'dart:io';
import '../../../sdk/lib/_internal/compiler/compiler.dart' as api;
import '../../../sdk/lib/_internal/compiler/implementation/apiimpl.dart';
@@ -122,7 +123,7 @@ class CollectingDiagnosticHandler extends FormattingDiagnosticHandler {
}
}
-void analyze(List<Uri> uriList, Map<String, List<String>> whiteList) {
+Future analyze(List<Uri> uriList, Map<String, List<String>> whiteList) {
var libraryRoot = currentDirectory.resolve('sdk/');
var provider = new SourceFileProvider();
var handler = new CollectingDiagnosticHandler(whiteList, provider);
@@ -134,6 +135,7 @@ void analyze(List<Uri> uriList, Map<String, List<String>> whiteList) {
<String>['--analyze-only', '--analyze-all',
'--categories=Client,Server']);
compiler.librariesToAnalyzeWhenRun = uriList;
- compiler.run(null);
- handler.checkResults();
+ return compiler.run(null).then((_) {
+ handler.checkResults();
+ });
}
« no previous file with comments | « tests/compiler/dart2js/analyze_dart2js_test.dart ('k') | tests/compiler/dart2js/analyze_only_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698