Returns True if fn is a bound method, regardless of whether fn was implemented in Python or in C.
(fn)
| 217 | return _re_stripid.sub(r'\1', text) |
| 218 | |
| 219 | def _is_bound_method(fn): |
| 220 | """ |
| 221 | Returns True if fn is a bound method, regardless of whether |
| 222 | fn was implemented in Python or in C. |
| 223 | """ |
| 224 | if inspect.ismethod(fn): |
| 225 | return True |
| 226 | if inspect.isbuiltin(fn): |
| 227 | self = getattr(fn, '__self__', None) |
| 228 | return not (inspect.ismodule(self) or (self is None)) |
| 229 | return False |
| 230 | |
| 231 | |
| 232 | def allmethods(cl): |
no test coverage detected
searching dependent graphs…