| Index: compiler/java/com/google/dart/compiler/LibraryDepsVisitor.java
|
| diff --git a/compiler/java/com/google/dart/compiler/LibraryDepsVisitor.java b/compiler/java/com/google/dart/compiler/LibraryDepsVisitor.java
|
| index 1e4f541773ff8b5463842ad60bc52e1f79b1fd73..14de2a45d8b6d7489880ec87f833dcf7489a2585 100644
|
| --- a/compiler/java/com/google/dart/compiler/LibraryDepsVisitor.java
|
| +++ b/compiler/java/com/google/dart/compiler/LibraryDepsVisitor.java
|
| @@ -10,6 +10,7 @@ import com.google.dart.compiler.ast.DartIdentifier;
|
| import com.google.dart.compiler.ast.DartMethodDefinition;
|
| import com.google.dart.compiler.ast.DartNode;
|
| import com.google.dart.compiler.ast.DartNodeTraverser;
|
| +import com.google.dart.compiler.ast.DartParameterizedTypeNode;
|
| import com.google.dart.compiler.ast.DartPropertyAccess;
|
| import com.google.dart.compiler.ast.DartTypeNode;
|
| import com.google.dart.compiler.ast.DartUnit;
|
| @@ -58,13 +59,14 @@ public class LibraryDepsVisitor extends DartNodeTraverser<Void> {
|
| // explanation).
|
| switch (kind) {
|
| case FIELD:
|
| - case METHOD:
|
| + case METHOD: {
|
| EnclosingElement enclosing = target.getEnclosingElement();
|
| addHoleIfSuper(node, enclosing);
|
| if (enclosing.getKind().equals(ElementKind.LIBRARY)) {
|
| addElementDependency(target);
|
| }
|
| break;
|
| + }
|
| }
|
|
|
| // Add dependency on the computed type of identifiers.
|
| @@ -113,6 +115,15 @@ public class LibraryDepsVisitor extends DartNodeTraverser<Void> {
|
| }
|
|
|
| @Override
|
| + public Void visitParameterizedTypeNode(DartParameterizedTypeNode node) {
|
| + if (TypeKind.of(node.getType()).equals(TypeKind.INTERFACE)) {
|
| + addElementDependency(((InterfaceType) node.getType()).getElement());
|
| + }
|
| + node.visitChildren(this);
|
| + return null;
|
| + }
|
| +
|
| + @Override
|
| public Void visitTypeNode(DartTypeNode node) {
|
| if (TypeKind.of(node.getType()).equals(TypeKind.INTERFACE)) {
|
| addElementDependency(((InterfaceType) node.getType()).getElement());
|
|
|