| Index: lib/compiler/implementation/typechecker.dart
|
| diff --git a/lib/compiler/implementation/typechecker.dart b/lib/compiler/implementation/typechecker.dart
|
| index aa6891976f43dcf3c4b610b6a68172a6a3a6b6b5..c28e2e631f1b5f9c207b488f07ef157f0e6c0cbd 100644
|
| --- a/lib/compiler/implementation/typechecker.dart
|
| +++ b/lib/compiler/implementation/typechecker.dart
|
| @@ -335,6 +335,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;
|
| @@ -647,7 +648,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;
|
| }
|
|
|