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

Unified Diff: pkg/analyzer/lib/src/task/driver.dart

Issue 1053673008: Initial re-write of analysis context for the new task model (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 5 years, 8 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
Index: pkg/analyzer/lib/src/task/driver.dart
diff --git a/pkg/analyzer/lib/src/task/driver.dart b/pkg/analyzer/lib/src/task/driver.dart
index 2fea201c9c4a93afc5a237621930a5bd51a29e17..8f9641bcbc759ebc780b94cad4a7ae3bdb1fa958 100644
--- a/pkg/analyzer/lib/src/task/driver.dart
+++ b/pkg/analyzer/lib/src/task/driver.dart
@@ -28,7 +28,7 @@ class AnalysisDriver {
/**
* The context in which analysis is to be performed.
*/
- final ExtendedAnalysisContext context;
+ final InternalAnalysisContext context;
/**
* The work order that was previously computed but that has not yet been
@@ -123,8 +123,14 @@ class AnalysisDriver {
state == CacheState.IN_PROCESS) {
return null;
}
- return new WorkOrder(taskManager,
- new WorkItem(context, target, taskManager.findTask(target, result)));
+ try {
+ return new WorkOrder(taskManager,
+ new WorkItem(context, target, taskManager.findTask(target, result)));
+ } catch (exception, stackTrace) {
+ throw new AnalysisException(
+ 'Could not create work order (target = $target; result = $result)',
+ new CaughtException(exception, stackTrace));
+ }
}
/**
@@ -260,7 +266,7 @@ class WorkItem {
/**
* The context in which the task will be performed.
*/
- final ExtendedAnalysisContext context;
+ final InternalAnalysisContext context;
/**
* The target for which a task is to be performed.

Powered by Google App Engine
This is Rietveld 408576698