| Index: lib/compiler/implementation/typechecker.dart
|
| diff --git a/lib/compiler/implementation/typechecker.dart b/lib/compiler/implementation/typechecker.dart
|
| index 8c36f1f797c130ca126d8835e49d6f1753b77471..a5489eedaaff9abb5f814cad83d1e11d1d80fb65 100644
|
| --- a/lib/compiler/implementation/typechecker.dart
|
| +++ b/lib/compiler/implementation/typechecker.dart
|
| @@ -395,6 +395,7 @@ class TypeCheckerVisitor implements Visitor<Type> {
|
| Type returnType;
|
| Type previousType;
|
| final FunctionElement element = elements[node];
|
| + if (Element.isInvalid(element)) return types.dynamicType;
|
| if (element.kind === ElementKind.GENERATIVE_CONSTRUCTOR ||
|
| element.kind === ElementKind.GENERATIVE_CONSTRUCTOR_BODY) {
|
| type = types.dynamicType;
|
| @@ -707,7 +708,7 @@ class TypeCheckerVisitor implements Visitor<Type> {
|
| }
|
|
|
| Type computeType(Element element) {
|
| - if (element === null) return types.dynamicType;
|
| + if (Element.isInvalid(element)) return types.dynamicType;
|
| Type result = element.computeType(compiler);
|
| return (result !== null) ? result : types.dynamicType;
|
| }
|
|
|