diff options
Diffstat (limited to 'Lib/_dummy_thread.py')
-rw-r--r-- | Lib/_dummy_thread.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/Lib/_dummy_thread.py b/Lib/_dummy_thread.py index b67cfb95be..36e5f38ae0 100644 --- a/Lib/_dummy_thread.py +++ b/Lib/_dummy_thread.py @@ -140,6 +140,14 @@ class LockType(object): def locked(self): return self.locked_status + def __repr__(self): + return "<%s %s.%s object at %s>" % ( + "locked" if self.locked_status else "unlocked", + self.__class__.__module__, + self.__class__.__qualname__, + hex(id(self)) + ) + # Used to signal that interrupt_main was called in a "thread" _interrupt = False # True when not executing in a "thread" |