diff --git a/org.eclipse.jdt.core/model/org/eclipse/jdt/internal/core/BinaryType.java b/org.eclipse.jdt.core/model/org/eclipse/jdt/internal/core/BinaryType.java index 98513a7dfb7..702e1ab7002 100644 --- a/org.eclipse.jdt.core/model/org/eclipse/jdt/internal/core/BinaryType.java +++ b/org.eclipse.jdt.core/model/org/eclipse/jdt/internal/core/BinaryType.java @@ -170,7 +170,12 @@ public IType createType(String contents, IJavaElement sibling, boolean force, IP } @Override public boolean equals(Object o) { - if (!(o instanceof BinaryType)) return false; + if (o == this) { + return true; + } + if (!(o instanceof BinaryType)) { + return false; + } return super.equals(o); }