// check for conflicts with existing methods, should really check type as well...
//System.err.println("adding: " + binding + " to " + sourceTypeBinding);
if (isVisible(binding, sourceTypeBinding)) {
MethodBinding[] baseMethods = sourceTypeBinding.methods;
for (int i=0, len=baseMethods.length; i < len; i++) {
MethodBinding b = baseMethods[i];
sourceTypeBinding.resolveTypesFor(b); // this will return fast if its already been done.
if (matches(binding, b)) {
// this always means we should remove the existing method
if (b.sourceMethod() != null) {
b.sourceMethod().binding = null;
}
sourceTypeBinding.removeMethod(i);
//System.err.println(" left: " + Arrays.asList(sourceTypeBinding.methods));
break;
}