Index: pkg/analyzer/lib/src/generated/type_system.dart |
diff --git a/pkg/analyzer/lib/src/generated/type_system.dart b/pkg/analyzer/lib/src/generated/type_system.dart |
index 4899d9a2821173456277694060e6a695df1bc2b5..0488553c43014ca14e9210c463bb5279263b57a8 100644 |
--- a/pkg/analyzer/lib/src/generated/type_system.dart |
+++ b/pkg/analyzer/lib/src/generated/type_system.dart |
@@ -1640,12 +1640,8 @@ class _StrongInferenceTypeSystem extends StrongTypeSystemImpl { |
// We already know L <: T2, for some L. |
// So update L to reflect the new constraint LUB(L, T1) <: T2 |
// |
- |
- // Heuristic: we intentionally ignore `dynamic` when doing inference. |
- if (!t1.isDynamic) { |
- bound.lower = |
- _typeSystem.getLeastUpperBound(_typeProvider, bound.lower, t1); |
- } |
+ bound.lower = |
+ _typeSystem.getLeastUpperBound(_typeProvider, bound.lower, t1); |
// Optimistically assume we will be able to satisfy the constraint. |
return true; |
} |