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

Unified Diff: pkg/analyzer/lib/src/generated/element_resolver.dart

Issue 1567223002: guard against null staticInvokeType (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 4 years, 11 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 | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analyzer/lib/src/generated/element_resolver.dart
diff --git a/pkg/analyzer/lib/src/generated/element_resolver.dart b/pkg/analyzer/lib/src/generated/element_resolver.dart
index 59285f21720d6e70d491dd16cca9f4ed8b19b249..57b8060e5a88a58076ae9e7d7b372c382969978a 100644
--- a/pkg/analyzer/lib/src/generated/element_resolver.dart
+++ b/pkg/analyzer/lib/src/generated/element_resolver.dart
@@ -653,7 +653,8 @@ class ElementResolver extends SimpleAstVisitor<Object> {
node.staticInvokeType = staticInvokeType;
if (propagatedInvokeType != null &&
- propagatedInvokeType.isMoreSpecificThan(staticInvokeType)) {
+ (staticInvokeType == null ||
+ propagatedInvokeType.isMoreSpecificThan(staticInvokeType))) {
// Don't store the propagated invoke type unless it's more specific than
// the static type. We still need to record the propagated parameter
// elements however, as that is used for the propagatedType downwards
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698