def _MaybeRemoveSignature(self, name, sig, is_abstract):
    'Visit a Signature and return None if we can remove it.'
    if ((not sig.params) or (sig.params[0].name != 'self') or (not isinstance(sig.params[0].type, pytd.ClassType))):
        return sig
    cls = sig.params[0].type.cls
    if (cls is None):
        return sig
    try:
        if self._FindNameAndSig(mro.GetBasesInMRO(cls), name, (sig.Replace(params=sig.params[1:]), is_abstract)):
            return None
    except mro.MROError:
        return sig
    return sig
Visit a Signature and return None if we can remove it.
def _MaybeRemoveSignature(self, name, sig, is_abstract):
    
    if ((not sig.params) or (sig.params[0].name != 'self') or (not isinstance(sig.params[0].type, pytd.ClassType))):
        return sig
    cls = sig.params[0].type.cls
    if (cls is None):
        return sig
    try:
        if self._FindNameAndSig(mro.GetBasesInMRO(cls), name, (sig.Replace(params=sig.params[1:]), is_abstract)):
            return None
    except mro.MROError:
        return sig
    return sig