Program: 186072
Project: 186072
Buggy source:
public void incompatibleReturnType(MethodBinding currentMethod,MethodBinding inheritedMethod){
  StringBuffer methodSignature=new StringBuffer();
  methodSignature.append(inheritedMethod.declaringClass.readableName()).append('.').append(inheritedMethod.readableName());
  StringBuffer shortSignature=new StringBuffer();
  shortSignature.append(inheritedMethod.declaringClass.shortReadableName()).append('.').append(inheritedMethod.shortReadableName());
  int id;
  final ReferenceBinding declaringClass=currentMethod.declaringClass;
  if (declaringClass.isInterface() && !inheritedMethod.isPublic()) {
    id=IProblem.IncompatibleReturnTypeForNonInheritedInterfaceMethod;
  }
 else {
    id=IProblem.IncompatibleReturnType;
  }
  AbstractMethodDeclaration method=currentMethod.sourceMethod();
  int sourceStart=0;
  int sourceEnd=0;
  if (method == null) {
    if (declaringClass instanceof SourceTypeBinding) {
      SourceTypeBinding sourceTypeBinding=(SourceTypeBinding)declaringClass;
      sourceStart=sourceTypeBinding.sourceStart();
      sourceEnd=sourceTypeBinding.sourceEnd();
    }
  }
 else   if (method.isConstructor()) {
    sourceStart=method.sourceStart;
    sourceEnd=method.sourceEnd;
  }
 else {
    TypeReference returnType=((MethodDeclaration)method).returnType;
    sourceStart=returnType.sourceStart;
    if (returnType instanceof ParameterizedSingleTypeReference) {
      ParameterizedSingleTypeReference typeReference=(ParameterizedSingleTypeReference)returnType;
      TypeReference[] typeArguments=typeReference.typeArguments;
      if (typeArguments[typeArguments.length - 1].sourceEnd > typeReference.sourceEnd) {
        sourceEnd=retrieveClosingAngleBracketPosition(typeReference.sourceEnd);
      }
 else {
        sourceEnd=returnType.sourceEnd;
      }
    }
 else     if (returnType instanceof ParameterizedQualifiedTypeReference) {
      ParameterizedQualifiedTypeReference typeReference=(ParameterizedQualifiedTypeReference)returnType;
      sourceEnd=retrieveClosingAngleBracketPosition(typeReference.sourceEnd);
    }
 else {
      sourceEnd=returnType.sourceEnd;
    }
  }
  this.handle(id,new String[]{methodSignature.toString()},new String[]{shortSignature.toString()},sourceStart,sourceEnd);
}

Fixed version (ground truth):
public void incompatibleReturnType(MethodBinding currentMethod,MethodBinding inheritedMethod){
  if (currentMethod.declaringClass instanceof SourceTypeBinding) {
    SourceTypeBinding stb=(SourceTypeBinding)currentMethod.declaringClass;
    if (stb.scope != null && !stb.scope.shouldReport(IProblem.IncompatibleReturnType)) {
      return;
    }
  }
  StringBuffer methodSignature=new StringBuffer();
  methodSignature.append(inheritedMethod.declaringClass.readableName()).append('.').append(inheritedMethod.readableName());
  StringBuffer shortSignature=new StringBuffer();
  shortSignature.append(inheritedMethod.declaringClass.shortReadableName()).append('.').append(inheritedMethod.shortReadableName());
  int id;
  final ReferenceBinding declaringClass=currentMethod.declaringClass;
  if (declaringClass.isInterface() && !inheritedMethod.isPublic()) {
    id=IProblem.IncompatibleReturnTypeForNonInheritedInterfaceMethod;
  }
 else {
    id=IProblem.IncompatibleReturnType;
  }
  AbstractMethodDeclaration method=currentMethod.sourceMethod();
  int sourceStart=0;
  int sourceEnd=0;
  if (method == null) {
    if (declaringClass instanceof SourceTypeBinding) {
      SourceTypeBinding sourceTypeBinding=(SourceTypeBinding)declaringClass;
      sourceStart=sourceTypeBinding.sourceStart();
      sourceEnd=sourceTypeBinding.sourceEnd();
    }
  }
 else   if (method.isConstructor()) {
    sourceStart=method.sourceStart;
    sourceEnd=method.sourceEnd;
  }
 else {
    TypeReference returnType=((MethodDeclaration)method).returnType;
    sourceStart=returnType.sourceStart;
    if (returnType instanceof ParameterizedSingleTypeReference) {
      ParameterizedSingleTypeReference typeReference=(ParameterizedSingleTypeReference)returnType;
      TypeReference[] typeArguments=typeReference.typeArguments;
      if (typeArguments[typeArguments.length - 1].sourceEnd > typeReference.sourceEnd) {
        sourceEnd=retrieveClosingAngleBracketPosition(typeReference.sourceEnd);
      }
 else {
        sourceEnd=returnType.sourceEnd;
      }
    }
 else     if (returnType instanceof ParameterizedQualifiedTypeReference) {
      ParameterizedQualifiedTypeReference typeReference=(ParameterizedQualifiedTypeReference)returnType;
      sourceEnd=retrieveClosingAngleBracketPosition(typeReference.sourceEnd);
    }
 else {
      sourceEnd=returnType.sourceEnd;
    }
  }
  this.handle(id,new String[]{methodSignature.toString()},new String[]{shortSignature.toString()},sourceStart,sourceEnd);
}