Index: pkg/compiler/lib/src/inferrer/type_graph_nodes.dart |
diff --git a/pkg/compiler/lib/src/inferrer/type_graph_nodes.dart b/pkg/compiler/lib/src/inferrer/type_graph_nodes.dart |
index fa18eb894dbeb9d2c15873575883da926bfa2538..9c315d91a07c9e4a066b76907678843606815a5e 100644 |
--- a/pkg/compiler/lib/src/inferrer/type_graph_nodes.dart |
+++ b/pkg/compiler/lib/src/inferrer/type_graph_nodes.dart |
@@ -1732,14 +1732,13 @@ TypeMask _narrowType( |
{bool isNullable: true}) { |
if (annotation.treatAsDynamic) return type; |
if (annotation.isObject) return type; |
+ if (annotation.isVoid) return type; |
TypeMask otherType; |
if (annotation.isTypedef || annotation.isFunctionType) { |
otherType = closedWorld.commonMasks.functionType; |
} else if (annotation.isTypeVariable) { |
// TODO(ngeoffray): Narrow to bound. |
return type; |
- } else if (annotation.isVoid) { |
- otherType = closedWorld.commonMasks.nullType; |
} else { |
ResolutionInterfaceType interfaceType = annotation; |
otherType = new TypeMask.nonNullSubtype(interfaceType.element, closedWorld); |