New submission from O.C. <oc-spa...@laposte.net>: Hello,
if 'lock' is a threading.Lock, the functions lock.__exit__() and lock.release() are different. The former takes 3 arguments, while the latter takes no argument. However, "lock.__exit__ == lock.release" returns True. Shouldn't it return False ? Best regards, O.C. Details: In [20]: lock=threading.Lock() In [21]: lock.acquire() In [22]: lock.__exit__(None,None,None) In [23]: lock.locked() Out[23]: False In [24]: lock.acquire() In [25]: lock.release(None,None,None) TypeError: release() takes no arguments (3 given) In [26]: lock.__exit__==lock.release Out[26]: True ---------- components: Library (Lib) messages: 128409 nosy: dghjfrdj priority: normal severity: normal status: open title: "lock.__exit__ == lock.release" should be False type: behavior versions: Python 3.1 _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue11194> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com