Index: pkg/analyzer/lib/src/context/context.dart |
diff --git a/pkg/analyzer/lib/src/context/context.dart b/pkg/analyzer/lib/src/context/context.dart |
index d0a2104ba50a2596685d47b97f6497fd01448a8d..a255836fa0d6bf53378d91a3796bcdd8af7d081d 100644 |
--- a/pkg/analyzer/lib/src/context/context.dart |
+++ b/pkg/analyzer/lib/src/context/context.dart |
@@ -720,6 +720,12 @@ class AnalysisContextImpl implements InternalAnalysisContext { |
CacheEntry entry = getCacheEntry(target); |
CacheState state = entry.getState(descriptor); |
if (state == CacheState.FLUSHED || state == CacheState.INVALID) { |
+ // Check the result provider. |
+ bool success = aboutToComputeResult(entry, descriptor); |
+ if (success) { |
+ return entry.getValue(descriptor); |
+ } |
+ // Compute the result. |
driver.computeResult(target, descriptor); |
entry = getCacheEntry(target); |
} |