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

Unified Diff: pkg/analyzer/lib/task/model.dart

Issue 1420783004: Last performed task diagnostics. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Label. Created 5 years, 2 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 | « pkg/analyzer/lib/src/generated/utilities_general.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/lib/task/model.dart
diff --git a/pkg/analyzer/lib/task/model.dart b/pkg/analyzer/lib/task/model.dart
index 791f8327fba27085fc85918b229dfc5a7da0a596..f550495d0f0363784de865add49487a48d36e9da 100644
--- a/pkg/analyzer/lib/task/model.dart
+++ b/pkg/analyzer/lib/task/model.dart
@@ -79,6 +79,11 @@ abstract class AnalysisTarget {
*/
abstract class AnalysisTask {
/**
+ * A queue storing the last 10 task descriptions for diagnostic purposes.
+ */
+ static final LimitedQueue<String> LAST_TASKS = new LimitedQueue<String>(10);
+
+ /**
* A table mapping the types of analysis tasks to the number of times each
* kind of task has been performed.
*/
@@ -266,6 +271,11 @@ abstract class AnalysisTask {
void _safelyPerform() {
try {
//
+ // Store task description for diagnostics.
+ //
+ LAST_TASKS.add(description);
+
+ //
// Report that this task is being performed.
//
String contextName = context.name;
« no previous file with comments | « pkg/analyzer/lib/src/generated/utilities_general.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698