@Override
public boolean isIdentical(GoPsiType goType) {
if (!(goType instanceof GoPsiTypeFunction))
return false;
GoPsiTypeFunction functionDeclaration = (GoPsiTypeFunction) goType;
GoFunctionParameter[] funcTypeArguments = this.getParameters();
GoFunctionParameter[] funcDeclArguments = functionDeclaration.getParameters();
int idx = 0;
if (funcDeclArguments.length != funcTypeArguments.length)
return false;
for (GoFunctionParameter parameter : funcDeclArguments) {
if (!parameter.getType().isIdentical(funcTypeArguments[idx].getType()))
return false;
idx++;
}
funcTypeArguments = this.getResults();
funcDeclArguments = functionDeclaration.getResults();
if (funcDeclArguments.length != funcTypeArguments.length)
return false;
idx = 0;