ThreadRLock.locked: Add support for "by_self".
ThreadRLock: inherit from RLock instead of proxying it.