<CONTEXT>for (MethodNode m : methods) {Parameter[] params = parameterizeArguments(receiver, m);</BUG>if (params.length > args.length && ! isVargs(params)) {int dist = allParametersAndArgumentsMatchWithDefaultParams(params, args);<extra_id_0>if (params.length > args.length && ! isVargs(params)) {int dist = allParametersAndArgumentsMatchWithDefaultParams(params, args);<BUG>if (dist>=0 && !receiver.equals(m.getDeclaringClass())) dist+=getDistance(receiver, m.getDeclaringClass());</BUG>if (dist>=0 && dist<bestDist) {bestChoices.clear();bestChoices.add(m);</CONTEXT>
actualReceiver = receiver!=null?receiver:m.getDeclaringClass();Parameter[] params = parameterizeArguments(actualReceiver, m);if (dist>=0 && !actualReceiver.equals(m.getDeclaringClass())) dist+=getDistance(actualReceiver, m.getDeclaringClass());