From ff6868cf10409441666d462af7df6a04faa45d1c Mon Sep 17 00:00:00 2001 From: Brett Cannon Date: Mon, 4 Aug 2008 21:24:43 +0000 Subject: [PATCH] Remove a use of callable() from Tkinter to silence warnings under -3. --- Lib/lib-tk/Tkinter.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/lib-tk/Tkinter.py b/Lib/lib-tk/Tkinter.py index 3f69baba963..7b116d9bb38 100644 --- a/Lib/lib-tk/Tkinter.py +++ b/Lib/lib-tk/Tkinter.py @@ -1577,7 +1577,7 @@ class Wm: """Bind function FUNC to command NAME for this widget. Return the function bound to NAME if None is given. NAME could be e.g. "WM_SAVE_YOURSELF" or "WM_DELETE_WINDOW".""" - if callable(func): + if hasattr(func, '__call__'): command = self._register(func) else: command = func