Buggy code:
for ( int i = 0 ; i < length ; i ++ ) { if ( ( this . genericTypeArguments [ i ] = this . typeArguments [ i ] . resolveType ( scope , true ) ) == null ) { argHasError = true ; } } if ( argHasError ) { return null ; } } TypeBinding [ ] argumentTypes = NoParameters ; if ( ( arguments ) != null ) { boolean argHasError = false ; int length = arguments . length ; argumentTypes = new TypeBinding [ length ] ; for ( int i = 0 ; i < length ; i ++ ) { Expression argument = arguments [ i ] ; if ( argument instanceof CastExpression ) { argument . bits |= IgnoreNeedForCastCheckMASK ; argsContainCast = true ; } if ( ( argumentTypes [ i ] = argument . resolveType ( scope ) ) == null ) { argHasError = true ; } } if ( argHasError ) { if ( ( actualReceiverType ) instanceof ReferenceBinding ) { this . binding = scope . findMethod ( ( ( ReferenceBinding ) ( actualReceiverType ) ) , selector , new TypeBinding [ ] { } , this ) ; } return null ; } } if ( ( this . actualReceiverType ) == null ) { return null ; } if ( this . actualReceiverType . isBaseType ( ) ) { scope . problemReporter ( ) . errorNoMethodFor ( this , this . actualReceiverType , argumentTypes ) ; return null ; } this . binding = ( receiver . isImplicitThis ( ) ) ? scope . getImplicitMethod ( selector , argumentTypes , this ) : scope . getMethod ( this . actualReceiverType , selector , argumentTypes , this ) ; if ( ! ( binding . isValidBinding ( ) ) ) { if ( ( binding . declaringClass ) == null ) { if ( ( this . actualReceiverType ) instanceof ReferenceBinding ) { binding . declaringClass = ( ( ReferenceBinding ) ( this . actualReceiverType ) ) ; } else { scope . problemReporter ( ) . errorNoMethodFor ( this , this . actualReceiverType , argumentTypes ) ; return null ; } } scope . problemReporter ( ) . invalidMethod ( this , binding ) ; MethodBinding closestMatch = ( ( ProblemMethodBinding ) ( binding ) ) . closestMatch ; switch ( this . binding . problemId ( ) ) { case ProblemReasons . Ambiguous : case ProblemReasons . NotVisible : case ProblemReasons . NonStaticReferenceInConstructorInvocation : case ProblemReasons . NonStaticReferenceInStaticContext : case ProblemReasons . ReceiverTypeNotVisible : case ProblemReasons . ParameterBoundMismatch : if ( closestMatch != null ) this . resolvedType = closestMatch . returnType ; default : } if ( closestMatch != null ) { this . binding = closestMatch ; if ( ( ( closestMatch . isPrivate ( ) ) || ( closestMatch . declaringClass . isLocalType ( ) ) ) && ( ! ( scope . isDefinedInMethod ( closestMatch ) ) ) ) { closestMatch . original ( ) . modifiers |= AccLocallyUsed ; } } return this . resolvedType ; } if ( ! ( binding . isStatic ( ) ) ) { if ( ( ( receiver ) instanceof NameReference ) && ( ( ( ( ( NameReference ) ( receiver ) ) . bits ) & ( Binding . TYPE ) ) != 0 ) ) { scope . problemReporter ( ) . mustUseAStaticMethod ( this , binding ) ; } else { TypeBinding receiverErasure = this . actualReceiverType . erasure ( ) ; if ( receiverErasure instanceof ReferenceBinding ) { <START_BUG> ReferenceBinding match = ( ( ReferenceBinding ) ( receiverErasure ) ) . findSuperTypeErasingTo ( ( ( ReferenceBinding ) ( this . binding . declaringClass . erasure ( ) ) ) ) ; <END_BUG> if ( match == null ) { this . actualReceiverType = this . binding . declaringClass ; } } receiver . computeConversion ( scope , this . actualReceiverType , this . actualReceiverType ) ; } } else { if ( ! ( ( ( receiver . isImplicitThis ( ) ) || ( receiver . isSuper ( ) ) ) || ( ( ( receiver ) instanceof NameReference ) && ( ( ( ( ( NameReference ) ( receiver ) ) . bits ) & ( Binding . TYPE ) ) != 0 ) ) ) ) { scope . problemReporter ( ) . nonStaticAccessToStaticMethod ( this , binding ) ; } if ( ( ! ( receiver . isImplicitThis ( ) ) ) && ( ( binding . declaringClass ) != ( actualReceiverType ) ) ) { scope . problemReporter ( ) . indirectAccessToStaticMethod ( this , binding ) ; } } ASTNode . checkInvocationArguments ( scope , this . receiver , actualReceiverType , binding , this . arguments , argumentTypes , argsContainCast , this ) ; if ( binding . isAbstract ( ) ) { if ( receiver . isSuper ( ) ) { scope . problemReporter ( ) . cannotDireclyInvokeAbstractMethod ( this , binding ) ; } } if ( isMethodUseDeprecated ( binding , scope ) ) scope . problemReporter ( ) . deprecatedMethod ( binding , this ) ; if ( ( ( ( actualReceiverType . isArrayType ( ) ) && ( ( this . binding . parameters ) == ( NoParameters ) ) ) && ( ( scope . compilerOptions ( ) . complianceLevel ) >= ( JDK1_5 ) ) ) && ( CharOperation . equals ( this . binding . selector , TypeConstants . CLONE ) ) ) { this . resolvedType = actualReceiverType ; } else { TypeBinding returnType = this . binding . returnType ; if ( returnType != null ) returnType = returnType . capture ( scope , this . sourceEnd ) ; this . resolvedType = returnType ; } return this . resolvedType ; } public void setActualReceiverType ( ReferenceBinding receiverType ) { } public void setExpectedType ( TypeBinding expectedType ) { }

Fix:
ReferenceBinding match = ( ( ReferenceBinding ) ( receiverErasure ) ) . findSuperTypeWithSameErasure ( this . binding . declaringClass ) ;