aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDawid Pakuła2018-05-12 14:14:36 -0400
committerDawid Pakuła2018-05-13 11:31:45 -0400
commit6fbce415a33063ed538c4a350a317633d5e1be0f (patch)
tree95e4806f8b44ff9e78074e103d312eb3282ac572
parentefeae5c7aac8dd7c6ace1f13fd1b8fb4372384e0 (diff)
downloadorg.eclipse.pdt-6fbce415a33063ed538c4a350a317633d5e1be0f.zip
org.eclipse.pdt-6fbce415a33063ed538c4a350a317633d5e1be0f.tar.gz
org.eclipse.pdt-6fbce415a33063ed538c4a350a317633d5e1be0f.tar.xz
Bug 534427 - SOE on ModelUtils#getMethod
Change-Id: I1e5111c2c625b400340219e311177ba974cc12d9 Signed-off-by: Dawid Pakuła <zulus@w3des.net>
-rw-r--r--plugins/org.eclipse.php.core/src/org/eclipse/php/core/ast/nodes/DefaultBindingResolver.java198
-rw-r--r--plugins/org.eclipse.php.core/src/org/eclipse/php/core/ast/nodes/MultiTypeBinding.java241
-rw-r--r--plugins/org.eclipse.php.core/src/org/eclipse/php/core/ast/nodes/TypeBinding.java21
3 files changed, 299 insertions, 161 deletions
diff --git a/plugins/org.eclipse.php.core/src/org/eclipse/php/core/ast/nodes/DefaultBindingResolver.java b/plugins/org.eclipse.php.core/src/org/eclipse/php/core/ast/nodes/DefaultBindingResolver.java
index 40e6db1..9e2034c 100644
--- a/plugins/org.eclipse.php.core/src/org/eclipse/php/core/ast/nodes/DefaultBindingResolver.java
+++ b/plugins/org.eclipse.php.core/src/org/eclipse/php/core/ast/nodes/DefaultBindingResolver.java
@@ -16,10 +16,12 @@
package org.eclipse.php.core.ast.nodes;
import java.util.*;
+import java.util.Map.Entry;
import org.apache.commons.lang3.ArrayUtils;
import org.eclipse.core.runtime.Assert;
import org.eclipse.dltk.core.*;
+import org.eclipse.dltk.evaluation.types.SimpleType;
import org.eclipse.dltk.ti.types.IEvaluatedType;
import org.eclipse.php.core.ast.visitor.AbstractVisitor;
import org.eclipse.php.core.compiler.PHPFlags;
@@ -84,7 +86,7 @@ public class DefaultBindingResolver extends BindingResolver {
/**
* @param sourceModule
- * of this resolver
+ * of this resolver
*/
public DefaultBindingResolver(ISourceModule sourceModule, WorkingCopyOwner owner) {
this.sourceModule = sourceModule;
@@ -113,13 +115,43 @@ public class DefaultBindingResolver extends BindingResolver {
if (typeName == null) {
return null;
}
- String key = IModelElement.TYPE + ":" + typeName; //$NON-NLS-1$
- IBinding binding = bindingTables.bindingKeysToBindings.get(key);
- if (binding == null) {
- binding = new TypeBinding(this, type, modelElements);
- bindingTables.bindingKeysToBindings.put(key, binding);
+
+ Map<String, List<IModelElement>> nameMap = new HashMap<String, List<IModelElement>>();
+ if (modelElements != null && modelElements.length > 0) {
+ for (IModelElement model : modelElements) {
+ String name = PHPModelUtils.getFullName(model);
+ if (!nameMap.containsKey(name)) {
+ nameMap.put(name, new LinkedList<>());
+ }
+ nameMap.get(name).add(model);
+ }
}
- return (ITypeBinding) binding;
+
+ if (type instanceof SimpleType || modelElements == null || nameMap.size() < 2) {
+ String key = new StringBuilder(IModelElement.TYPE).append(":").append(type.getTypeName()).toString(); //$NON-NLS-1$
+ IBinding binding = bindingTables.bindingKeysToBindings.get(key);
+ if (binding == null) {
+ binding = new TypeBinding(this, type, modelElements);
+ bindingTables.bindingKeysToBindings.put(key, binding);
+ }
+ return (ITypeBinding) binding;
+ }
+ List<ITypeBinding> bindingList = new LinkedList<>();
+ for (Entry<String, List<IModelElement>> entry : nameMap.entrySet()) {
+ String key = new StringBuilder(IModelElement.TYPE).append(":").append(entry.getKey()).toString(); //$NON-NLS-1$
+ IBinding binding = bindingTables.bindingKeysToBindings.get(key);
+ if (binding == null) {
+ binding = new TypeBinding(this, new PHPClassType(entry.getKey()),
+ entry.getValue().toArray(new IModelElement[0]));
+ bindingTables.bindingKeysToBindings.put(key, binding);
+ }
+ bindingList.add((ITypeBinding) binding);
+ }
+ if (bindingList.size() == 1) {
+ return bindingList.get(0);
+ }
+
+ return new MultiTypeBinding(this, bindingList.toArray(new ITypeBinding[0]));
}
/**
@@ -131,7 +163,7 @@ public class DefaultBindingResolver extends BindingResolver {
* </p>
*
* @param type
- * the given type
+ * the given type
* @return the new type binding
*/
@Override
@@ -142,12 +174,6 @@ public class DefaultBindingResolver extends BindingResolver {
return null;
}
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.php.internal.core.ast.nodes.BindingResolver#getTypeBinding
- * (org.eclipse.dltk.core.IType[])
- */
@Override
ITypeBinding getTypeBinding(IType[] types) {
if (ArrayUtils.isNotEmpty(types)) {
@@ -161,7 +187,7 @@ public class DefaultBindingResolver extends BindingResolver {
* binding.
*
* @param field
- * An {@link IField}
+ * An {@link IField}
* @return the new variable binding, or null in case the given field is null.
*/
@Override
@@ -177,7 +203,7 @@ public class DefaultBindingResolver extends BindingResolver {
* Returns the new method binding corresponding to the given {@link IMethod} .
*
* @param method
- * An {@link IMethod}
+ * An {@link IMethod}
* @return the new method binding
*/
@Override
@@ -263,8 +289,8 @@ public class DefaultBindingResolver extends BindingResolver {
* @param offset
* @param length
* @param filter
- * Indicate whether to use the File-Network in order to filter the
- * results.
+ * Indicate whether to use the File-Network in order to filter
+ * the results.
*
* @see #getModelElements(int, int)
* @see BindingUtility#getModelElement(int, int, boolean)
@@ -281,12 +307,6 @@ public class DefaultBindingResolver extends BindingResolver {
}
}
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.php.internal.core.ast.nodes.BindingResolver#resolveName(org
- * .eclipse.php.internal.core.ast.nodes.Identifier)
- */
@Override
IBinding resolveName(Identifier name) {
// workaround for bug 253193's "ctrl+T not functional on methods"
@@ -332,7 +352,7 @@ public class DefaultBindingResolver extends BindingResolver {
* </p>
*
* @param method
- * the method or constructor declaration of interest
+ * the method or constructor declaration of interest
* @return the binding for the given method declaration, or <code>null</code> if
* no binding is available
*/
@@ -378,48 +398,23 @@ public class DefaultBindingResolver extends BindingResolver {
}
}
- /*
- * (non-Javadoc)
- *
- * @see BindingResolver#resolveInclude(Include)
- */
@Override
IBinding resolveInclude(Include includeDeclaration) {
return new IncludeBinding(sourceModule, includeDeclaration);
}
- /*
- * (non-Javadoc)
- *
- * @see
- * org.eclipse.php.internal.core.ast.nodes.BindingResolver#findDeclaringNode
- * (org.eclipse.php.internal.core.ast.nodes.IBinding)
- */
@Override
org.eclipse.php.core.ast.nodes.ASTNode findDeclaringNode(IBinding binding) {
// TODO Auto-generated method stub
return super.findDeclaringNode(binding);
}
- /*
- * (non-Javadoc)
- *
- * @see
- * org.eclipse.php.internal.core.ast.nodes.BindingResolver#findDeclaringNode
- * (java.lang.String)
- */
@Override
org.eclipse.php.core.ast.nodes.ASTNode findDeclaringNode(String bindingKey) {
// TODO Auto-generated method stub
return super.findDeclaringNode(bindingKey);
}
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.php.internal.core.ast.nodes.BindingResolver#getTypeBinding
- * (org.eclipse.php.internal.core.ast.nodes.FieldsDeclaration)
- */
@Override
ITypeBinding getTypeBinding(SingleFieldDeclaration fieldDeclaration) {
IModelElement[] modelElements;
@@ -445,12 +440,6 @@ public class DefaultBindingResolver extends BindingResolver {
return super.getTypeBinding(fieldDeclaration);
}
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.php.internal.core.ast.nodes.BindingResolver#getTypeBinding
- * (org.eclipse.dltk.ti.types.IEvaluatedType)
- */
@Override
ITypeBinding getTypeBinding(IEvaluatedType referenceBinding, ISourceModule sourceModule) {
if (referenceBinding != null) {
@@ -459,26 +448,12 @@ public class DefaultBindingResolver extends BindingResolver {
return null;
}
- /*
- * (non-Javadoc)
- *
- * @seeorg.eclipse.php.internal.core.ast.nodes.BindingResolver#
- * resolveConstantExpressionValue
- * (org.eclipse.php.internal.core.ast.nodes.Expression)
- */
@Override
Object resolveConstantExpressionValue(Expression expression) {
// TODO Auto-generated method stub
return super.resolveConstantExpressionValue(expression);
}
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.php.internal.core.ast.nodes.BindingResolver#
- * resolveConstructor
- * (org.eclipse.php.internal.core.ast.nodes.ClassInstanceCreation)
- */
@Override
IMethodBinding resolveConstructor(ClassInstanceCreation expression) {
IModelElement[] modelElements;
@@ -501,12 +476,6 @@ public class DefaultBindingResolver extends BindingResolver {
return super.resolveConstructor(expression);
}
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.php.internal.core.ast.nodes.BindingResolver#
- * resolveConstructor (org.eclipse.php.internal.core.ast.nodes.MethodInvocation)
- */
@Override
IMethodBinding resolveConstructor(MethodInvocation expression) {
IMethodBinding binding = resolveMethod(expression);
@@ -516,12 +485,6 @@ public class DefaultBindingResolver extends BindingResolver {
return super.resolveConstructor(expression);
}
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.php.internal.core.ast.nodes.BindingResolver#resolveField(
- * org.eclipse.php.internal.core.ast.nodes.FieldAccess)
- */
@Override
IVariableBinding resolveField(FieldAccess fieldAccess) {
final VariableBase member = fieldAccess.getMember();
@@ -537,12 +500,6 @@ public class DefaultBindingResolver extends BindingResolver {
return null;
}
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.php.internal.core.ast.nodes.BindingResolver#resolveField(
- * org.eclipse.php.internal.core.ast.nodes.StaticConstantAccess)
- */
@Override
IVariableBinding resolveField(StaticConstantAccess constantAccess) {
final Identifier constName = constantAccess.getConstant();
@@ -582,12 +539,6 @@ public class DefaultBindingResolver extends BindingResolver {
return null;
}
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.php.internal.core.ast.nodes.BindingResolver#resolveField(
- * org.eclipse.php.internal.core.ast.nodes.StaticFieldAccess)
- */
@Override
IVariableBinding resolveField(StaticFieldAccess fieldAccess) {
final VariableBase member = fieldAccess.getField();
@@ -603,12 +554,6 @@ public class DefaultBindingResolver extends BindingResolver {
return null;
}
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.php.internal.core.ast.nodes.BindingResolver#resolveFunction
- * (org.eclipse.php.internal.core.ast.nodes.FunctionDeclaration)
- */
@Override
IFunctionBinding resolveFunction(FunctionDeclaration function) {
IModelElement[] modelElements = null;
@@ -631,12 +576,6 @@ public class DefaultBindingResolver extends BindingResolver {
return super.resolveFunction(function);
}
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.php.internal.core.ast.nodes.BindingResolver#resolveFunction
- * (org.eclipse.php.internal.core.ast.nodes.FunctionInvocation)
- */
@Override
IFunctionBinding resolveFunction(FunctionInvocation function) {
IModelElement[] modelElements = null;
@@ -659,12 +598,6 @@ public class DefaultBindingResolver extends BindingResolver {
return super.resolveFunction(function);
}
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.php.internal.core.ast.nodes.BindingResolver#resolveMethod
- * (org.eclipse.php.internal.core.ast.nodes.MethodInvocation)
- */
@Override
IMethodBinding resolveMethod(MethodInvocation method) {
IModelElement[] modelElements = null;
@@ -687,12 +620,6 @@ public class DefaultBindingResolver extends BindingResolver {
return super.resolveMethod(method);
}
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.php.internal.core.ast.nodes.BindingResolver#resolveMethod
- * (org.eclipse.php.internal.core.ast.nodes.StaticMethodInvocation)
- */
@Override
IMethodBinding resolveMethod(StaticMethodInvocation method) {
IModelElement[] modelElements = null;
@@ -715,12 +642,6 @@ public class DefaultBindingResolver extends BindingResolver {
return super.resolveMethod(method);
}
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.php.internal.core.ast.nodes.BindingResolver#resolveType(org
- * .eclipse.php.internal.core.ast.nodes.TypeDeclaration)
- */
@Override
ITypeBinding resolveType(TypeDeclaration type) {
@@ -747,37 +668,18 @@ public class DefaultBindingResolver extends BindingResolver {
return super.resolveType(type);
}
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.php.internal.core.ast.nodes.BindingResolver#
- * resolveTypeParameter
- * (org.eclipse.php.internal.core.ast.nodes.FormalParameter)
- */
@Override
ITypeBinding resolveTypeParameter(FormalParameter typeParameter) {
// TODO Auto-generated method stub
return super.resolveTypeParameter(typeParameter);
}
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.php.internal.core.ast.nodes.BindingResolver#resolveVariable
- * (org.eclipse.php.internal.core.ast.nodes.FieldsDeclaration)
- */
@Override
IVariableBinding resolveVariable(FieldsDeclaration variable) {
// TODO Auto-generated method stub
return super.resolveVariable(variable);
}
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.php.internal.core.ast.nodes.BindingResolver#resolveVariable
- * (org.eclipse.php.internal.core.ast.nodes.Variable)
- */
@Override
IVariableBinding resolveVariable(Variable variable) {
IModelElement modelElements = null;
@@ -801,12 +703,6 @@ public class DefaultBindingResolver extends BindingResolver {
return super.resolveVariable(variable);
}
- /*
- * (non-Javadoc)
- *
- * @see org.eclipse.php.internal.core.ast.nodes.BindingResolver#
- * resolveWellKnownType (java.lang.String)
- */
@Override
ITypeBinding resolveWellKnownType(String name) {
// TODO Auto-generated method stub
@@ -832,8 +728,8 @@ public class DefaultBindingResolver extends BindingResolver {
* declaration.
*
* @param node
- * the body declaration. Must either be a method declaration or an
- * initializer.
+ * the body declaration. Must either be a method declaration or
+ * an initializer.
* @return the maximum number of local variables
*/
public static int perform(ASTNode node, Variable variable) {
diff --git a/plugins/org.eclipse.php.core/src/org/eclipse/php/core/ast/nodes/MultiTypeBinding.java b/plugins/org.eclipse.php.core/src/org/eclipse/php/core/ast/nodes/MultiTypeBinding.java
new file mode 100644
index 0000000..3d4f136
--- /dev/null
+++ b/plugins/org.eclipse.php.core/src/org/eclipse/php/core/ast/nodes/MultiTypeBinding.java
@@ -0,0 +1,241 @@
+/*******************************************************************************
+ * Copyright (c) 2018 Dawid Pakuła and others.
+ * All rights reserved. This program and the accompanying materials
+ * are made available under the terms of the Eclipse Public License v1.0
+ * which accompanies this distribution, and is available at
+ * http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Dawid Pakuła - initial API and implementation
+ *******************************************************************************/
+package org.eclipse.php.core.ast.nodes;
+
+import java.util.Arrays;
+import java.util.LinkedList;
+import java.util.List;
+
+import org.eclipse.dltk.core.IModelElement;
+import org.eclipse.dltk.core.IType;
+import org.eclipse.dltk.ti.types.IEvaluatedType;
+
+public class MultiTypeBinding implements ITypeBinding {
+ private final ITypeBinding[] subtypes;
+ private final DefaultBindingResolver resolver;
+
+ public MultiTypeBinding(DefaultBindingResolver resolver, ITypeBinding[] subtypes) {
+ this.subtypes = subtypes;
+ this.resolver = resolver;
+ }
+
+ @Override
+ public int getKind() {
+ return IBinding.TYPE;
+ }
+
+ @Override
+ public boolean isDeprecated() {
+ for (ITypeBinding binding : subtypes) {
+ if (binding.isDeprecated()) {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ @Override
+ public IModelElement getPHPElement() {
+ return null;
+ }
+
+ @Override
+ public String getKey() {
+ return null;
+ }
+
+ @Override
+ public ITypeBinding createArrayType(int dimension) {
+ return null;
+ }
+
+ @Override
+ public String getBinaryName() {
+ return null;
+ }
+
+ @Override
+ public ITypeBinding getComponentType() {
+ return null;
+ }
+
+ @Override
+ public IVariableBinding[] getDeclaredFields() {
+ List<IVariableBinding> list = new LinkedList<>();
+ for (ITypeBinding t : subtypes) {
+ list.addAll(Arrays.asList(t.getDeclaredFields()));
+ }
+ return list.toArray(new IVariableBinding[0]);
+ }
+
+ @Override
+ public IMethodBinding[] getDeclaredMethods() {
+ List<IMethodBinding> list = new LinkedList<>();
+ for (ITypeBinding t : subtypes) {
+ list.addAll(Arrays.asList(t.getDeclaredMethods()));
+ }
+ return list.toArray(new IMethodBinding[0]);
+ }
+
+ @Override
+ public int getModifiers() {
+ return -1;
+ }
+
+ @Override
+ public int getDimensions() {
+ return 0;
+ }
+
+ @Override
+ public ITypeBinding getElementType() {
+ return null;
+ }
+
+ @Override
+ public ITypeBinding[] getInterfaces() {
+ List<ITypeBinding> list = new LinkedList<>();
+ for (ITypeBinding t : subtypes) {
+ list.addAll(Arrays.asList(t.getInterfaces()));
+ }
+ return list.toArray(new ITypeBinding[0]);
+ }
+
+ @Override
+ public String getName() {
+ return null;
+ }
+
+ @Override
+ public IEvaluatedType getEvaluatedType() {
+ return subtypes[0].getEvaluatedType();
+ }
+
+ @Override
+ public ITypeBinding getSuperclass() {
+ List<ITypeBinding> list = new LinkedList<>();
+ for (ITypeBinding t : subtypes) {
+ ITypeBinding s = t.getSuperclass();
+ if (s != null && !s.isUnknown()) {
+ list.add(s);
+ }
+ }
+ if (list.size() == 1) {
+ return list.get(0);
+ } else if (list.size() > 1) {
+ return new MultiTypeBinding(resolver, list.toArray(new ITypeBinding[0]));
+ }
+ return null;
+ }
+
+ @Override
+ public ITypeBinding getTypeDeclaration() {
+ return subtypes[0].getTypeDeclaration();
+ }
+
+ @Override
+ public boolean isArray() {
+ for (ITypeBinding t : subtypes) {
+ if (t.isArray()) {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ @Override
+ public boolean isClass() {
+ for (ITypeBinding t : subtypes) {
+ if (t.isClass()) {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ @Override
+ public boolean isTrait() {
+ for (ITypeBinding t : subtypes) {
+ if (t.isTrait()) {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ @Override
+ public boolean isInterface() {
+ for (ITypeBinding t : subtypes) {
+ if (t.isInterface()) {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ @Override
+ public boolean isNullType() {
+ for (ITypeBinding t : subtypes) {
+ if (t.isNullType()) {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ @Override
+ public boolean isPrimitive() {
+ for (ITypeBinding t : subtypes) {
+ if (t.isPrimitive()) {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ @Override
+ public boolean isSubTypeCompatible(ITypeBinding type) {
+ for (ITypeBinding t : subtypes) {
+ if (t.isSubTypeCompatible(type)) {
+ return true;
+ }
+ }
+ return false;
+ }
+
+ @Override
+ public boolean isAmbiguous() {
+ return true;
+ }
+
+ @Override
+ public boolean isUnknown() {
+ return false;
+ }
+
+ @Override
+ public List<IType> getTraitList(boolean isMethod, String classMemberName, boolean includeSuper) {
+ List<IType> list = new LinkedList<>();
+ for (ITypeBinding t : subtypes) {
+ list.addAll(t.getTraitList(isMethod, classMemberName, includeSuper));
+ }
+ return list;
+ }
+
+ @Override
+ public IModelElement[] getPHPElements() {
+ List<IModelElement> list = new LinkedList<>();
+ for (ITypeBinding t : subtypes) {
+ list.addAll(Arrays.asList(t.getPHPElements()));
+ }
+ return list.toArray(new IModelElement[0]);
+ }
+}
diff --git a/plugins/org.eclipse.php.core/src/org/eclipse/php/core/ast/nodes/TypeBinding.java b/plugins/org.eclipse.php.core/src/org/eclipse/php/core/ast/nodes/TypeBinding.java
index 54e863b..acc7cbb 100644
--- a/plugins/org.eclipse.php.core/src/org/eclipse/php/core/ast/nodes/TypeBinding.java
+++ b/plugins/org.eclipse.php.core/src/org/eclipse/php/core/ast/nodes/TypeBinding.java
@@ -85,15 +85,16 @@ public class TypeBinding implements ITypeBinding {
* </p>
*
* @param dimension
- * the given dimension
+ * the given dimension
* @return an array type binding
* @throws IllegalArgumentException
- * :
- * <ul>
- * <li>if the receiver represents the void type</li>
- * <li>if the resulting dimensions is lower than one or greater than
- * 255</li>
- * </ul>
+ * :
+ * <ul>
+ * <li>if the receiver represents the void
+ * type</li>
+ * <li>if the resulting dimensions is lower
+ * than one or greater than 255</li>
+ * </ul>
*/
@Override
public ITypeBinding createArrayType(int dimension) {
@@ -660,7 +661,7 @@ public class TypeBinding implements ITypeBinding {
* Returns whether this type is subtype compatible with the given type.
*
* @param type
- * the type to check compatibility against
+ * the type to check compatibility against
* @return <code>true</code> if this type is subtype compatible with the given
* type, and <code>false</code> otherwise
*
@@ -687,7 +688,7 @@ public class TypeBinding implements ITypeBinding {
supertypeHierarchy = type.newSupertypeHierarchy(new NullProgressMonitor());
hierarchy.put(type, supertypeHierarchy);
}
- IModelElement[] otherElements = ((TypeBinding) otherType).elements;
+ IModelElement[] otherElements = otherType.getPHPElements();
if (otherElements != null) {
for (IModelElement modelElement : otherElements) {
if (modelElement instanceof IType && supertypeHierarchy.contains((IType) modelElement)) {
@@ -851,7 +852,7 @@ public class TypeBinding implements ITypeBinding {
* {@link #isEqualTo(IBinding)}, which checks their keys.
*
* @param other
- * {@inheritDoc}
+ * {@inheritDoc}
* @return {@inheritDoc}
*/
@Override